Update of /cvsroot/wxlua/wxLua/bindings/wxwidgets In directory sc8-pr-cvs9.sourceforge.net:/tmp/cvs-serv22784/wxLua/bindings/wxwidgets Modified Files: controls.i defsutil.i dialogs.i file.i gdi.i help.i html.i image.i wx_datatypes.lua Log Message: update bindings to wxWidgets 2.8 using headers Index: wx_datatypes.lua =================================================================== RCS file: /cvsroot/wxlua/wxLua/bindings/wxwidgets/wx_datatypes.lua,v retrieving revision 1.53 retrieving revision 1.54 diff -C2 -d -r1.53 -r1.54 *** wx_datatypes.lua 9 Mar 2007 06:10:16 -0000 1.53 --- wx_datatypes.lua 12 Mar 2007 23:12:31 -0000 1.54 *************** *** 1018,1021 **** --- 1018,1027 ---- Name = "wxFile::OpenMode", }, + ["wxFile::dummy"] = { + Condition = "wxLUA_USE_wxFile && wxUSE_FILE", + DefType = "enum", + IsNumber = true, + Name = "wxFile::dummy", + }, wxFileConfig = { BaseClass = "wxConfigBase", *************** *** 1704,1707 **** --- 1710,1719 ---- Name = "wxIconBundle", }, + wxIconLocation = { + Condition = "wxLUA_USE_wxIcon", + DefType = "class", + IsNumber = false, + Name = "wxIconLocation", + }, wxIconizeEvent = { BaseClass = "wxEvent", *************** *** 2157,2160 **** --- 2169,2178 ---- Name = "wxMultiChoiceDialog", }, + wxNativeFontInfo = { + Condition = "wxLUA_USE_wxFont", + DefType = "class", + IsNumber = false, + Name = "wxNativeFontInfo", + }, wxNavigationKeyEvent = { BaseClass = "wxEvent", *************** *** 2317,2320 **** --- 2335,2344 ---- Name = "wxPathFormat", }, + wxPathList = { + BaseClass = "wxArrayString", + DefType = "class", + IsNumber = false, + Name = "wxPathList", + }, wxPathNormalize = { Condition = "wxLUA_USE_wxFileName", *************** *** 2673,2676 **** --- 2697,2707 ---- Name = "wxSimpleHelpProvider", }, + wxSimpleHtmlListBox = { + BaseClass = "wxHtmlWindowInterface", + Condition = "(wxCHECK_VERSION(2,7,0)) && (wxLUA_USE_wxHTML && wxUSE_HTML)", + DefType = "class", + IsNumber = false, + Name = "wxSimpleHtmlListBox", + }, wxSingleChoiceDialog = { BaseClass = "wxDialog", *************** *** 2890,2893 **** --- 2921,2936 ---- Name = "wxStdDialogButtonSizer", }, + wxStockGDI = { + Condition = "(wxCHECK_VERSION(2,8,0)) && (wxLUA_USE_wxColourPenBrush)", + DefType = "class", + IsNumber = false, + Name = "wxStockGDI", + }, + ["wxStockGDI::Item"] = { + Condition = "(wxCHECK_VERSION(2,8,0)) && (wxLUA_USE_wxColourPenBrush)", + DefType = "enum", + IsNumber = true, + Name = "wxStockGDI::Item", + }, wxStreamBase = { Condition = "wxUSE_STREAMS", *************** *** 3002,3005 **** --- 3045,3054 ---- Name = "wxTaskBarIconEvent", }, + wxTempFile = { + Condition = "wxLUA_USE_wxFile && wxUSE_FILE", + DefType = "class", + IsNumber = false, + Name = "wxTempFile", + }, wxTextAttr = { Condition = "wxLUA_USE_wxTextCtrl && wxUSE_TEXTCTRL", Index: file.i =================================================================== RCS file: /cvsroot/wxlua/wxLua/bindings/wxwidgets/file.i,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** file.i 9 Mar 2007 00:15:12 -0000 1.17 --- file.i 12 Mar 2007 23:12:31 -0000 1.18 *************** *** 26,30 **** %function wxString wxGetOSDirectory() %function bool wxIsAbsolutePath(const wxString& filename) - %function bool wxDirExists(const wxString& dirname) %function wxString wxPathOnly(const wxString& path) // %override [new lua string] wxUnix2DosFilename(lua string) --- 26,29 ---- *************** *** 38,46 **** %function bool wxMkdir(const wxString& dir, int perm = 0777) //int wxParseCommonDialogsFilter(const wxString& wildCard, wxArrayString& descriptions, wxArrayString& filters) %function bool wxRemoveFile(const wxString& file) ! %function bool wxRenameFile(const wxString& file1, const wxString& file2) %function bool wxRmdir(const wxString& dir, int flags=0) %function bool wxSetWorkingDirectory(const wxString& dir) // These two methods are for wxLua // %override wxFILE_SEP_PATH wxFileSeparator() - returns either / or \ depending on platform --- 37,51 ---- %function bool wxMkdir(const wxString& dir, int perm = 0777) //int wxParseCommonDialogsFilter(const wxString& wildCard, wxArrayString& descriptions, wxArrayString& filters) + %wxchkver_2_8 %function wxString wxRealPath(const wxString& path) %function bool wxRemoveFile(const wxString& file) ! !%wxchkver_2_8 %function bool wxRenameFile(const wxString& file1, const wxString& file2) ! %wxchkver_2_8 %function bool wxRenameFile(const wxString& file1, const wxString& file2, bool overwrite = true) %function bool wxRmdir(const wxString& dir, int flags=0) %function bool wxSetWorkingDirectory(const wxString& dir) + %wxchkver_2_8 %function bool wxIsWritable(const wxString &path) + %wxchkver_2_8 %function bool wxIsReadable(const wxString &path) + %wxchkver_2_8 %function bool wxIsExecutable(const wxString &path) + // These two methods are for wxLua // %override wxFILE_SEP_PATH wxFileSeparator() - returns either / or \ depending on platform *************** *** 49,54 **** --- 54,117 ---- %function long wxFileSize(const wxString& fileName) + // wxLua only has storage for wxChar* in bindings, wxFILE_SEP_XXX are #defined + // as wxChar wxT('.'), so we just redefine them to be wxT(".") or wxChar* + %define %string wxFILE_SEP_EXT wxT(".") + %define %string wxFILE_SEP_DSK wxT(":") + %define %string wxFILE_SEP_PATH_DOS wxT("\\") + %define %string wxFILE_SEP_PATH_UNIX wxT("/") + %define %string wxFILE_SEP_PATH_MAC wxT(":") + %define %string wxFILE_SEP_PATH_VMS wxT(".") // VMS also uses '[' and ']' + + %if defined(__UNIX__) && !defined(__OS2__) + // CYGWIN also uses UNIX settings + %define %string wxFILE_SEP_PATH wxT("/") // wxFILE_SEP_PATH_UNIX + %endif + %if defined(__MAC__) + %define %string wxFILE_SEP_PATH wxT(":") // wxFILE_SEP_PATH_MAC + %endif + %if !(defined(__UNIX__) && !defined(__OS2__)) && !defined(__MAC__) // Windows and OS/2 + %define %string wxFILE_SEP_PATH wxT("\\") // wxFILE_SEP_PATH_DOS + %endif // Unix/Windows + + %define %string wxPATH_SEP_DOS // wxT(";") + %define %string wxPATH_SEP_UNIX // wxT(":") + %define %string wxPATH_SEP_MAC // wxT(";") + %define %string wxPATH_SEP // wxPATH_SEP_XXX + + %define wxARE_FILENAMES_CASE_SENSITIVE // bool 1/0 + + //%function bool wxIsPathSeparator(wxChar c) FIXME + //%function bool wxEndsWithPathSeparator(const wxChar *pszFileName) + + + //----------------------------------------------------------------------------- + // wxPathList + + %include "wx/filefn.h" + + %class %delete %encapsulate %noclassinfo wxPathList, wxArrayString + wxPathList() + //wxPathList(const wxArrayString &arr) + + // Adds all paths in environment variable + void AddEnvList(const wxString& envVariable) + // Adds given path to this list + !%wxchkver_2_8 void Add(const wxString& path) + %wxchkver_2_8 bool Add(const wxString& path) + %wxchkver_2_8 %rename AddArray void Add(const wxArrayString_FromLuaTable& paths) + // Find the first full path for which the file exists + wxString FindValidPath(const wxString& filename) const + // Find the first full path for which the file exists; ensure it's an + // absolute path that gets returned. + wxString FindAbsoluteValidPath(const wxString& filename) const + // Given full path and filename, add path to list + !%wxchkver_2_8 void EnsureFileAccessible(const wxString& path) + %wxchkver_2_8 bool EnsureFileAccessible(const wxString& path) + %endclass + //----------------------------------------------------------------------------- // wxFileName + // Note: Most of the static methods are not implemented since it is just as + // easy to create a wxFileName object and call functions on it. %if wxLUA_USE_wxFileName *************** *** 104,111 **** void AssignDir(const wxString& dir, wxPathFormat format = wxPATH_NATIVE) void AssignHomeDir() ! void AssignTempFileName(const wxString& prefix, wxFile *fileTemp = NULL) void Clear() void ClearExt() ! static wxString CreateTempFileName(const wxString& prefix, wxFile *fileTemp = NULL) bool DirExists() %rename DirExistsName static bool DirExists(const wxString& dir) --- 167,181 ---- void AssignDir(const wxString& dir, wxPathFormat format = wxPATH_NATIVE) void AssignHomeDir() ! !%wxchkver_2_8 void AssignTempFileName(const wxString& prefix, wxFile *fileTemp = NULL) ! %wxchkver_2_8&&(wxUSE_FILE||wxUSE_FFILE) %rename AssignTempFileNameGetName void AssignTempFileName(const wxString& prefix) ! %wxchkver_2_8&&wxUSE_FILE void AssignTempFileName(const wxString& prefix, wxFile *fileTemp) ! //%wxchkver_2_8&&wxUSE_FFILE void AssignTempFileName(const wxString& prefix, wxFFile *fileTemp) void Clear() void ClearExt() ! // Use AssignTempFileName(...) equivalents ! //!%wxchkver_2_8 static wxString CreateTempFileName(const wxString& prefix, wxFile *fileTemp = NULL) ! //%wxchkver_2_8&&(wxUSE_FILE||wxUSE_FFILE) static wxString CreateTempFileName(const wxString& prefix) ! //%wxchkver_2_8&&wxUSE_FILE static wxString CreateTempFileName(const wxString& prefix, wxFile *fileTemp) ! //%wxchkver_2_8&&wxUSE_FFILE static wxString CreateTempFileName(const wxString& prefix, wxFFile *fileTemp); bool DirExists() %rename DirExistsName static bool DirExists(const wxString& dir) *************** *** 124,127 **** --- 194,200 ---- wxString GetFullPath(wxPathFormat format = wxPATH_NATIVE) const static wxString GetHomeDir() + %wxchkver_2_8 wxString GetHumanReadableSize(const wxString &nullsize = "Not available", int precision = 1) const + //%wxchkver_2_8 wxString GetHumanReadableSize(const wxString &nullsize = wxGetTranslation(_T("Not available")), int precision = 1) const + //%wxchkver_2_8 static wxString GetHumanReadableSize(const wxULongLong &sz, const wxString &nullsize = wxGetTranslation(_T("Not available")), int precision = 1) wxString GetLongPath() const wxDateTime GetModificationTime() const *************** *** 132,135 **** --- 205,210 ---- static wxString GetPathTerminators(wxPathFormat format = wxPATH_NATIVE) wxString GetShortPath() const + //%wxchkver_2_8 wxULongLong GetSize() const + //%wxchkver_2_8 static wxULongLong GetSize(const wxString &file) // %override [bool, wxDateTime dtAccess, wxDateTime dtMod, wxDateTime dtCreate] wxFileName::GetTimes() bool GetTimes(wxDateTime* dtAccess, wxDateTime* dtMod, wxDateTime* dtCreate) const *************** *** 146,149 **** --- 221,234 ---- bool IsRelative(wxPathFormat format = wxPATH_NATIVE) bool IsDir() const + %wxchkver_2_8 bool IsDirWritable() const + //%wxchkver_2_8 static bool IsDirWritable(const wxString &path) + %wxchkver_2_8 bool IsDirReadable() const + //%wxchkver_2_8 static bool IsDirReadable(const wxString &path) + %wxchkver_2_8 bool IsFileWritable() const + //%wxchkver_2_8 static bool IsFileWritable(const wxString &path) + %wxchkver_2_8 bool IsFileReadable() const + //%wxchkver_2_8 static bool IsFileReadable(const wxString &path) + %wxchkver_2_8 bool IsFileExecutable() const + //%wxchkver_2_8 static bool IsFileExecutable(const wxString &path) //static bool MacFindDefaultTypeAndCreator(const wxString& ext, wxUint32* type, wxUint32* creator) //bool MacSetDefaultTypeAndCreator() *************** *** 198,201 **** --- 283,293 ---- %endenum + %enum wxFile::dummy + fd_invalid // = -1 + fd_stdin + fd_stdout + fd_stderr + %endenum + %enum wxSeekMode wxFromStart *************** *** 248,252 **** //size_t Write(const void* buffer, unsigned int count) size_t Write(const wxString& buffer, unsigned int count) ! %rename WriteString size_t Write(const wxString &str) %endclass --- 340,377 ---- //size_t Write(const void* buffer, unsigned int count) size_t Write(const wxString& buffer, unsigned int count) ! %rename WriteString size_t Write(const wxString &str) //, const wxMBConv& conv = wxConvUTF8) ! %endclass ! ! //----------------------------------------------------------------------------- ! // wxTempFile ! ! %include "wx/file.h" ! ! %class %noclassinfo %encapsulate %delete wxTempFile ! %constructor wxTempFileDefault() ! // associates the temp file with the file to be replaced and opens it ! wxTempFile(const wxString& strName) ! ! // open the temp file (strName is the name of file to be replaced) ! bool Open(const wxString& strName) ! ! // is the file opened? ! bool IsOpened() const ! // get current file length ! wxFileOffset Length() const ! // move ptr ofs bytes related to start/current offset/end of file ! wxFileOffset Seek(wxFileOffset ofs, wxSeekMode mode = wxFromStart) ! // get current offset ! wxFileOffset Tell() const ! ! // I/O (both functions return true on success, false on failure) ! //bool Write(const void *p, size_t n) ! bool Write(const wxString& str) //, const wxMBConv& conv = wxConvUTF8) ! ! // validate changes and delete the old file of name m_strName ! bool Commit() ! // discard changes ! void Discard(); ! %endclass Index: help.i =================================================================== RCS file: /cvsroot/wxlua/wxLua/bindings/wxwidgets/help.i,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** help.i 9 Mar 2007 00:15:12 -0000 1.11 --- help.i 12 Mar 2007 23:12:31 -0000 1.12 *************** *** 89,92 **** --- 89,94 ---- %include "wx/help.h" + %define wxHELP_NETSCAPE // Flags for SetViewer + %enum wxHelpSearchMode wxHELP_SEARCH_INDEX *************** *** 97,100 **** --- 99,103 ---- %class %delete wxHelpController, wxObject wxHelpController() + //%wxchkver_2_8 wxHelpController(wxWindow* parentWindow = NULL) wxHTMLHelpController takes different params virtual void Initialize(const wxString& file) *************** *** 108,115 **** --- 111,120 ---- // %override [wxFrame*, wxSize* size = NULL, wxPoint* pos = NULL, bool *newFrameEachTime = NULL] wxHelpController::GetFrameParameters() virtual wxFrame* GetFrameParameters(wxSize* size = NULL, wxPoint* pos = NULL, bool *newFrameEachTime = NULL) + %wxchkver_2_8 virtual wxWindow* GetParentWindow() const virtual bool KeywordSearch(const wxString& keyWord, wxHelpSearchMode mode = wxHELP_SEARCH_ALL) virtual bool LoadFile(const wxString& file = "") //virtual bool OnQuit() virtual void SetFrameParameters(const wxString& title, const wxSize& size, const wxPoint& pos = wxDefaultPosition, bool newFrameEachTime = false) + %wxchkver_2_8 virtual void SetParentWindow(wxWindow* win) virtual void SetViewer(const wxString& viewer, long flags) virtual bool Quit() Index: image.i =================================================================== RCS file: /cvsroot/wxlua/wxLua/bindings/wxwidgets/image.i,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** image.i 9 Mar 2007 00:15:12 -0000 1.18 --- image.i 12 Mar 2007 23:12:31 -0000 1.19 *************** *** 47,50 **** --- 47,53 ---- wxBITMAP_TYPE_ICON wxBITMAP_TYPE_ICON_RESOURCE + wxBITMAP_TYPE_ANI + wxBITMAP_TYPE_IFF + %wxchkver_2_8 wxBITMAP_TYPE_TGA wxBITMAP_TYPE_MACCURSOR wxBITMAP_TYPE_MACCURSOR_RESOURCE Index: gdi.i =================================================================== RCS file: /cvsroot/wxlua/wxLua/bindings/wxwidgets/gdi.i,v retrieving revision 1.40 retrieving revision 1.41 diff -C2 -d -r1.40 -r1.41 *** gdi.i 9 Mar 2007 00:15:12 -0000 1.40 --- gdi.i 12 Mar 2007 23:12:31 -0000 1.41 *************** *** 43,46 **** --- 43,56 ---- //----------------------------------------------------------------------------- + // wxRealPoint - Used nowhere in wxWidgets + + //%class %delete %noclassinfo %encapsulate wxRealPoint + // wxRealPoint(double xx = 0, double yy = 0) + // + // %rename X %member double x // GetX() and SetX(int x) + // %rename Y %member double y // GetY() and SetY(int y) + //%endclass + + //----------------------------------------------------------------------------- // wxSize *************** *** 51,59 **** --- 61,76 ---- %overload %constructor wxSizeCopy(const wxSize& size) + %wxchkver_2_8 void DecBy(int dx, int dy) + //%wxchkver_2_8 void DecBy(const wxSize& sz) + //%wxchkver_2_8 void DecBy(int d) void DecTo(const wxSize& sz) bool IsFullySpecified() const int GetHeight() const int GetWidth() const + %wxchkver_2_8 void IncBy(int dx, int dy) + //%wxchkver_2_8 void IncBy(const wxSize& sz) + //%wxchkver_2_8 void IncBy(int d) void IncTo(const wxSize& sz) + %wxchkver_2_8 wxSize& Scale(float xscale, float yscale) void Set(int width, int height) void SetDefaults(const wxSize& size) *************** *** 75,78 **** --- 92,96 ---- %overload %constructor wxRectFromSize(const wxSize& size) + %wxchkver_2_8 wxRect CentreIn(const wxRect& r, int dir = wxBOTH) const // CenterIn %wxchkver_2_7 %overload bool Contains(wxCoord dx, wxCoord dy) const %wxchkver_2_7 %overload %rename ContainsPoint bool Contains(const wxPoint& pt) const *************** *** 83,88 **** int GetLeft() wxPoint GetPosition() ! wxPoint GetTopLeft() const //wxPoint GetLeftTop() const ! wxPoint GetBottomRight() const //wxPoint GetRightBottom() const int GetRight() wxSize GetSize() --- 101,108 ---- int GetLeft() wxPoint GetPosition() ! wxPoint GetTopLeft() const // GetLeftTop ! %wxchkver_2_8 wxPoint GetTopRight() const // GetRightTop ! wxPoint GetBottomRight() const // GetRightBottom ! %wxchkver_2_8 wxPoint GetBottomLeft() const // GetLeftBottom int GetRight() wxSize GetSize() *************** *** 100,108 **** void SetLeft(int left) void SetPosition(const wxPoint &p) ! void SetBottomRight(const wxPoint &p) ! void SetRightBottom(const wxPoint &p) void SetRight(int right) void SetSize(const wxSize &s) void SetTop(int top) void SetWidth(int width) void SetX(int X) --- 120,129 ---- void SetLeft(int left) void SetPosition(const wxPoint &p) ! %wxchkver_2_8 void SetBottomLeft(const wxPoint &p) // SetLeftBottom ! void SetBottomRight(const wxPoint &p) // SetRightBottom void SetRight(int right) void SetSize(const wxSize &s) void SetTop(int top) + %wxchkver_2_8 void SetTopRight(const wxPoint &p) // SetRightTop void SetWidth(int width) void SetX(int X) *************** *** 128,132 **** %class %delete wxGDIObject, wxObject ! //wxGDIObject() //bool GetVisible() these are NOT USED and have been removed in 2.7 //void SetVisible(bool visible) --- 149,154 ---- %class %delete wxGDIObject, wxObject ! //wxGDIObject() - base class, no constructor since it doesn't do anything ! //bool GetVisible() these are NOT USED and have been removed in 2.7 //void SetVisible(bool visible) *************** *** 274,321 **** %enum wxFontEncoding ! wxFONTENCODING_SYSTEM ! wxFONTENCODING_DEFAULT ! wxFONTENCODING_ISO8859_1 ! wxFONTENCODING_ISO8859_2 ! wxFONTENCODING_ISO8859_3 ! wxFONTENCODING_ISO8859_4 ! wxFONTENCODING_ISO8859_5 ! wxFONTENCODING_ISO8859_6 ! wxFONTENCODING_ISO8859_7 ! wxFONTENCODING_ISO8859_8 ! wxFONTENCODING_ISO8859_9 ! wxFONTENCODING_ISO8859_10 ! wxFONTENCODING_ISO8859_11 ! wxFONTENCODING_ISO8859_12 ! wxFONTENCODING_ISO8859_13 ! wxFONTENCODING_ISO8859_14 ! wxFONTENCODING_ISO8859_15 wxFONTENCODING_ISO8859_MAX ! wxFONTENCODING_KOI8 ! wxFONTENCODING_ALTERNATIVE ! wxFONTENCODING_BULGARIAN ! wxFONTENCODING_CP437 ! wxFONTENCODING_CP850 ! wxFONTENCODING_CP852 ! wxFONTENCODING_CP855 ! wxFONTENCODING_CP866 ! wxFONTENCODING_CP874 ! wxFONTENCODING_CP932 ! wxFONTENCODING_CP936 ! wxFONTENCODING_CP949 ! wxFONTENCODING_CP950 ! wxFONTENCODING_CP1250 ! wxFONTENCODING_CP1251 ! wxFONTENCODING_CP1252 ! wxFONTENCODING_CP1253 ! wxFONTENCODING_CP1254 ! wxFONTENCODING_CP1255 ! wxFONTENCODING_CP1256 ! wxFONTENCODING_CP1257 wxFONTENCODING_CP12_MAX ! wxFONTENCODING_UTF7 ! wxFONTENCODING_UTF8 wxFONTENCODING_UNICODE ! wxFONTENCODING_MAX %endenum --- 296,420 ---- %enum wxFontEncoding ! wxFONTENCODING_SYSTEM // system default ! wxFONTENCODING_DEFAULT // current default encoding ! ! // ISO8859 standard defines a number of single-byte charsets ! wxFONTENCODING_ISO8859_1 // West European (Latin1) ! wxFONTENCODING_ISO8859_2 // Central and East European (Latin2) ! wxFONTENCODING_ISO8859_3 // Esperanto (Latin3) ! wxFONTENCODING_ISO8859_4 // Baltic (old) (Latin4) ! wxFONTENCODING_ISO8859_5 // Cyrillic ! wxFONTENCODING_ISO8859_6 // Arabic ! wxFONTENCODING_ISO8859_7 // Greek ! wxFONTENCODING_ISO8859_8 // Hebrew ! wxFONTENCODING_ISO8859_9 // Turkish (Latin5) ! wxFONTENCODING_ISO8859_10 // Variation of Latin4 (Latin6) ! wxFONTENCODING_ISO8859_11 // Thai ! wxFONTENCODING_ISO8859_12 // doesn't exist currently, but put it ! // here anyhow to make all ISO8859 ! // consecutive numbers ! wxFONTENCODING_ISO8859_13 // Baltic (Latin7) ! wxFONTENCODING_ISO8859_14 // Latin8 ! wxFONTENCODING_ISO8859_15 // Latin9 (a.k.a. Latin0, includes euro) wxFONTENCODING_ISO8859_MAX ! ! // Cyrillic charset soup (see http://czyborra.com/charsets/cyrillic.html) ! wxFONTENCODING_KOI8 // KOI8 Russian ! wxFONTENCODING_KOI8_U // KOI8 Ukrainian ! wxFONTENCODING_ALTERNATIVE // same as MS-DOS CP866 ! wxFONTENCODING_BULGARIAN // used under Linux in Bulgaria ! ! // what would we do without Microsoft? They have their own encodings ! // for DOS ! wxFONTENCODING_CP437 // original MS-DOS codepage ! wxFONTENCODING_CP850 // CP437 merged with Latin1 ! wxFONTENCODING_CP852 // CP437 merged with Latin2 ! wxFONTENCODING_CP855 // another cyrillic encoding ! wxFONTENCODING_CP866 // and another one ! // and for Windows ! wxFONTENCODING_CP874 // WinThai ! wxFONTENCODING_CP932 // Japanese (shift-JIS) ! wxFONTENCODING_CP936 // Chinese simplified (GB) ! wxFONTENCODING_CP949 // Korean (Hangul charset) ! wxFONTENCODING_CP950 // Chinese (traditional - Big5) ! wxFONTENCODING_CP1250 // WinLatin2 ! wxFONTENCODING_CP1251 // WinCyrillic ! wxFONTENCODING_CP1252 // WinLatin1 ! wxFONTENCODING_CP1253 // WinGreek (8859-7) ! wxFONTENCODING_CP1254 // WinTurkish ! wxFONTENCODING_CP1255 // WinHebrew ! wxFONTENCODING_CP1256 // WinArabic ! wxFONTENCODING_CP1257 // WinBaltic (same as Latin 7) wxFONTENCODING_CP12_MAX ! ! wxFONTENCODING_UTF7 // UTF-7 Unicode encoding ! wxFONTENCODING_UTF8 // UTF-8 Unicode encoding ! wxFONTENCODING_EUC_JP // Extended Unix Codepage for Japanese ! wxFONTENCODING_UTF16BE // UTF-16 Big Endian Unicode encoding ! wxFONTENCODING_UTF16LE // UTF-16 Little Endian Unicode encoding ! wxFONTENCODING_UTF32BE // UTF-32 Big Endian Unicode encoding ! wxFONTENCODING_UTF32LE // UTF-32 Little Endian Unicode encoding ! ! wxFONTENCODING_MACROMAN // the standard mac encodings ! wxFONTENCODING_MACJAPANESE ! wxFONTENCODING_MACCHINESETRAD ! wxFONTENCODING_MACKOREAN ! wxFONTENCODING_MACARABIC ! wxFONTENCODING_MACHEBREW ! wxFONTENCODING_MACGREEK ! wxFONTENCODING_MACCYRILLIC ! wxFONTENCODING_MACDEVANAGARI ! wxFONTENCODING_MACGURMUKHI ! wxFONTENCODING_MACGUJARATI ! wxFONTENCODING_MACORIYA ! wxFONTENCODING_MACBENGALI ! wxFONTENCODING_MACTAMIL ! wxFONTENCODING_MACTELUGU ! wxFONTENCODING_MACKANNADA ! wxFONTENCODING_MACMALAJALAM ! wxFONTENCODING_MACSINHALESE ! wxFONTENCODING_MACBURMESE ! wxFONTENCODING_MACKHMER ! wxFONTENCODING_MACTHAI ! wxFONTENCODING_MACLAOTIAN ! wxFONTENCODING_MACGEORGIAN ! wxFONTENCODING_MACARMENIAN ! wxFONTENCODING_MACCHINESESIMP ! wxFONTENCODING_MACTIBETAN ! wxFONTENCODING_MACMONGOLIAN ! wxFONTENCODING_MACETHIOPIC ! wxFONTENCODING_MACCENTRALEUR ! wxFONTENCODING_MACVIATNAMESE ! wxFONTENCODING_MACARABICEXT ! wxFONTENCODING_MACSYMBOL ! wxFONTENCODING_MACDINGBATS ! wxFONTENCODING_MACTURKISH ! wxFONTENCODING_MACCROATIAN ! wxFONTENCODING_MACICELANDIC ! wxFONTENCODING_MACROMANIAN ! wxFONTENCODING_MACCELTIC ! wxFONTENCODING_MACGAELIC ! wxFONTENCODING_MACKEYBOARD ! ! wxFONTENCODING_MAX // highest enumerated encoding value ! ! wxFONTENCODING_MACMIN //= wxFONTENCODING_MACROMAN , ! wxFONTENCODING_MACMAX //= wxFONTENCODING_MACKEYBOARD , ! ! // aliases for endian-dependent UTF encodings ! wxFONTENCODING_UTF16 // native UTF-16 ! wxFONTENCODING_UTF32 // native UTF-32 ! ! // alias for the native Unicode encoding on this platform ! // (this is used by wxEncodingConverter and wxUTFFile only for now) wxFONTENCODING_UNICODE ! ! // alternative names for Far Eastern encodings ! // Chinese ! wxFONTENCODING_GB2312 // Simplified Chinese ! wxFONTENCODING_BIG5 // Traditional Chinese ! ! // Japanese (see http://zsigri.tripod.com/fontboard/cjk/jis.html) ! wxFONTENCODING_SHIFT_JIS // Shift JIS %endenum *************** *** 348,354 **** bool Ok() static void SetDefaultEncoding(wxFontEncoding encoding) ! void SetFaceName(const wxString& faceName) void SetFamily(int family) void SetNativeFontInfo(const wxString& info) void SetPointSize(int pointSize) void SetStyle(int style) --- 447,456 ---- bool Ok() static void SetDefaultEncoding(wxFontEncoding encoding) ! !%wxchkver_2_8 void SetFaceName(const wxString& faceName) ! %wxchkver_2_8 bool SetFaceName(const wxString& faceName) void SetFamily(int family) void SetNativeFontInfo(const wxString& info) + %wxchkver_2_8 %rename SetNativeFontInfoString bool SetNativeFontInfo(const wxString& info) + %wxchkver_2_8 bool SetNativeFontInfoUserDesc(const wxString& info) void SetPointSize(int pointSize) void SetStyle(int style) *************** *** 365,368 **** --- 467,517 ---- %endclass + //----------------------------------------------------------------------------- + // wxNativeFontInfo + + %include "wx/fontutil.h" + + %class %noclassinfo %encapsulate wxNativeFontInfo + wxNativeFontInfo() + %constructor wxNativeFontInfoCopy(const wxNativeFontInfo& info) + + // accessors and modifiers for the font elements + int GetPointSize() const + wxSize GetPixelSize() const + wxFontStyle GetStyle() const + wxFontWeight GetWeight() const + bool GetUnderlined() const + wxString GetFaceName() const + wxFontFamily GetFamily() const + wxFontEncoding GetEncoding() const + + void SetPointSize(int pointsize) + void SetPixelSize(const wxSize& pixelSize) + void SetStyle(wxFontStyle style) + void SetWeight(wxFontWeight weight) + void SetUnderlined(bool underlined) + %wxchkver_2_8 bool SetFaceName(const wxString& facename) + !%wxchkver_2_8 void SetFaceName(const wxString& facename) + void SetFamily(wxFontFamily family) + void SetEncoding(wxFontEncoding encoding) + + // sets the first facename in the given array which is found + // to be valid. If no valid facename is given, sets the + // first valid facename returned by wxFontEnumerator::GetFacenames(). + // Does not return a bool since it cannot fail. + %wxchkver_2_8 %rename SetFaceNameFromArray void SetFaceName(const wxArrayString_FromLuaTable& facenames) + + // it is important to be able to serialize wxNativeFontInfo objects to be + // able to store them (in config file, for example) + bool FromString(const wxString& s); + wxString ToString() const + + // we also want to present the native font descriptions to the user in some + // human-readable form (it is not platform independent neither, but can + // hopefully be understood by the user) + bool FromUserString(const wxString& s) + wxString ToUserString() const + %endclass + %endif //wxLUA_USE_wxFont *************** *** 380,388 **** virtual bool EnumerateEncodings( const wxString &font = "" ) ! %wxchkver_2_7 static wxArrayString GetEncodings() ! %wxchkver_2_7 static wxArrayString GetFacenames() !%wxchkver_2_7 wxArrayString* GetEncodings() !%wxchkver_2_7 wxArrayString* GetFacenames() %win %property=Encodings, read %win %property=Facenames, read --- 529,541 ---- virtual bool EnumerateEncodings( const wxString &font = "" ) ! %wxchkver_2_7 static wxArrayString GetEncodings(const wxString& facename = "") ! %wxchkver_2_7 static wxArrayString GetFacenames(wxFontEncoding encoding = wxFONTENCODING_SYSTEM, bool fixedWidthOnly = false) !%wxchkver_2_7 wxArrayString* GetEncodings() !%wxchkver_2_7 wxArrayString* GetFacenames() + // Use GetEncodings/Facenames after calling EnumerateXXX + //virtual bool OnFacename(const wxString& facename) + //virtual bool OnFontEncoding(const wxString& facename, const wxString& encoding) + %win %property=Encodings, read %win %property=Facenames, read *************** *** 399,403 **** %define %pointer wxTheFontList ! // Only use FindOrCreateFont - deprecated in >2.7 //void AddFont(wxFont* font) wxFont* FindOrCreateFont(int pointSize, int family, int style, int weight, bool underline = false, const wxString &faceName = "", wxFontEncoding encoding = wxFONTENCODING_DEFAULT) --- 552,556 ---- %define %pointer wxTheFontList ! // Only use FindOrCreateFont - others deprecated in >2.7 //void AddFont(wxFont* font) wxFont* FindOrCreateFont(int pointSize, int family, int style, int weight, bool underline = false, const wxString &faceName = "", wxFontEncoding encoding = wxFONTENCODING_DEFAULT) *************** *** 418,425 **** wxFontEncoding CharsetToEncoding(const wxString &charset, bool interactive = true) ! static wxFontMapper *Get() // %override [bool, wxFontEncoding *altEncoding] GetAltForEncoding(wxFontEncoding encoding, const wxString &faceName = "", bool interactive = true) bool GetAltForEncoding(wxFontEncoding encoding, wxFontEncoding *altEncoding, const wxString &faceName = "", bool interactive = true) // %rename GetAltForEncodingInternal bool GetAltForEncoding(wxFontEncoding encoding, wxNativeEncodingInfo *info, const wxString &faceName = "", bool interactive = true) static wxFontEncoding GetEncoding(size_t n) static wxString GetEncodingDescription(wxFontEncoding encoding) --- 571,579 ---- wxFontEncoding CharsetToEncoding(const wxString &charset, bool interactive = true) ! %staticonly wxFontMapper *Get() // %override [bool, wxFontEncoding *altEncoding] GetAltForEncoding(wxFontEncoding encoding, const wxString &faceName = "", bool interactive = true) bool GetAltForEncoding(wxFontEncoding encoding, wxFontEncoding *altEncoding, const wxString &faceName = "", bool interactive = true) // %rename GetAltForEncodingInternal bool GetAltForEncoding(wxFontEncoding encoding, wxNativeEncodingInfo *info, const wxString &faceName = "", bool interactive = true) + static wxString GetDefaultConfigPath() static wxFontEncoding GetEncoding(size_t n) static wxString GetEncodingDescription(wxFontEncoding encoding) *************** *** 428,431 **** --- 582,586 ---- static size_t GetSupportedEncodingsCount() bool IsEncodingAvailable(wxFontEncoding encoding, const wxString &facename = "") + %wxchkver_2_8 static void Reset() void SetDialogParent(wxWindow *parent) void SetDialogTitle(const wxString &title) *************** *** 641,644 **** --- 796,861 ---- %endif //wxLUA_USE_wxBrushList + + + //----------------------------------------------------------------------------- + // wxStockGDI + + %include "wx/gdicmn.h" + + %if %wxchkver_2_8 + + %enum wxStockGDI::Item + BRUSH_BLACK + BRUSH_BLUE + BRUSH_CYAN + BRUSH_GREEN + BRUSH_GREY + BRUSH_LIGHTGREY + BRUSH_MEDIUMGREY + BRUSH_RED + BRUSH_TRANSPARENT + BRUSH_WHITE + COLOUR_BLACK + COLOUR_BLUE + COLOUR_CYAN + COLOUR_GREEN + COLOUR_LIGHTGREY + COLOUR_RED + COLOUR_WHITE + CURSOR_CROSS + CURSOR_HOURGLASS + CURSOR_STANDARD + FONT_ITALIC + FONT_NORMAL + FONT_SMALL + FONT_SWISS + PEN_BLACK + PEN_BLACKDASHED + PEN_CYAN + PEN_GREEN + PEN_GREY + PEN_LIGHTGREY + PEN_MEDIUMGREY + PEN_RED + PEN_TRANSPARENT + PEN_WHITE + ITEMCOUNT + %endenum + + %class %noclassinfo %encapsulate wxStockGDI + wxStockGDI() + + //static void DeleteAll() + %staticonly wxStockGDI& instance() + + static const wxBrush* GetBrush(wxStockGDI::Item item) + static const wxColour* GetColour(wxStockGDI::Item item) + static const wxCursor* GetCursor(wxStockGDI::Item item) + // Can be overridden by platform-specific derived classes + virtual const wxFont* GetFont(wxStockGDI::Item item) + static const wxPen* GetPen(wxStockGDI::Item item) + %endclass + + %endif // %wxchkver_2_8 %endif //wxLUA_USE_wxColourPenBrush *************** *** 700,703 **** --- 917,922 ---- // wxIconBundle + %include "wx/iconbndl.h" + %class %delete %noclassinfo %encapsulate wxIconBundle %constructor wxDefaultIconBundle() *************** *** 714,717 **** --- 933,958 ---- %endclass + //----------------------------------------------------------------------------- + // wxIconLocation + + %include "wx/iconloc.h" + + %class %noclassinfo %encapsulate wxIconLocation + // ctor takes the name of the file where the icon is + !%msw wxIconLocation(const wxString& filename = "") + %msw wxIconLocation(const wxString& file = "", int num = 0) + + // returns true if this object is valid/initialized + bool IsOk() const + + // set/get the icon file name + void SetFileName(const wxString& filename) + const wxString& GetFileName() const + + // set/get the icon index + %msw void SetIndex(int num) + %msw int GetIndex() const + %endclass + %endif //wxLUA_USE_wxIcon *************** *** 819,823 **** wxCURSOR_DEFAULT %mac wxCURSOR_COPY_ARROW ! // FIXME some missing wxCURSOR_XXX for X11 wxCURSOR_ARROWWAIT wxCURSOR_MAX --- 1060,1072 ---- wxCURSOR_DEFAULT %mac wxCURSOR_COPY_ARROW ! ! %if defined(__X__) ! // Not yet implemented for Windows ! wxCURSOR_CROSS_REVERSE, ! wxCURSOR_DOUBLE_ARROW, ! wxCURSOR_BASED_ARROW_UP, ! wxCURSOR_BASED_ARROW_DOWN, ! %endif // X11 ! wxCURSOR_ARROWWAIT wxCURSOR_MAX *************** *** 1293,1296 **** --- 1542,1547 ---- %if wxLUA_USE_wxGLCanvas & wxUSE_GLCANVAS + // FIXME : Need to wrap wxGLApp? + %include "wx/glcanvas.h" Index: html.i =================================================================== RCS file: /cvsroot/wxlua/wxLua/bindings/wxwidgets/html.i,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** html.i 9 Mar 2007 00:15:12 -0000 1.14 --- html.i 12 Mar 2007 23:12:31 -0000 1.15 *************** *** 321,325 **** %endclass ! %endif //----------------------------------------------------------------------------- --- 321,352 ---- %endclass ! // ---------------------------------------------------------------------------- ! // wxSimpleHtmlListBox - Use this instead of having to override virtual functions in wxHtmlListBox ! ! %include "wx/htmllbox.h" ! ! %define wxHLB_DEFAULT_STYLE ! %define wxHLB_MULTIPLE ! ! %class wxSimpleHtmlListBox, wxHtmlWindowInterface //: public wxHtmlListBox, public wxItemContainer ! %constructor wxSimpleHtmlListBoxDefault() ! wxSimpleHtmlListBox(wxWindow *parent, wxWindowID id, const wxPoint& pos, const wxSize& size, const wxArrayString_FromLuaTable& choices, long style = wxHLB_DEFAULT_STYLE, const wxValidator& validator = wxDefaultValidator, const wxString& name = "wxSimpleHtmlListBox") ! ! bool Create(wxWindow *parent, wxWindowID id, const wxPoint& pos, const wxSize& size, const wxArrayString_FromLuaTable& choices, long style = wxHLB_DEFAULT_STYLE, const wxValidator& validator = wxDefaultValidator, const wxString& name = "wxSimpleHtmlListBox") ! void SetSelection(int n) ! int GetSelection() const ! virtual unsigned int GetCount() const ! virtual wxString GetString(unsigned int n) const ! wxArrayString GetStrings() const ! virtual void SetString(unsigned int n, const wxString& s) ! virtual void Clear() ! virtual void Delete(unsigned int n) ! %rename AppendStrings void Append(const wxArrayString_FromLuaTable& strings) ! int Append(const wxString& item) ! //int Append(const wxString& item, void *clientData) ! //int Append(const wxString& item, wxClientData *clientData) ! %endclass ! ! %endif //%wxchkver_2_7 //----------------------------------------------------------------------------- Index: dialogs.i =================================================================== RCS file: /cvsroot/wxlua/wxLua/bindings/wxwidgets/dialogs.i,v retrieving revision 1.25 retrieving revision 1.26 diff -C2 -d -r1.25 -r1.26 *** dialogs.i 9 Mar 2007 00:15:12 -0000 1.25 --- dialogs.i 12 Mar 2007 23:12:31 -0000 1.26 *************** *** 19,22 **** --- 19,23 ---- %define wxICON_WARNING + %if %wxcompat_2_6 %enum // for wxFileSelector and wxFileDialog wxOPEN *************** *** 28,31 **** --- 29,47 ---- wxCHANGE_DIR %endenum + %endif //%wxcompat_2_6 + + %if %wxchkver_2_8 + %enum + wxFD_OPEN + wxFD_SAVE + wxFD_OVERWRITE_PROMPT + wxFD_FILE_MUST_EXIST + wxFD_MULTIPLE + wxFD_CHANGE_DIR + wxFD_PREVIEW + + wxFD_DEFAULT_STYLE + %endenum + %endif //%wxchkver_2_8 //----------------------------------------------------------------------------- *************** *** 41,45 **** wxUSE_COLOURDLG&&!%wxchkver_2_8 %function wxColour wxGetColourFromUser(wxWindow *parent, const wxColour& colInit) wxUSE_COLOURDLG&&%wxchkver_2_8 %function wxColour wxGetColourFromUser(wxWindow *parent, const wxColour& colInit, const wxString& caption = "") ! wxUSE_FONTDLG %function wxFont wxGetFontFromUser(wxWindow *parent, const wxFont& fontInit) // %override [int, lua int table] wxGetMultipleChoices(const wxString& message, const wxString& caption, lua string table, wxWindow *parent = NULL, int x = -1, int y = -1, bool centre = true, int width=150, int height=200) wxUSE_CHOICEDLG %function int wxGetMultipleChoices(const wxString& message, const wxString& caption, int n, const wxString choices[], int nsel, int *selection, wxWindow *parent = NULL, int x = -1, int y = -1, bool centre = true, int width=150, int height=200) --- 57,62 ---- wxUSE_COLOURDLG&&!%wxchkver_2_8 %function wxColour wxGetColourFromUser(wxWindow *parent, const wxColour& colInit) wxUSE_COLOURDLG&&%wxchkver_2_8 %function wxColour wxGetColourFromUser(wxWindow *parent, const wxColour& colInit, const wxString& caption = "") ! !%wxchkver_2_8&&wxUSE_FONTDLG %function wxFont wxGetFontFromUser(wxWindow *parent, const wxFont& fontInit) ! %wxchkver_2_8&&wxUSE_FONTDLG %function wxFont wxGetFontFromUser(wxWindow *parent = NULL, const wxFont& fontInit = wxNullFont, const wxString& caption = "") // %override [int, lua int table] wxGetMultipleChoices(const wxString& message, const wxString& caption, lua string table, wxWindow *parent = NULL, int x = -1, int y = -1, bool centre = true, int width=150, int height=200) wxUSE_CHOICEDLG %function int wxGetMultipleChoices(const wxString& message, const wxString& caption, int n, const wxString choices[], int nsel, int *selection, wxWindow *parent = NULL, int x = -1, int y = -1, bool centre = true, int width=150, int height=200) *************** *** 220,225 **** %class wxFileDialog, wxDialog ! wxFileDialog(wxWindow* parent, const wxString& message = "Choose a file", const wxString& defaultDir = "", const wxString& defaultFile = "", const wxString& wildcard = "*.*", long style = 0, const wxPoint& pos = wxDefaultPosition) wxString GetDirectory() const wxString GetFilename() const --- 237,245 ---- %class wxFileDialog, wxDialog ! %constructor wxFileDialogDefault() ! !%wxchkver_2_8 wxFileDialog(wxWindow* parent, const wxString& message = "Choose a file", const wxString& defaultDir = "", const wxString& defaultFile = "", const wxString& wildcard = "*.*", long style = 0, const wxPoint& pos = wxDefaultPosition) ! %wxchkver_2_8 wxFileDialog(wxWindow *parent, const wxString& message = wxFileSelectorPromptStr, const wxString& defaultDir = "", const wxString& defaultFile = "", const wxString& wildCard = wxFileSelectorDefaultWildcardStr, long style = wxFD_DEFAULT_STYLE, const wxPoint& pos = wxDefaultPosition, const wxSize& sz = wxDefaultSize, const wxString& name = "wxFileDialog") + %wxchkver_2_8 bool Create(wxWindow *parent, const wxString& message = wxFileSelectorPromptStr, const wxString& defaultDir = "", const wxString& defaultFile = "", const wxString& wildCard = wxFileSelectorDefaultWildcardStr, long style = wxFD_DEFAULT_STYLE, const wxPoint& pos = wxDefaultPosition, const wxSize& sz = wxDefaultSize, const wxString& name = "wxFileDialog") wxString GetDirectory() const wxString GetFilename() const Index: controls.i =================================================================== RCS file: /cvsroot/wxlua/wxLua/bindings/wxwidgets/controls.i,v retrieving revision 1.30 retrieving revision 1.31 diff -C2 -d -r1.30 -r1.31 *** controls.i 9 Mar 2007 06:10:15 -0000 1.30 --- controls.i 12 Mar 2007 23:12:30 -0000 1.31 *************** *** 240,244 **** %define wxGA_HORIZONTAL ! %define wxGA_PROGRESSBAR %define wxGA_SMOOTH %define wxGA_VERTICAL --- 240,244 ---- %define wxGA_HORIZONTAL ! %wxcompat_2_6 %define wxGA_PROGRESSBAR %define wxGA_SMOOTH %define wxGA_VERTICAL *************** *** 254,257 **** --- 254,258 ---- int GetValue() const bool IsVertical() const + %wxchkver_2_8 void Pulse() void SetBezelFace(int width) void SetRange(int range) Index: defsutil.i =================================================================== RCS file: /cvsroot/wxlua/wxLua/bindings/wxwidgets/defsutil.i,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -d -r1.33 -r1.34 *** defsutil.i 9 Mar 2007 00:15:12 -0000 1.33 --- defsutil.i 12 Mar 2007 23:12:31 -0000 1.34 *************** *** 196,205 **** --- 196,209 ---- // %override [int x, int y, int width, int height] wxClientDisplayRect() %function void wxClientDisplayRect(int *x, int *y, int *width, int *height) + %function wxRect wxGetClientDisplayRect() %function bool wxColourDisplay() %function int wxDisplayDepth() // %override [int width, int height] wxDisplaySize() %function void wxDisplaySize(int *width, int *height) + %function wxSize wxGetDisplaySize() // %override [int width, int height] wxDisplaySizeMM() %function void wxDisplaySizeMM(int *width, int *height) + %function wxSize wxGetDisplaySizeMM() + %function void wxSetCursor(const wxCursor &cursor) // %function wxIconOrCursor wxDROP_ICON(wxString name) |