Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

helpbrowser.h

Go to the documentation of this file.
00001 /**********************************************************************
00002 ** Copyright (C) 2000-2002 Trolltech AS.  All rights reserved.
00003 **
00004 ** This file is part of the Qtopia Environment.
00005 **
00006 ** This file may be distributed and/or modified under the terms of the
00007 ** GNU General Public License version 2 as published by the Free Software
00008 ** Foundation and appearing in the file LICENSE.GPL included in the
00009 ** packaging of this file.
00010 **
00011 ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
00012 ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
00013 **
00014 ** See http://www.trolltech.com/gpl/ for GPL licensing information.
00015 **
00016 ** Contact info@trolltech.com if any conditions of this licensing are
00017 ** not clear to you.
00018 **
00019 **********************************************************************/
00020 
00021 #ifndef HELPWINDOW_H
00022 #define HELPWINDOW_H
00023 
00024 #include <qmainwindow.h>
00025 #include <qtextbrowser.h>
00026 #include <qstringlist.h>
00027 #include <qmap.h>
00028 
00029 class QPopupMenu;
00030 class QAction;
00031 
00032 class HelpBrowser : public QMainWindow
00033 {
00034     Q_OBJECT
00035 public:
00036     HelpBrowser( QWidget* parent = 0, const char *name=0, WFlags f=0 );
00037     static QString appName() { return QString::fromLatin1("helpbrowser"); }
00038     ~HelpBrowser();
00039 
00040 public slots:
00041     void setDocument( const QString &doc );
00042     
00043 private slots:
00044     void appMessage(const QCString& msg, const QByteArray& data);
00045     void textChanged();
00046 
00047     void pathSelected( const QString & );
00048     void bookmChosen( int );
00049     void addBookmark();
00050     void removeBookmark();
00051     
00052 private:
00053     void init( const QString & );
00054     void readBookmarks();
00055     
00056     QTextBrowser* browser;
00057     QAction *backAction;
00058     QAction *forwardAction;
00059     QString selectedURL;
00060     struct Bookmark { 
00061         QString name;
00062         QString file;
00063     };
00064     QMap<int, Bookmark> mBookmarks;
00065     QMenuBar *menu;
00066     QPopupMenu *bookm;
00067 };
00068 
00069 #endif
00070 

Generated on Sat Nov 5 16:15:28 2005 for OPIE by  doxygen 1.4.2