]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/src/htmlhelp.i
fixed MSLU check
[wxWidgets.git] / wxPython / src / htmlhelp.i
index 6f77dba09afd298bf74696312e2aaa599621a0a2..b9c9bee5e1da7800adc9e9b14bc25ac81cbcf1df 100644 (file)
@@ -4,7 +4,7 @@
 //
 // Author:      Robin Dunn
 //
-// Created:     25-nov-1998
+// Created:     25-Nov-1998
 // RCS-ID:      $Id$
 // Copyright:   (c) 1998 by Total Control Software
 // Licence:     wxWindows license
 %extern utils.i
 %extern html.i
 
+//  #ifdef wxUSE_UNICODE
+//  %typemap(python, memberin) wxChar* {
+//      if ($target) delete [] $target;
+//      wxString *tempStr = new wxString($source);
+//      $target = new wxChar[tempStr->Len()+1];
+//      memcpy($target, tempStr->c_str(), (sizeof(wxChar)*tempStr->Len())+sizeof(wxChar));
+//      delete tempStr;
+//  }
+//  #endif
 
 //---------------------------------------------------------------------------
 
-class  wxHtmlHelpFrameCfg
-{
+class wxHtmlBookRecord : public wxObject {
 public:
-    wxHtmlHelpFrameCfg();
-
-    long x, y, w, h;
-    long sashpos;
-    bool navig_on;
-};
-
-
-//---------------------------------------------------------------------------
-
-class wxHtmlBookRecord  {
-public:
-    wxHtmlBookRecord(const wxString& basepath, const wxString& title,
-                    const wxString& start);
+    wxHtmlBookRecord(const wxString& bookfile, const wxString& basepath,
+                     const wxString& title, const wxString& start);
 
+    wxString GetBookFile();
     wxString GetTitle();
     wxString GetStart();
     wxString GetBasePath();
@@ -67,18 +64,26 @@ public:
     void SetContentsRange(int start, int end);
     int GetContentsStart();
     int GetContentsEnd();
+
+    void SetTitle(const wxString& title);
+    void SetBasePath(const wxString& path);
+    void SetStart(const wxString& start);
+
+    wxString GetFullPath(const wxString &page) const;
 };
 
 //---------------------------------------------------------------------------
 
-typedef struct
+struct wxHtmlContentsItem
 {
+%readonly
     short int m_Level;
     int m_ID;
-    char* m_Name;
-    char* m_Page;
+    wxChar* m_Name;
+    wxChar* m_Page;
     wxHtmlBookRecord *m_Book;
-} wxHtmlContentsItem;
+%readwrite
+};
 
 //---------------------------------------------------------------------------
 
@@ -129,6 +134,8 @@ public:
                    const wxString& title = wxEmptyString,
                    int style = wxHF_DEFAULTSTYLE, wxHtmlHelpData* data = NULL);
 
+    %pragma(python) addtomethod = "__init__:self._setOORInfo(self)"
+
     wxHtmlHelpData* GetData();
     void SetTitleFormat(const wxString& format);
     void Display(const wxString& x);
@@ -163,6 +170,8 @@ public:
     wxHtmlHelpController(int style = wxHF_DEFAULTSTYLE);
     ~wxHtmlHelpController();
 
+    %pragma(python) addtomethod = "__init__:self._setOORInfo(self)"
+
     void SetTitleFormat(const wxString& format);
     void SetTempDir(const wxString& path);
     bool AddBook(const wxString& book, int show_wait_msg = FALSE);