00001 /*************************************************************************** 00002 tinykate.h 00003 Tiny KATE mainwindow 00004 ------------------- 00005 begin : November 2002 00006 copyright : (C) 2002 by Joseph Wenninger <jowenn@kde.org> 00007 ***************************************************************************/ 00008 00009 /*************************************************************************** 00010 * * 00011 * This program is free software; you can redistribute it and/or modify * 00012 * it under the terms of the GNU General Public License as published by * 00013 * the Free Software Foundation. * 00014 * ONLY VERSION 2 OF THE LICENSE IS APPLICABLE * 00015 * * 00016 ***************************************************************************/ 00017 00018 #ifndef __TINYKATE_H__ 00019 #define __TINYKATE_H__ 00020 00021 00022 #include <qmainwindow.h> 00023 #include <opie2/otabwidget.h> 00024 #include <ktexteditor.h> 00025 00026 class QToolButton; 00027 class QAction; 00028 class QPopupMenu; 00029 00030 class TinyKate : public QMainWindow 00031 { 00032 Q_OBJECT 00033 public: 00034 TinyKate( QWidget *parent=0, const char *name=0, WFlags f = 0); 00035 ~TinyKate( ); 00036 static QString appName() { return QString::fromLatin1( "tinykate" ); }; 00037 00038 00039 public slots: 00040 void slotNew(); 00041 void setDocument(const QString& fileref); 00042 00043 protected slots: 00044 void slotOpen(); 00045 void slotClose(); 00046 void slotCurrentChanged(QWidget *); 00047 void slotSave(); 00048 void slotSaveAs(); 00049 protected: 00050 void open(const QString&); 00051 private: 00052 QString currentFileName; 00053 Opie::Ui::OTabWidget *tabwidget; 00054 KTextEditor::View *currentView; 00055 bool shutDown; 00056 00057 QToolButton *editCopy, *editCut, *editPaste, *editUndo, *editRedo, *editFindReplace; 00058 QAction *viewIncFontSizes, *viewDecFontSizes, *utilSettings; 00059 00060 QPopupMenu *hlmenu; 00061 uint nextUnnamed; 00062 uint viewCount; 00063 }; 00064 00065 00066 #endif // __TINYKATE_H__
1.4.2