]>
Commit | Line | Data |
---|---|---|
1 | ///////////////////////////////////////////////////////////////////////////// | |
2 | // Name: wx/msw/helpwin.h | |
3 | // Purpose: Help system: WinHelp implementation | |
4 | // Author: Julian Smart | |
5 | // Modified by: | |
6 | // Created: 04/01/98 | |
7 | // Copyright: (c) Julian Smart | |
8 | // Licence: wxWindows licence | |
9 | ///////////////////////////////////////////////////////////////////////////// | |
10 | ||
11 | #ifndef _WX_HELPWIN_H_ | |
12 | #define _WX_HELPWIN_H_ | |
13 | ||
14 | #include "wx/wx.h" | |
15 | ||
16 | #if wxUSE_HELP | |
17 | ||
18 | #include "wx/helpbase.h" | |
19 | ||
20 | class WXDLLIMPEXP_CORE wxWinHelpController: public wxHelpControllerBase | |
21 | { | |
22 | DECLARE_DYNAMIC_CLASS(wxWinHelpController) | |
23 | ||
24 | public: | |
25 | wxWinHelpController(wxWindow* parentWindow = NULL): wxHelpControllerBase(parentWindow) {} | |
26 | virtual ~wxWinHelpController() {} | |
27 | ||
28 | // Must call this to set the filename | |
29 | virtual bool Initialize(const wxString& file); | |
30 | virtual bool Initialize(const wxString& file, int WXUNUSED(server) ) { return Initialize( file ); } | |
31 | ||
32 | // If file is "", reloads file given in Initialize | |
33 | virtual bool LoadFile(const wxString& file = wxEmptyString); | |
34 | virtual bool DisplayContents(); | |
35 | virtual bool DisplaySection(int sectionNo); | |
36 | virtual bool DisplaySection(const wxString& section) { return KeywordSearch(section); } | |
37 | virtual bool DisplayBlock(long blockNo); | |
38 | virtual bool DisplayContextPopup(int contextId); | |
39 | virtual bool KeywordSearch(const wxString& k, | |
40 | wxHelpSearchMode mode = wxHELP_SEARCH_ALL); | |
41 | virtual bool Quit(); | |
42 | ||
43 | inline wxString GetHelpFile() const { return m_helpFile; } | |
44 | ||
45 | protected: | |
46 | // Append extension if necessary. | |
47 | wxString GetValidFilename(const wxString& file) const; | |
48 | ||
49 | private: | |
50 | wxString m_helpFile; | |
51 | }; | |
52 | ||
53 | #endif // wxUSE_HELP | |
54 | #endif | |
55 | // _WX_HELPWIN_H_ |