kexi

kexistatusbar.h
1/* This file is part of the KDE project
2 Copyright (C) 2003 Jaroslaw Staniek <js@iidea.pl>
3
4 This program is free software; you can redistribute it and,or
5 modify it under the terms of the GNU Library General Public
6 License as published by the Free Software Foundation; either
7 version 2 of the License, or (at your option) any later version.
8
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 Library General Public License for more details.
13
14 You should have received a copy of the GNU Library General Public License
15 along with this program; see the file COPYING. If not, write to
16 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17 * Boston, MA 02110-1301, USA.
18
19 Loosely based on tdevelop/src/statusbar.h
20 Copyright (C) 2001 by Bernd Gehrmann <bernd@kdevelop.org>
21*/
22
23#ifndef KEXISTATUSBAR_H
24#define KEXISTATUSBAR_H
25
26//temporary
27#define KexitStatusBar_KTEXTEDITOR_USED 0
28
29#include <kstatusbar.h>
30#include <tqmap.h>
31
32class TQLabel;
33
34#if KexitStatusBar_KTEXTEDITOR_USED
35namespace KTextEditor { class ViewStatusMsgInterface; }
36namespace KTextEditor { class ViewCursorInterface; }
37#endif
38namespace KParts { class Part; }
39
40class KexitStatusBar : public KStatusBar
41{
42 TQ_OBJECT
43
44 public:
45 KexitStatusBar( TQWidget *parent=0, const char *name=0 );
46 virtual ~KexitStatusBar();
47// virtual void addWidget( TQWidget *widget, int stretch = 0, bool permanent = false);
48
49 public slots:
50 virtual void setStatus(const TQString &str);
51 virtual void setReadOnlyFlag(bool readOnly);
52
53 protected slots:
54 virtual void cursorPositionChanged();
55 virtual void activePartChanged(KParts::Part *part);
56 virtual void setCursorPosition(int line, int col);
57
58 protected:
59 int m_msgID, m_readOnlyID;
60// TQLabel *m_status, *m_readOnlyStatus;
61
62#if KexitStatusBar_KTEXTEDITOR_USED
63 KTextEditor::ViewCursorInterface * m_cursorIface;
64 KTextEditor::ViewStatusMsgInterface * m_viewmsgIface;
65#endif
66 KParts::Part *m_activePart;
67};
68
69#endif
70