1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: SWIG definitions of html classes
7 // Created: 25-Nov-1998
9 // Copyright: (c) 1998 by Total Control Software
10 // Licence: wxWindows license
11 /////////////////////////////////////////////////////////////////////////////
18 #include <wx/html/htmlwin.h>
19 #include <wx/html/helpctrl.h>
21 #include <wx/fs_zip.h>
22 #include <wx/fs_inet.h>
23 #include <wx/wfstream.h>
26 //---------------------------------------------------------------------------
29 %include my_typemaps.i
43 //---------------------------------------------------------------------------
45 class wxHtmlBookRecord {
47 wxHtmlBookRecord(const wxString& basepath, const wxString& title,
48 const wxString& start);
52 wxString GetBasePath();
54 void SetContentsRange(int start, int end);
55 int GetContentsStart();
59 //---------------------------------------------------------------------------
67 wxHtmlBookRecord *m_Book;
70 //---------------------------------------------------------------------------
72 class wxHtmlSearchStatus
75 //wxHtmlSearchStatus(wxHtmlHelpData* base, const wxString& keyword,
76 // const wxString& book = wxEmptyString);
81 const wxString& GetName();
82 wxHtmlContentsItem* GetContentsItem();
85 //---------------------------------------------------------------------------
87 class wxHtmlHelpData {
92 void SetTempDir(const wxString& path);
93 bool AddBook(const wxString& book);
94 // bool AddBookParam(const wxString& title, const wxString& contfile,
95 // const wxString& indexfile=wxEmptyString,
96 // const wxString& deftopic=wxEmptyString,
97 // const wxString& path=wxEmptyString);
99 wxString FindPageByName(const wxString& page);
100 wxString FindPageById(int id);
102 // TODO: this one needs fixed...
103 const wxHtmlBookRecArray& GetBookRecArray();
105 wxHtmlContentsItem* GetContents();
106 int GetContentsCnt();
107 wxHtmlContentsItem* GetIndex();
111 //---------------------------------------------------------------------------
113 class wxHtmlHelpFrame : public wxFrame {
115 wxHtmlHelpFrame(wxWindow* parent, int wxWindowID,
116 const wxString& title = wxEmptyString,
117 int style = wxHF_DEFAULTSTYLE, wxHtmlHelpData* data = NULL);
119 wxHtmlHelpData* GetData();
120 void SetTitleFormat(const wxString& format);
121 void Display(const wxString& x);
122 %name(DisplayID) void Display(int id);
123 void DisplayContents();
125 bool KeywordSearch(const wxString& keyword);
126 void UseConfig(wxConfigBase *config, const wxString& rootpath = wxEmptyString);
127 void ReadCustomization(wxConfigBase *cfg, wxString path = wxEmptyString);
128 void WriteCustomization(wxConfigBase *cfg, wxString path = wxEmptyString);
132 //---------------------------------------------------------------------------
148 class wxHtmlHelpController : public wxEvtHandler {
150 wxHtmlHelpController(int style = wxHF_DEFAULTSTYLE);
151 ~wxHtmlHelpController();
153 void SetTitleFormat(const wxString& format);
154 void SetTempDir(const wxString& path);
155 bool AddBook(const wxString& book, int show_wait_msg = FALSE);
156 void Display(const wxString& x);
157 %name(DisplayID) void Display(int id);
158 void DisplayContents();
160 bool KeywordSearch(const wxString& keyword);
161 void UseConfig(wxConfigBase *config, const wxString& rootpath = wxEmptyString);
162 void ReadCustomization(wxConfigBase *cfg, wxString path = wxEmptyString);
163 void WriteCustomization(wxConfigBase *cfg, wxString path = wxEmptyString);
164 wxHtmlHelpFrame* GetFrame();
167 //---------------------------------------------------------------------------
168 //---------------------------------------------------------------------------