]>
Commit | Line | Data |
---|---|---|
23324ae1 FM |
1 | ///////////////////////////////////////////////////////////////////////////// |
2 | // Name: html/helpfrm.h | |
e54c96f1 | 3 | // Purpose: interface of wxHtmlHelpFrame |
23324ae1 FM |
4 | // Author: wxWidgets team |
5 | // RCS-ID: $Id$ | |
526954c5 | 6 | // Licence: wxWindows licence |
23324ae1 FM |
7 | ///////////////////////////////////////////////////////////////////////////// |
8 | ||
90f011dc RD |
9 | /// style flags for the Help Frame |
10 | #define wxHF_TOOLBAR 0x0001 | |
11 | #define wxHF_CONTENTS 0x0002 | |
12 | #define wxHF_INDEX 0x0004 | |
13 | #define wxHF_SEARCH 0x0008 | |
14 | #define wxHF_BOOKMARKS 0x0010 | |
15 | #define wxHF_OPEN_FILES 0x0020 | |
16 | #define wxHF_PRINT 0x0040 | |
17 | #define wxHF_FLAT_TOOLBAR 0x0080 | |
18 | #define wxHF_MERGE_BOOKS 0x0100 | |
19 | #define wxHF_ICONS_BOOK 0x0200 | |
20 | #define wxHF_ICONS_BOOK_CHAPTER 0x0400 | |
21 | #define wxHF_ICONS_FOLDER 0x0000 // this is 0 since it is default | |
22 | #define wxHF_DEFAULT_STYLE (wxHF_TOOLBAR | wxHF_CONTENTS | \ | |
23 | wxHF_INDEX | wxHF_SEARCH | \ | |
24 | wxHF_BOOKMARKS | wxHF_PRINT) | |
25 | ||
26 | ||
23324ae1 FM |
27 | /** |
28 | @class wxHtmlHelpFrame | |
7c913512 | 29 | |
c87f263e | 30 | This class is used by wxHtmlHelpController to display help. |
23324ae1 FM |
31 | It is an internal class and should not be used directly - except for the case |
32 | when you're writing your own HTML help controller. | |
7c913512 | 33 | |
23324ae1 | 34 | @library{wxhtml} |
c87f263e | 35 | @category{help,html} |
23324ae1 FM |
36 | */ |
37 | class wxHtmlHelpFrame : public wxFrame | |
38 | { | |
39 | public: | |
c87f263e FM |
40 | wxHtmlHelpFrame(wxHtmlHelpData* data = NULL); |
41 | ||
23324ae1 | 42 | /** |
c87f263e FM |
43 | Constructor. |
44 | ||
45 | For the possible values of @a style, please see wxHtmlHelpController. | |
23324ae1 | 46 | */ |
90f011dc | 47 | wxHtmlHelpFrame(wxWindow* parent, wxWindowID id, |
7c913512 FM |
48 | const wxString& title = wxEmptyString, |
49 | int style = wxHF_DEFAULT_STYLE, | |
a44f3b5a FM |
50 | wxHtmlHelpData* data = NULL, |
51 | wxConfigBase* config = NULL, | |
52 | const wxString& rootpath = wxEmptyString); | |
23324ae1 FM |
53 | |
54 | /** | |
55 | You may override this virtual method to add more buttons to the help window's | |
4cc4bfaf | 56 | toolbar. @a toolBar is a pointer to the toolbar and @a style is the style |
c87f263e FM |
57 | flag as passed to the Create() method. |
58 | ||
23324ae1 FM |
59 | wxToolBar::Realize is called immediately after returning from this function. |
60 | */ | |
4cc4bfaf | 61 | virtual void AddToolbarButtons(wxToolBar* toolBar, int style); |
23324ae1 FM |
62 | |
63 | /** | |
c87f263e | 64 | Creates the frame. See @ref wxHtmlHelpFrame() "the constructor" |
23324ae1 FM |
65 | for a description of the parameters. |
66 | */ | |
67 | bool Create(wxWindow* parent, wxWindowID id, | |
5267aefd FM |
68 | const wxString& title = wxEmptyString, int style = wxHF_DEFAULT_STYLE, |
69 | wxConfigBase* config = NULL, | |
70 | const wxString& rootpath = wxEmptyString); | |
23324ae1 FM |
71 | |
72 | /** | |
73 | Returns the help controller associated with the frame. | |
74 | */ | |
328f5751 | 75 | wxHtmlHelpController* GetController() const; |
23324ae1 | 76 | |
23324ae1 FM |
77 | /** |
78 | Sets the help controller associated with the frame. | |
79 | */ | |
d13b34d3 | 80 | void SetController(wxHtmlHelpController* controller); |
23324ae1 FM |
81 | |
82 | /** | |
c87f263e FM |
83 | Sets the frame's title format. |
84 | ||
85 | @a format must contain exactly one "%s" (it will be replaced by the page title). | |
23324ae1 FM |
86 | */ |
87 | void SetTitleFormat(const wxString& format); | |
23324ae1 | 88 | }; |
e54c96f1 | 89 |