summaryrefslogtreecommitdiffstats
path: root/khelpcenter/mainwindow.h
diff options
context:
space:
mode:
authortoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
committertoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
commit4aed2c8219774f5d797760606b8489a92ddc5163 (patch)
tree3f8c130f7d269626bf6a9447407ef6c35954426a /khelpcenter/mainwindow.h
downloadtdebase-4aed2c8219774f5d797760606b8489a92ddc5163.tar.gz
tdebase-4aed2c8219774f5d797760606b8489a92ddc5163.zip
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'khelpcenter/mainwindow.h')
-rw-r--r--khelpcenter/mainwindow.h108
1 files changed, 108 insertions, 0 deletions
diff --git a/khelpcenter/mainwindow.h b/khelpcenter/mainwindow.h
new file mode 100644
index 000000000..aba2d3421
--- /dev/null
+++ b/khelpcenter/mainwindow.h
@@ -0,0 +1,108 @@
+#ifndef __mainwindow_h__
+#define __mainwindow_h__
+
+#include <qptrlist.h>
+
+#include <kmainwindow.h>
+#include <kio/job.h>
+#include <kurl.h>
+#include <kparts/browserextension.h>
+#include <dcopclient.h>
+#include <dcopobject.h>
+
+#include "navigator.h"
+#include "glossary.h"
+
+class KHTMLPart;
+class QSplitter;
+
+class LogDialog;
+
+namespace KHC {
+
+class View;
+
+class MainWindow : public KMainWindow, public DCOPObject
+{
+ Q_OBJECT
+ K_DCOP
+ public:
+ MainWindow();
+ ~MainWindow();
+
+ k_dcop:
+ void openUrl( const QString &url );
+ void openUrl( const QString &url, const QCString& startup_id );
+ void showHome();
+ void lastSearch();
+
+ public slots:
+ void print();
+ void statusBarMessage(const QString &m);
+ void slotShowHome();
+ void slotLastSearch();
+ void showSearchStderr();
+ /**
+ Show document corresponding to given URL in viewer part.
+ */
+ void viewUrl( const KURL &url,
+ const KParts::URLArgs &args = KParts::URLArgs() );
+ /**
+ Show document corresponding to given URL in viewer part.
+ */
+ void viewUrl( const QString & );
+
+ /**
+ Open document corresponding to given URL, i.e. show it in the viewer part
+ and select the corresponding entry in the navigator widget.
+ */
+ void openUrl( const KURL &url );
+
+ protected:
+ void setupActions();
+
+ virtual void saveProperties( KConfig *config );
+ virtual void readProperties( KConfig *config );
+
+ void readConfig();
+ void writeConfig();
+
+ protected slots:
+ void enableLastSearchAction();
+ void enableCopyTextAction();
+
+ private:
+ void stop();
+
+ private slots:
+ void slotGlossSelected(const GlossaryEntry &entry);
+ void slotStarted(KIO::Job *job);
+ void slotInfoMessage(KIO::Job *, const QString &);
+ void goInternalUrl( const KURL & );
+ /**
+ This function is called when the user clicks on a link in the viewer part.
+ */
+ void slotOpenURLRequest( const KURL &url,
+ const KParts::URLArgs &args);
+ void documentCompleted();
+ void slotIncFontSizes();
+ void slotDecFontSizes();
+ void slotConfigureFonts();
+ void slotCopySelectedText();
+
+private:
+ void updateZoomActions();
+
+ QSplitter *mSplitter;
+ View *mDoc;
+ Navigator *mNavigator;
+
+ KAction *mLastSearchAction;
+ KAction *mCopyText;
+ LogDialog *mLogDialog;
+};
+
+}
+
+#endif
+// vim:ts=2:sw=2:et