home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / qt3_emx.zip / examples / helpviewer / helpwindow.h < prev    next >
C/C++ Source or Header  |  2001-10-11  |  1KB  |  66 lines

  1. /****************************************************************************
  2. ** $Id:  qt/helpwindow.h   3.0.0   edited Jun 22 13:24 $
  3. **
  4. ** Copyright (C) 1992-2000 Trolltech AS.  All rights reserved.
  5. **
  6. ** This file is part of an example program for Qt.  This example
  7. ** program may be used, distributed and modified without limitation.
  8. **
  9. *****************************************************************************/
  10.  
  11. #ifndef HELPWINDOW_H
  12. #define HELPWINDOW_H
  13.  
  14. #include <qmainwindow.h>
  15. #include <qtextbrowser.h>
  16. #include <qstringlist.h>
  17. #include <qmap.h>
  18. #include <qdir.h>
  19.  
  20. class QComboBox;
  21. class QPopupMenu;
  22.  
  23. class HelpWindow : public QMainWindow
  24. {
  25.     Q_OBJECT
  26. public:
  27.     HelpWindow( const QString& home_,  const QString& path, QWidget* parent = 0, const char *name=0 );
  28.     ~HelpWindow();
  29.  
  30. private slots:
  31.     void setBackwardAvailable( bool );
  32.     void setForwardAvailable( bool );
  33.  
  34.     void textChanged();
  35.     void about();
  36.     void aboutQt();
  37.     void openFile();
  38.     void newWindow();
  39.     void print();
  40.  
  41.     void pathSelected( const QString & );
  42.     void histChosen( int );
  43.     void bookmChosen( int );
  44.     void addBookmark();
  45.     
  46. private:
  47.     void readHistory();
  48.     void readBookmarks();
  49.     
  50.     QTextBrowser* browser;
  51.     QComboBox *pathCombo;
  52.     int backwardId, forwardId;
  53.     QString selectedURL;
  54.     QStringList history, bookmarks;
  55.     QMap<int, QString> mHistory, mBookmarks;
  56.     QPopupMenu *hist, *bookm;
  57.     
  58. };
  59.  
  60.  
  61.  
  62.  
  63.  
  64. #endif
  65.  
  66.