From 1777b9bbf4573dabecf4a3256d0d3c2c0c2a3fdf Mon Sep 17 00:00:00 2001 From: David Webster Date: Wed, 28 Jul 1999 03:38:12 +0000 Subject: [PATCH] *** empty log message *** git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@3173 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/accel.h | 2 + include/wx/app.h | 2 + include/wx/bitmap.h | 2 + include/wx/bmpbuttn.h | 2 + include/wx/brush.h | 2 + include/wx/button.h | 2 + include/wx/checkbox.h | 2 + include/wx/checklst.h | 2 + include/wx/choice.h | 2 + include/wx/clipbrd.h | 2 + include/wx/cmndata.h | 4 +- include/wx/colordlg.h | 2 + include/wx/colour.h | 2 + include/wx/combobox.h | 2 + include/wx/control.h | 2 + include/wx/cursor.h | 2 + include/wx/dataobj.h | 2 + include/wx/dc.h | 2 + include/wx/dcclient.h | 2 + include/wx/dcmemory.h | 2 + include/wx/dcprint.h | 3 + include/wx/dcscreen.h | 2 + include/wx/dde.h | 2 + include/wx/defs.h | 38 ++- include/wx/dialog.h | 2 + include/wx/dirdlg.h | 2 + include/wx/dnd.h | 2 + include/wx/dragimag.h | 2 + include/wx/dynarray.h | 4 +- include/wx/dynlib.h | 4 + include/wx/filedlg.h | 2 + include/wx/filefn.h | 4 +- include/wx/font.h | 2 + include/wx/fontdlg.h | 4 + include/wx/frame.h | 2 + include/wx/gauge.h | 2 + include/wx/gdicmn.h | 3 + include/wx/gdiobj.h | 2 + include/wx/icon.h | 2 + include/wx/imaglist.h | 2 + include/wx/joystick.h | 2 + include/wx/listbox.h | 2 + include/wx/listctrl.h | 2 + include/wx/mdi.h | 2 + include/wx/menu.h | 2 + include/wx/menuitem.h | 2 + include/wx/metafile.h | 3 + include/wx/minifram.h | 2 + include/wx/msgdlg.h | 2 + include/wx/notebook.h | 2 + include/wx/palette.h | 2 + include/wx/pen.h | 2 + include/wx/pnghand.h | 2 + include/wx/printdlg.h | 2 + include/wx/radiobox.h | 2 + include/wx/radiobut.h | 2 + include/wx/region.h | 2 + include/wx/sckstrm.h | 2 +- include/wx/scrolbar.h | 2 + include/wx/settings.h | 2 + include/wx/setup.h | 6 +- include/wx/slider.h | 2 + include/wx/spinbutt.h | 2 + include/wx/statbmp.h | 2 + include/wx/statbox.h | 2 + include/wx/statline.h | 2 + include/wx/stattext.h | 2 + include/wx/string.h | 2 + include/wx/tabctrl.h | 2 + include/wx/taskbar.h | 2 + include/wx/tbar95.h | 2 + include/wx/tbarmsw.h | 2 + include/wx/textctrl.h | 2 + include/wx/thread.h | 4 +- include/wx/timer.h | 2 + include/wx/toolbar.h | 2 + include/wx/tooltip.h | 2 + include/wx/treectrl.h | 2 + include/wx/version.h | 2 +- include/wx/wave.h | 2 + include/wx/window.h | 2 + include/wx/wxchar.h | 693 +++++++++++++++++++++--------------------- include/wx/wxprec.h | 7 +- include/wx/xpmhand.h | 7 +- 84 files changed, 560 insertions(+), 364 deletions(-) diff --git a/include/wx/accel.h b/include/wx/accel.h index a36d4a0a44..cc3423b721 100644 --- a/include/wx/accel.h +++ b/include/wx/accel.h @@ -11,6 +11,8 @@ #include "wx/qt/accel.h" #elif defined(__WXMAC__) #include "wx/mac/accel.h" +#elif defined(__WXPM__) +#include "wx/os2/accel.h" #elif defined(__WXSTUBS__) #include "wx/stubs/accel.h" #endif diff --git a/include/wx/app.h b/include/wx/app.h index 85e28145a8..7deb0a45a7 100644 --- a/include/wx/app.h +++ b/include/wx/app.h @@ -246,6 +246,8 @@ protected: #include "wx/gtk/app.h" #elif defined(__WXMAC__) #include "wx/mac/app.h" +#elif defined(__WXPM__) + #include "wx/os2/app.h" #elif defined(__WXSTUBS__) #include "wx/stubs/app.h" #endif diff --git a/include/wx/bitmap.h b/include/wx/bitmap.h index f031e7041a..f9118cb55e 100644 --- a/include/wx/bitmap.h +++ b/include/wx/bitmap.h @@ -11,6 +11,8 @@ #include "wx/qt/bitmap.h" #elif defined(__WXMAC__) #include "wx/mac/bitmap.h" +#elif defined(__WXPM__) +#include "wx/os2/bitmap.h" #elif defined(__WXSTUBS__) #include "wx/stubs/bitmap.h" #endif diff --git a/include/wx/bmpbuttn.h b/include/wx/bmpbuttn.h index 2ff65ebbb2..f753cd2409 100644 --- a/include/wx/bmpbuttn.h +++ b/include/wx/bmpbuttn.h @@ -11,6 +11,8 @@ #include "wx/qt/bmpbuttn.h" #elif defined(__WXMAC__) #include "wx/mac/bmpbuttn.h" +#elif defined(__WXPM__) +#include "wx/os2/bmpbuttn.h" #elif defined(__WXSTUBS__) #include "wx/stubs/bmpbuttn.h" #endif diff --git a/include/wx/brush.h b/include/wx/brush.h index e5d99b39a1..3955876d1d 100644 --- a/include/wx/brush.h +++ b/include/wx/brush.h @@ -11,6 +11,8 @@ #include "wx/qt/brush.h" #elif defined(__WXMAC__) #include "wx/mac/brush.h" +#elif defined(__WXPM__) +#include "wx/os2/brush.h" #elif defined(__WXSTUBS__) #include "wx/stubs/brush.h" #endif diff --git a/include/wx/button.h b/include/wx/button.h index 454a0a58f6..31d4e12d0a 100644 --- a/include/wx/button.h +++ b/include/wx/button.h @@ -11,6 +11,8 @@ #include "wx/qt/button.h" #elif defined(__WXMAC__) #include "wx/mac/button.h" +#elif defined(__WXPM__) +#include "wx/os2/button.h" #elif defined(__WXSTUBS__) #include "wx/stubs/button.h" #endif diff --git a/include/wx/checkbox.h b/include/wx/checkbox.h index 47895df8cd..ac6e7e992b 100644 --- a/include/wx/checkbox.h +++ b/include/wx/checkbox.h @@ -11,6 +11,8 @@ #include "wx/qt/checkbox.h" #elif defined(__WXMAC__) #include "wx/mac/checkbox.h" +#elif defined(__WXPM__) +#include "wx/os2/checkbox.h" #elif defined(__WXSTUBS__) #include "wx/stubs/checkbox.h" #endif diff --git a/include/wx/checklst.h b/include/wx/checklst.h index 96f31e454f..4528bb8f84 100644 --- a/include/wx/checklst.h +++ b/include/wx/checklst.h @@ -11,6 +11,8 @@ #include "wx/qt/checklst.h" #elif defined(__WXMAC__) #include "wx/mac/checklst.h" +#elif defined(__WXPM__) +#include "wx/os2/checklst.h" #elif defined(__WXSTUBS__) #include "wx/stubs/checklst.h" #endif diff --git a/include/wx/choice.h b/include/wx/choice.h index 9940c9f69f..bfe28e0ed1 100644 --- a/include/wx/choice.h +++ b/include/wx/choice.h @@ -120,6 +120,8 @@ private: #include "wx/qt/choice.h" #elif defined(__WXMAC__) #include "wx/mac/choice.h" +#elif defined(__WXPM__) + #include "wx/os2/choice.h" #elif defined(__WXSTUBS__) #include "wx/stubs/choice.h" #endif diff --git a/include/wx/clipbrd.h b/include/wx/clipbrd.h index c37f46116f..36a95b0638 100644 --- a/include/wx/clipbrd.h +++ b/include/wx/clipbrd.h @@ -11,6 +11,8 @@ #include "wx/gtk/clipbrd.h" #elif defined(__WXMAC__) #include "wx/mac/clipbrd.h" +#elif defined(__WXPM__) +#include "wx/os2/clipbrd.h" #elif defined(__WXSTUBS__) #include "wx/stubs/clipbrd.h" #endif diff --git a/include/wx/cmndata.h b/include/wx/cmndata.h index ce6cf7c866..178e58668c 100644 --- a/include/wx/cmndata.h +++ b/include/wx/cmndata.h @@ -21,7 +21,7 @@ #include "wx/colour.h" #include "wx/gdicmn.h" -#if (defined(__WXMOTIF__) || defined(__WXGTK__)) && wxUSE_POSTSCRIPT +#if (defined(__WXMOTIF__) || defined(__WXGTK__) || defined(__WXPM__)) && wxUSE_POSTSCRIPT class WXDLLEXPORT wxPrintSetupData; #endif @@ -156,7 +156,7 @@ class WXDLLEXPORT wxPrintData: public wxObject void operator=(const wxPrintData& data); // For compatibility -#if (defined(__WXMOTIF__) || defined(__WXGTK__)) && wxUSE_POSTSCRIPT +#if (defined(__WXMOTIF__) || defined(__WXGTK__) || defined(__WXPM__)) && wxUSE_POSTSCRIPT void operator=(const wxPrintSetupData& setupData); #endif diff --git a/include/wx/colordlg.h b/include/wx/colordlg.h index a8ca97c25b..7500259cb8 100644 --- a/include/wx/colordlg.h +++ b/include/wx/colordlg.h @@ -11,6 +11,8 @@ #include "wx/generic/colrdlgg.h" #elif defined(__WXMAC__) #include "wx/generic/colrdlgg.h" +#elif defined(__WXPM__) +#include "wx/generic/colrdlgg.h" #elif defined(__WXSTUBS__) #include "wx/generic/colrdlgg.h" #endif diff --git a/include/wx/colour.h b/include/wx/colour.h index 3fff200431..dc5706de19 100644 --- a/include/wx/colour.h +++ b/include/wx/colour.h @@ -11,6 +11,8 @@ #include "wx/qt/colour.h" #elif defined(__WXMAC__) #include "wx/mac/colour.h" +#elif defined(__WXPM__) +#include "wx/os2/colour.h" #elif defined(__WXSTUBS__) #include "wx/stubs/colour.h" #endif diff --git a/include/wx/combobox.h b/include/wx/combobox.h index 26512aa0cd..9c80b16565 100644 --- a/include/wx/combobox.h +++ b/include/wx/combobox.h @@ -11,6 +11,8 @@ #include "wx/qt/combobox.h" #elif defined(__WXMAC__) #include "wx/mac/combobox.h" +#elif defined(__WXPM__) +#include "wx/os2/combobox.h" #elif defined(__WXSTUBS__) #include "wx/stubs/combobox.h" #endif diff --git a/include/wx/control.h b/include/wx/control.h index 33d5486cb7..c68cfa4e84 100644 --- a/include/wx/control.h +++ b/include/wx/control.h @@ -62,6 +62,8 @@ protected: #include "wx/qt/control.h" #elif defined(__WXMAC__) #include "wx/mac/control.h" +#elif defined(__WXPM__) + #include "wx/os2/control.h" #elif defined(__WXSTUBS__) #include "wx/stubs/control.h" #endif diff --git a/include/wx/cursor.h b/include/wx/cursor.h index 4ebe73a971..2e793baa8a 100644 --- a/include/wx/cursor.h +++ b/include/wx/cursor.h @@ -11,6 +11,8 @@ #include "wx/qt/cursor.h" #elif defined(__WXMAC__) #include "wx/mac/cursor.h" +#elif defined(__WXPM__) +#include "wx/os2/cursor.h" #elif defined(__WXSTUBS__) #include "wx/stubs/cursor.h" #endif diff --git a/include/wx/dataobj.h b/include/wx/dataobj.h index 3e1df6d487..48f84bca8d 100644 --- a/include/wx/dataobj.h +++ b/include/wx/dataobj.h @@ -22,6 +22,8 @@ #include "wx/qt/dnd.h" #elif defined(__WXMAC__) #include "wx/mac/dnd.h" +#elif defined(__WXPM__) + #include "wx/os2/dnd.h" #elif defined(__WXSTUBS__) #include "wx/stubs/dnd.h" #endif diff --git a/include/wx/dc.h b/include/wx/dc.h index 1b60a8e4df..90fd7f6c94 100644 --- a/include/wx/dc.h +++ b/include/wx/dc.h @@ -548,6 +548,8 @@ private: #include "wx/qt/dc.h" #elif defined(__WXMAC__) #include "wx/mac/dc.h" +#elif defined(__WXPM__) + #include "wx/os2/dc.h" #elif defined(__WXSTUBS__) #include "wx/stubs/dc.h" #endif diff --git a/include/wx/dcclient.h b/include/wx/dcclient.h index 557e2f4dc2..0d7938d875 100644 --- a/include/wx/dcclient.h +++ b/include/wx/dcclient.h @@ -11,6 +11,8 @@ #include "wx/qt/dcclient.h" #elif defined(__WXMAC__) #include "wx/mac/dcclient.h" +#elif defined(__WXPM__) +#include "wx/os2/dcclient.h" #elif defined(__WXSTUBS__) #include "wx/stubs/dcclient.h" #endif diff --git a/include/wx/dcmemory.h b/include/wx/dcmemory.h index 84a814c4d6..8e8c4cd3c2 100644 --- a/include/wx/dcmemory.h +++ b/include/wx/dcmemory.h @@ -11,6 +11,8 @@ #include "wx/qt/dcmemory.h" #elif defined(__WXMAC__) #include "wx/mac/dcmemory.h" +#elif defined(__WXPM__) +#include "wx/os2/dcmemory.h" #elif defined(__WXSTUBS__) #include "wx/stubs/dcmemory.h" #endif diff --git a/include/wx/dcprint.h b/include/wx/dcprint.h index 532323e9d2..37ebb5469c 100644 --- a/include/wx/dcprint.h +++ b/include/wx/dcprint.h @@ -4,6 +4,9 @@ #if defined(__WXMSW__) #include "wx/msw/dcprint.h" #endif +#if defined(__WXPM__) +#include "wx/os2/dcprint.h" +#endif #endif // _WX_DCPRINT_H_BASE_ diff --git a/include/wx/dcscreen.h b/include/wx/dcscreen.h index bd35719499..d6aa6e1515 100644 --- a/include/wx/dcscreen.h +++ b/include/wx/dcscreen.h @@ -11,6 +11,8 @@ #include "wx/qt/dcscreen.h" #elif defined(__WXMAC__) #include "wx/mac/dcscreen.h" +#elif defined(__WXPM__) +#include "wx/os2/dcscreen.h" #elif defined(__WXSTUBS__) #include "wx/stubs/dcscreen.h" #endif diff --git a/include/wx/dde.h b/include/wx/dde.h index 908fb09388..a77e343d16 100644 --- a/include/wx/dde.h +++ b/include/wx/dde.h @@ -11,6 +11,8 @@ #include "wx/qt/dde.h" #elif defined(__WXMAC__) #include "wx/mac/dde.h" +#elif defined(__WXPM__) +#include "wx/os2/dde.h" #elif defined(__WXSTUBS__) #include "wx/stubs/dde.h" #endif diff --git a/include/wx/defs.h b/include/wx/defs.h index 302766b90a..b9f0a123c4 100644 --- a/include/wx/defs.h +++ b/include/wx/defs.h @@ -68,6 +68,17 @@ #elif defined(applec) || defined(THINK_C) || ( defined( __MWERKS__ ) && !defined(__INTEL__) ) // MacOS +#elif defined(__OS2__) + #if defined(__IBMCPP__) + #define __VISAGEAVER__ __IBMCPP__ + #endif + #ifndef __WXOS2__ + #define __WXOS2__ + #endif + #ifndef __WXPM__ + #define __WXPM__ + #endif + // Place other OS/2 compiler environment defines here #else // Windows #ifndef __WINDOWS__ #define __WINDOWS__ @@ -175,9 +186,9 @@ // Make sure the environment is set correctly #if defined(__WXMSW__) && defined(__X__) #error "Target can't be both X and Windows" -#elif !defined(__WXMOTIF__) && !defined(__WXMSW__) && !defined(__WXGTK__) && \ +#elif !defined(__WXMOTIF__) && !defined(__WXMSW__) && !defined(__WXGTK__) && !defined(__WXPM__) && \ !defined(__WXMAC__) && !defined(__X__) && !defined(__WXQT__) && !defined(__WXSTUBS__) - #error "No Target! Use -D[__WXMOTIF__|__WXGTK__|__WXMSW__|__WXMAC__|__WXQT__|__WXSTUBS__]" + #error "No Target! Use -D[__WXMOTIF__|__WXGTK__|__WXMSW__|__WXMAC__|__WXQT__|__WXPM__|__WXSTUBS__]" #endif // ============================================================================ @@ -188,7 +199,7 @@ // check for native bool type and TRUE/FALSE constants // ---------------------------------------------------------------------------- -#if defined(__WXMOTIF__) || defined(__WXGTK__) || defined(__WXQT__) || defined(__WXSTUBS__) +#if defined(__WXMOTIF__) || defined(__WXGTK__) || defined(__WXQT__) || defined(__WXPM__) || defined(__WXSTUBS__) // Bool is now obsolete, use bool instead // typedef int Bool; @@ -233,6 +244,9 @@ #elif defined(__GNUWIN32__) // Cygwin supports bool #define HAVE_BOOL + #elif defined(__VISAGECPP__) + typedef unsigned long bool; + #define HAVE_BOOL #endif // compilers #endif // HAVE_BOOL @@ -263,7 +277,7 @@ typedef int wxWindowID; * Making or using wxWindows as a Windows DLL */ -#ifdef __WXMSW__ +#if defined(__WXMSW__) // _declspec works in BC++ 5 and later, as well as VC++ #if defined(__VISUALC__) || defined(__BORLANDC__) @@ -282,6 +296,22 @@ typedef int wxWindowID; # define WXDLLEXPORT_CTORFN # endif +#elif defined(__WXPM__) + +# ifdef WXMAKINGDLL +# define WXDLLEXPORT _Export +# define WXDLLEXPORT_DATA(type) _Export type +# define WXDLLEXPORT_CTORFN +# elif defined(WXUSINGDLL) +# define WXDLLEXPORT _Export +# define WXDLLEXPORT_DATA(type) _Export type +# define WXDLLEXPORT_CTORFN +# else +# define WXDLLEXPORT +# define WXDLLEXPORT_DATA(type) type +# define WXDLLEXPORT_CTORFN +# endif + #else # define WXDLLEXPORT # define WXDLLEXPORT_DATA(type) type diff --git a/include/wx/dialog.h b/include/wx/dialog.h index 709d6f5f0b..8a4737c2f4 100644 --- a/include/wx/dialog.h +++ b/include/wx/dialog.h @@ -75,6 +75,8 @@ protected: #include "wx/qt/dialog.h" #elif defined(__WXMAC__) #include "wx/mac/dialog.h" +#elif defined(__WXPM__) + #include "wx/os2/dialog.h" #elif defined(__WXSTUBS__) #include "wx/stubs/dialog.h" #endif diff --git a/include/wx/dirdlg.h b/include/wx/dirdlg.h index f2d1dbbdf2..5da68a5a45 100644 --- a/include/wx/dirdlg.h +++ b/include/wx/dirdlg.h @@ -15,6 +15,8 @@ #include "wx/qt/dirdlg.h" #elif defined(__WXMAC__) #include "wx/mac/dirdlg.h" +#elif defined(__WXPM__) +#include "wx/os2/dirdlg.h" #elif defined(__WXSTUBS__) #include "wx/stubs/dirdlg.h" #endif diff --git a/include/wx/dnd.h b/include/wx/dnd.h index d67e09fc7a..f6ddf89255 100644 --- a/include/wx/dnd.h +++ b/include/wx/dnd.h @@ -13,6 +13,8 @@ #include "wx/qt/dnd.h" #elif defined(__WXMAC__) #include "wx/mac/dnd.h" +#elif defined(__WXPM__) +#include "wx/os2/dnd.h" #elif defined(__WXSTUBS__) #include "wx/stubs/dnd.h" #endif diff --git a/include/wx/dragimag.h b/include/wx/dragimag.h index dbbce924d2..02da2e77dd 100644 --- a/include/wx/dragimag.h +++ b/include/wx/dragimag.h @@ -15,6 +15,8 @@ #include "wx/generic/dragimag.h" #elif defined(__WXMAC__) #include "wx/generic/dragimag.h" +#elif defined(__WXPM__) +#include "wx/generic/dragimag.h" #elif defined(__WXSTUBS__) #include "wx/generic/dragimag.h" #endif diff --git a/include/wx/dynarray.h b/include/wx/dynarray.h index e1ee899f16..b05f260955 100644 --- a/include/wx/dynarray.h +++ b/include/wx/dynarray.h @@ -44,8 +44,10 @@ must return negative value, 0 or positive value if pItem1 <, = or > pItem2 */ -#ifdef __VISUALC__ +#if defined(__VISUALC__) #define CMPFUNC_CONV _cdecl +#elif defined(__VISAGECPP__) + #define CMPFUNC_CONV _Optlink #else // !Visual C++ #define CMPFUNC_CONV #endif // compiler diff --git a/include/wx/dynlib.h b/include/wx/dynlib.h index 5788c2a743..0802665377 100644 --- a/include/wx/dynlib.h +++ b/include/wx/dynlib.h @@ -42,6 +42,10 @@ #elif defined(__WINDOWS__) # include typedef HMODULE wxDllType; +#elif defined(__OS2__) +# define INCL_DOS +# include + typedef HMODULE wxDllType; #elif defined(__WXMAC__) typedef CFragConnectionID wxDllType; #else diff --git a/include/wx/filedlg.h b/include/wx/filedlg.h index 7fc2e7a76e..7ce866145b 100644 --- a/include/wx/filedlg.h +++ b/include/wx/filedlg.h @@ -11,6 +11,8 @@ #include "wx/qt/filedlg.h" #elif defined(__WXMAC__) #include "wx/mac/filedlg.h" +#elif defined(__WXPM__) +#include "wx/os2/filedlg.h" #elif defined(__WXSTUBS__) #include "wx/stubs/filedlg.h" #endif diff --git a/include/wx/filefn.h b/include/wx/filefn.h index 22db00222b..b7455424ad 100644 --- a/include/wx/filefn.h +++ b/include/wx/filefn.h @@ -173,7 +173,7 @@ WXDLLEXPORT bool wxRmdir(const wxString& dir, int flags = 0); #ifdef __UNIX__ #define wxFILE_SEP_PATH wxFILE_SEP_PATH_UNIX #define wxPATH_SEP wxPATH_SEP_UNIX -#else // Windows +#else // Windows and OS/2 #define wxFILE_SEP_PATH wxFILE_SEP_PATH_DOS #define wxPATH_SEP wxPATH_SEP_DOS #endif // Unix/Windows @@ -182,7 +182,7 @@ WXDLLEXPORT bool wxRmdir(const wxString& dir, int flags = 0); // filename1.IsSameAs(filename2, wxARE_FILENAMES_CASE_SENSITIVE) #ifdef __UNIX__ #define wxARE_FILENAMES_CASE_SENSITIVE TRUE -#else // Windows +#else // Windows and OS/2 #define wxARE_FILENAMES_CASE_SENSITIVE FALSE #endif // Unix/Windows diff --git a/include/wx/font.h b/include/wx/font.h index 165c9c9f06..fdd9d9d8c6 100644 --- a/include/wx/font.h +++ b/include/wx/font.h @@ -11,6 +11,8 @@ #include "wx/qt/font.h" #elif defined(__WXMAC__) #include "wx/mac/font.h" +#elif defined(__WXPM__) +#include "wx/os2/font.h" #elif defined(__WXSTUBS__) #include "wx/stubs/font.h" #endif diff --git a/include/wx/fontdlg.h b/include/wx/fontdlg.h index f851cd8ee9..559d903ec2 100644 --- a/include/wx/fontdlg.h +++ b/include/wx/fontdlg.h @@ -19,6 +19,10 @@ #include "wx/generic/fontdlgg.h" # define wxFontDialog wxGenericFontDialog # define sm_classwxFontDialog sm_classwxGenericFontDialog +#elif defined(__WXPM__) +#include "wx/generic/fontdlgg.h" +# define wxFontDialog wxGenericFontDialog +# define sm_classwxFontDialog sm_classwxGenericFontDialog #elif defined(__WXSTUBS__) #include "wx/generic/fontdlgg.h" # define wxFontDialog wxGenericFontDialog diff --git a/include/wx/frame.h b/include/wx/frame.h index 329561fd9a..89171ced45 100644 --- a/include/wx/frame.h +++ b/include/wx/frame.h @@ -11,6 +11,8 @@ #include "wx/qt/frame.h" #elif defined(__WXMAC__) #include "wx/mac/frame.h" +#elif defined(__WXPM__) +#include "wx/os2/frame.h" #elif defined(__WXSTUBS__) #include "wx/stubs/frame.h" #endif diff --git a/include/wx/gauge.h b/include/wx/gauge.h index abf8a1f7e0..cffbc7c0d7 100644 --- a/include/wx/gauge.h +++ b/include/wx/gauge.h @@ -11,6 +11,8 @@ #include "wx/qt/gauge.h" #elif defined(__WXMAC__) #include "wx/mac/gauge.h" +#elif defined(__WXPM__) +#include "wx/os2/gauge.h" #elif defined(__WXSTUBS__) #include "wx/stubs/gauge.h" #endif diff --git a/include/wx/gdicmn.h b/include/wx/gdicmn.h index 0e197f0482..27ca11d85d 100644 --- a/include/wx/gdicmn.h +++ b/include/wx/gdicmn.h @@ -131,6 +131,9 @@ enum wxStockCursor #ifdef __WXMSW__ // Load from a resource #define wxICON(X) wxIcon("" #X "") +#elif defined(__WXPM__) + // Load from a resource + #define wxICON(X) wxIcon("" #X "") #elif defined(__WXGTK__) // Initialize from an included XPM #define wxICON(X) wxIcon( (const char**) X##_xpm ) diff --git a/include/wx/gdiobj.h b/include/wx/gdiobj.h index 39762ec749..4ab7c5ad81 100644 --- a/include/wx/gdiobj.h +++ b/include/wx/gdiobj.h @@ -11,6 +11,8 @@ #include "wx/qt/gdiobj.h" #elif defined(__WXMAC__) #include "wx/mac/gdiobj.h" +#elif defined(__WXPM__) +#include "wx/os2/gdiobj.h" #elif defined(__WXSTUBS__) #include "wx/stubs/gdiobj.h" #endif diff --git a/include/wx/icon.h b/include/wx/icon.h index 4fa9b5d225..ee304c2b69 100644 --- a/include/wx/icon.h +++ b/include/wx/icon.h @@ -17,6 +17,8 @@ #include "wx/qt/icon.h" #elif defined(__WXMAC__) #include "wx/mac/icon.h" +#elif defined(__WXPM__) + #include "wx/os2/icon.h" #elif defined(__WXSTUBS__) #include "wx/stubs/icon.h" #endif diff --git a/include/wx/imaglist.h b/include/wx/imaglist.h index 7aa92ee1bf..32f5922bd7 100644 --- a/include/wx/imaglist.h +++ b/include/wx/imaglist.h @@ -15,6 +15,8 @@ #include "wx/generic/imaglist.h" #elif defined(__WXMAC__) #include "wx/generic/imaglist.h" +#elif defined(__WXPM__) +#include "wx/generic/imaglist.h" #elif defined(__WXSTUBS__) #include "wx/generic/imaglist.h" #endif diff --git a/include/wx/joystick.h b/include/wx/joystick.h index 5391c9c5c3..370ee935c6 100644 --- a/include/wx/joystick.h +++ b/include/wx/joystick.h @@ -9,6 +9,8 @@ #include "wx/gtk/joystick.h" #elif defined(__WXMAC__) #include "wx/mac/joystick.h" +#elif defined(__WXPM__) +#include "wx/os2/joystick.h" #elif defined(__WXSTUBS__) #include "wx/stubs/joystick.h" #endif diff --git a/include/wx/listbox.h b/include/wx/listbox.h index 9d8a3460db..c104dbeabd 100644 --- a/include/wx/listbox.h +++ b/include/wx/listbox.h @@ -11,6 +11,8 @@ #include "wx/qt/listbox.h" #elif defined(__WXMAC__) #include "wx/mac/listbox.h" +#elif defined(__WXPM__) +#include "wx/os2/listbox.h" #elif defined(__WXSTUBS__) #include "wx/stubs/listbox.h" #endif diff --git a/include/wx/listctrl.h b/include/wx/listctrl.h index f6fe64203a..087e5d1c2a 100644 --- a/include/wx/listctrl.h +++ b/include/wx/listctrl.h @@ -15,6 +15,8 @@ #include "wx/generic/listctrl.h" #elif defined(__WXMAC__) #include "wx/generic/listctrl.h" +#elif defined(__WXPM__) +#include "wx/generic/listctrl.h" #elif defined(__WXSTUBS__) #include "wx/generic/listctrl.h" #endif diff --git a/include/wx/mdi.h b/include/wx/mdi.h index 1ce5e5555c..40d7abf66c 100644 --- a/include/wx/mdi.h +++ b/include/wx/mdi.h @@ -11,6 +11,8 @@ #include "wx/qt/mdi.h" #elif defined(__WXMAC__) #include "wx/mac/mdi.h" +#elif defined(__WXPM__) +#include "wx/os2/mdi.h" #elif defined(__WXSTUBS__) #include "wx/stubs/mdi.h" #endif diff --git a/include/wx/menu.h b/include/wx/menu.h index 2d0ce9798b..eb6bc59c98 100644 --- a/include/wx/menu.h +++ b/include/wx/menu.h @@ -11,6 +11,8 @@ #include "wx/qt/menu.h" #elif defined(__WXMAC__) #include "wx/mac/menu.h" +#elif defined(__WXPM__) +#include "wx/os2/menu.h" #elif defined(__WXSTUBS__) #include "wx/stubs/menu.h" #endif diff --git a/include/wx/menuitem.h b/include/wx/menuitem.h index ffb693fe0c..c19c785ffe 100644 --- a/include/wx/menuitem.h +++ b/include/wx/menuitem.h @@ -11,6 +11,8 @@ #include "wx/qt/menuitem.h" #elif defined(__WXMAC__) #include "wx/mac/menuitem.h" +#elif defined(__WXPM__) +#include "wx/os2/menuitem.h" #elif defined(__WXSTUBS__) #include "wx/stubs/menuitem.h" #endif diff --git a/include/wx/metafile.h b/include/wx/metafile.h index dab13f19f2..17aebfdcc8 100644 --- a/include/wx/metafile.h +++ b/include/wx/metafile.h @@ -4,6 +4,9 @@ #if defined(__WXMSW__) #include "wx/msw/metafile.h" #endif +#if defined(__WXPM__) +#include "wx/os2/metafile.h" +#endif #endif // _WX_METAFILE_H_BASE_ diff --git a/include/wx/minifram.h b/include/wx/minifram.h index 3b45d33a52..c8bd992496 100644 --- a/include/wx/minifram.h +++ b/include/wx/minifram.h @@ -9,6 +9,8 @@ #include "wx/gtk/minifram.h" #elif defined(__WXMAC__) #include "wx/mac/minifram.h" +#elif defined(__WXPM__) +#include "wx/os2/minifram.h" #elif defined(__WXSTUBS__) #include "wx/stubs/minifram.h" #endif diff --git a/include/wx/msgdlg.h b/include/wx/msgdlg.h index f03456aeaf..173e699e36 100644 --- a/include/wx/msgdlg.h +++ b/include/wx/msgdlg.h @@ -11,6 +11,8 @@ #include "wx/generic/msgdlgg.h" #elif defined(__WXMAC__) #include "wx/mac/msgdlg.h" +#elif defined(__WXPM__) +#include "wx/os2/msgdlg.h" #elif defined(__WXSTUBS__) #include "wx/generic/msgdlgg.h" #endif diff --git a/include/wx/notebook.h b/include/wx/notebook.h index 04fec2227f..63bbee89ea 100644 --- a/include/wx/notebook.h +++ b/include/wx/notebook.h @@ -103,6 +103,8 @@ typedef void (wxEvtHandler::*wxNotebookEventFunction)(wxNotebookEvent&); #include "wx/qt/notebook.h" #elif defined(__WXMAC__) #include "wx/mac/notebook.h" +#elif defined(__WXPM__) + #include "wx/os2/notebook.h" #elif defined(__WXSTUBS__) #include "wx/stubs/notebook.h" #endif diff --git a/include/wx/palette.h b/include/wx/palette.h index 9702d374a1..1c5099ee19 100644 --- a/include/wx/palette.h +++ b/include/wx/palette.h @@ -11,6 +11,8 @@ #include "wx/qt/palette.h" #elif defined(__WXMAC__) #include "wx/mac/palette.h" +#elif defined(__WXPM__) +#include "wx/os2/palette.h" #elif defined(__WXSTUBS__) #include "wx/stubs/palette.h" #endif diff --git a/include/wx/pen.h b/include/wx/pen.h index d132d8a7c9..62bdd7dc6e 100644 --- a/include/wx/pen.h +++ b/include/wx/pen.h @@ -11,6 +11,8 @@ #include "wx/qt/pen.h" #elif defined(__WXMAC__) #include "wx/mac/pen.h" +#elif defined(__WXPM__) +#include "wx/os2/pen.h" #elif defined(__WXSTUBS__) #include "wx/stubs/pen.h" #endif diff --git a/include/wx/pnghand.h b/include/wx/pnghand.h index 405e234ba5..3e6089629c 100644 --- a/include/wx/pnghand.h +++ b/include/wx/pnghand.h @@ -9,6 +9,8 @@ #include "wx/gtk/pnghand.h" #elif defined(__WXMAC__) #include "wx/mac/pnghand.h" +#elif defined(__WXPM__) +#include "wx/os2/pnghand.h" #elif defined(__WXSTUBS__) #include "wx/stubs/pnghand.h" #endif diff --git a/include/wx/printdlg.h b/include/wx/printdlg.h index 59d382735e..8a9480c622 100644 --- a/include/wx/printdlg.h +++ b/include/wx/printdlg.h @@ -11,6 +11,8 @@ #include "wx/generic/prntdlgg.h" #elif defined(__WXMAC__) #include "wx/mac/printdlg.h" +#elif defined(__WXPM__) +#include "wx/os2/printdlg.h" #elif defined(__WXSTUBS__) #include "wx/generic/prntdlgg.h" #endif diff --git a/include/wx/radiobox.h b/include/wx/radiobox.h index 2f0253ddb9..dc4b1df2ab 100644 --- a/include/wx/radiobox.h +++ b/include/wx/radiobox.h @@ -11,6 +11,8 @@ #include "wx/qt/radiobox.h" #elif defined(__WXMAC__) #include "wx/mac/radiobox.h" +#elif defined(__WXPM__) +#include "wx/os2/radiobox.h" #elif defined(__WXSTUBS__) #include "wx/stubs/radiobox.h" #endif diff --git a/include/wx/radiobut.h b/include/wx/radiobut.h index ce602dcc0f..01023e4c17 100644 --- a/include/wx/radiobut.h +++ b/include/wx/radiobut.h @@ -11,6 +11,8 @@ #include "wx/qt/radiobut.h" #elif defined(__WXMAC__) #include "wx/mac/radiobut.h" +#elif defined(__WXPM__) +#include "wx/os2/radiobut.h" #elif defined(__WXSTUBS__) #include "wx/stubs/radiobut.h" #endif diff --git a/include/wx/region.h b/include/wx/region.h index 9c5afd22bc..ee0fd6ac06 100644 --- a/include/wx/region.h +++ b/include/wx/region.h @@ -11,6 +11,8 @@ #include "wx/qt/region.h" #elif defined(__WXMAC__) #include "wx/mac/region.h" +#elif defined(__WXPM__) +#include "wx/os2/region.h" #elif defined(__WXSTUBS__) #include "wx/stubs/region.h" #endif diff --git a/include/wx/sckstrm.h b/include/wx/sckstrm.h index a330bb173f..7e5159294a 100644 --- a/include/wx/sckstrm.h +++ b/include/wx/sckstrm.h @@ -56,7 +56,7 @@ class WXDLLEXPORT wxSocketInputStream : public wxInputStream }; class WXDLLEXPORT wxSocketStream : public wxSocketInputStream, - public wxSocketOutputStream + public wxSocketOutputStream { public: wxSocketStream(wxSocketBase& s); diff --git a/include/wx/scrolbar.h b/include/wx/scrolbar.h index 49f9a11b05..301291e7b2 100644 --- a/include/wx/scrolbar.h +++ b/include/wx/scrolbar.h @@ -11,6 +11,8 @@ #include "wx/qt/scrolbar.h" #elif defined(__WXMAC__) #include "wx/mac/scrolbar.h" +#elif defined(__WXPM__) +#include "wx/os2/scrolbar.h" #elif defined(__WXSTUBS__) #include "wx/stubs/scrolbar.h" #endif diff --git a/include/wx/settings.h b/include/wx/settings.h index 1dfc5d9280..0109917b1d 100644 --- a/include/wx/settings.h +++ b/include/wx/settings.h @@ -114,6 +114,8 @@ #include "wx/qt/settings.h" #elif defined(__WXMAC__) #include "wx/mac/settings.h" +#elif defined(__WXPM__) +#include "wx/os2/settings.h" #elif defined(__WXSTUBS__) #include "wx/stubs/settings.h" #endif diff --git a/include/wx/setup.h b/include/wx/setup.h index 54936598ae..076a4d4c78 100644 --- a/include/wx/setup.h +++ b/include/wx/setup.h @@ -4,8 +4,8 @@ /* compatibility code, to be removed asap: */ -#if !defined(__WXMSW__) && !defined(__WXGTK__) && !defined(__WXMOTIF__) && !defined(__WXQT__) && !defined(__WXSTUBS__) && !defined(__WXMAC__) -# error No __WXxxx__ define set! Please define one of __WXGTK__,__WXMSW__,__WXMOTIF__,__WXMAC__,__WXQT__,__WXSTUBS__ +#if !defined(__WXMSW__) && !defined(__WXGTK__) && !defined(__WXMOTIF__) && !defined(__WXQT__) && !defined(__WXSTUBS__) && !defined(__WXMAC__) && !defined(__WXPM__) +# error No __WXxxx__ define set! Please define one of __WXGTK__,__WXMSW__,__WXMOTIF__,__WXMAC__,__WXQT__,__WXPM__,__WXSTUBS__ #endif #if defined(__WXMSW__) @@ -16,6 +16,8 @@ #include "wx/qt/setup.h" #elif defined(__WXMOTIF__) #include "wx/motif/setup.h" +#elif defined(__WXPM__) +#include "wx/os2/setup.h" #elif defined(__WXSTUBS__) #include "wx/stubs/setup.h" #elif defined(__WXGTK__) diff --git a/include/wx/slider.h b/include/wx/slider.h index 739a311aa5..772c2e5db4 100644 --- a/include/wx/slider.h +++ b/include/wx/slider.h @@ -11,6 +11,8 @@ #include "wx/qt/slider.h" #elif defined(__WXMAC__) #include "wx/mac/slider.h" +#elif defined(__WXPM__) +#include "wx/os2/slider.h" #elif defined(__WXSTUBS__) #include "wx/stubs/slider.h" #endif diff --git a/include/wx/spinbutt.h b/include/wx/spinbutt.h index b06df17a92..4593894ca5 100644 --- a/include/wx/spinbutt.h +++ b/include/wx/spinbutt.h @@ -79,6 +79,8 @@ protected: #include "wx/qt/spinbutt.h" #elif defined(__WXMAC__) #include "wx/mac/spinbutt.h" +#elif defined(__WXPM__) + #include "wx/os2/spinbutt.h" #elif defined(__WXSTUBS__) #include "wx/stubs/spinbutt.h" #endif diff --git a/include/wx/statbmp.h b/include/wx/statbmp.h index 0f32d687a3..764a0fe7e3 100644 --- a/include/wx/statbmp.h +++ b/include/wx/statbmp.h @@ -11,6 +11,8 @@ #include "wx/qt/statbmp.h" #elif defined(__WXMAC__) #include "wx/mac/statbmp.h" +#elif defined(__WXPM__) +#include "wx/os2/statbmp.h" #elif defined(__WXSTUBS__) #include "wx/stubs/statbmp.h" #endif diff --git a/include/wx/statbox.h b/include/wx/statbox.h index f1a8bd6eea..e67a1698e3 100644 --- a/include/wx/statbox.h +++ b/include/wx/statbox.h @@ -11,6 +11,8 @@ #include "wx/qt/statbox.h" #elif defined(__WXMAC__) #include "wx/mac/statbox.h" +#elif defined(__WXPM__) +#include "wx/os2/statbox.h" #elif defined(__WXSTUBS__) #include "wx/stubs/statbox.h" #endif diff --git a/include/wx/statline.h b/include/wx/statline.h index 9c7fe86788..956dc75a68 100644 --- a/include/wx/statline.h +++ b/include/wx/statline.h @@ -64,6 +64,8 @@ protected: #include "wx/msw/statline.h" #elif defined(__WXGTK__) #include "wx/gtk/statline.h" +#elif defined(__WXPM__) + #include "wx/os2/statline.h" #else // use generic implementation for all other platforms #include "wx/generic/statline.h" #endif diff --git a/include/wx/stattext.h b/include/wx/stattext.h index abfbbd5be6..48ea950c52 100644 --- a/include/wx/stattext.h +++ b/include/wx/stattext.h @@ -11,6 +11,8 @@ #include "wx/qt/stattext.h" #elif defined(__WXMAC__) #include "wx/mac/stattext.h" +#elif defined(__WXPM__) +#include "wx/os2/stattext.h" #elif defined(__WXSTUBS__) #include "wx/stubs/stattext.h" #endif diff --git a/include/wx/string.h b/include/wx/string.h index 661c893f57..41e60cb3c0 100644 --- a/include/wx/string.h +++ b/include/wx/string.h @@ -105,6 +105,8 @@ inline int WXDLLEXPORT Stricmp(const char *psz1, const char *psz2) return stricmp(psz1, psz2); #elif defined(__EMX__) return stricmp(psz1, psz2); +#elif defined(__VISAGECPP__) + return stricmp(psz1, psz2); #elif defined(__UNIX__) || defined(__GNUWIN32__) return strcasecmp(psz1, psz2); #elif defined(__MWERKS__) && !defined(__INTEL__) diff --git a/include/wx/tabctrl.h b/include/wx/tabctrl.h index c766f72bf3..baf3850a04 100644 --- a/include/wx/tabctrl.h +++ b/include/wx/tabctrl.h @@ -8,6 +8,8 @@ #elif defined(__WXGTK__) #elif defined(__WXMAC__) #include "wx/mac/tabctrl.h" +#elif defined(__WXPM__) +#include "wx/os2/tabctrl.h" #elif defined(__WXSTUBS__) #include "wx/stubs/tabctrl.h" #endif diff --git a/include/wx/taskbar.h b/include/wx/taskbar.h index 614edbb655..3474858a65 100644 --- a/include/wx/taskbar.h +++ b/include/wx/taskbar.h @@ -9,6 +9,8 @@ #elif defined(__WXQT__) #elif defined(__WXMAC__) #include "wx/mac/taskbar.h" +#elif defined(__WXPM__) +#include "wx/os2/taskbar.h" #elif defined(__WXSTUBS__) #include "wx/stubs/taskbar.h" #endif diff --git a/include/wx/tbar95.h b/include/wx/tbar95.h index 5e1a009544..511220e2bd 100644 --- a/include/wx/tbar95.h +++ b/include/wx/tbar95.h @@ -7,6 +7,8 @@ #include "wx/motif/tbar95.h" #elif defined(__WXGTK__) #include "wx/gtk/tbar95.h" +#elif defined(__WXPM__) +#include "wx/os2/tbar95.h" #endif #endif diff --git a/include/wx/tbarmsw.h b/include/wx/tbarmsw.h index 4b9d761fcf..b79f2200c6 100644 --- a/include/wx/tbarmsw.h +++ b/include/wx/tbarmsw.h @@ -7,6 +7,8 @@ #include "wx/motif/tbarmsw.h" #elif defined(__WXGTK__) #include "wx/gtk/tbarmsw.h" +#elif defined(__WXPM__) +#include "wx/os2/tbarmsw.h" #endif #endif diff --git a/include/wx/textctrl.h b/include/wx/textctrl.h index 0de57cdcf6..279d9160a8 100644 --- a/include/wx/textctrl.h +++ b/include/wx/textctrl.h @@ -172,6 +172,8 @@ private: #include "wx/qt/textctrl.h" #elif defined(__WXMAC__) #include "wx/mac/textctrl.h" +#elif defined(__WXPM__) + #include "wx/os2/textctrl.h" #elif defined(__WXSTUBS__) #include "wx/stubs/textctrl.h" #endif diff --git a/include/wx/thread.h b/include/wx/thread.h index b0bbc261f7..d4bb7aeac3 100644 --- a/include/wx/thread.h +++ b/include/wx/thread.h @@ -160,7 +160,7 @@ private: wxCriticalSection(const wxCriticalSection&); wxCriticalSection& operator=(const wxCriticalSection&); -#ifdef __WXMSW__ +#if defined(__WXMSW__) || defined(__WXPM__) wxCriticalSectionInternal *m_critsect; #else // !MSW wxMutex m_mutex; @@ -372,7 +372,7 @@ public: // implementation only until the end of file // ----------------------------------------------------------------------------- #if wxUSE_THREADS -#ifdef __WXMSW__ +#if defined(__WXMSW__) || defined(__WXPM__) // unlock GUI if there are threads waiting for and lock it back when // there are no more of them - should be called periodically by the main // thread diff --git a/include/wx/timer.h b/include/wx/timer.h index 4cf5c35b26..0b86490de6 100644 --- a/include/wx/timer.h +++ b/include/wx/timer.h @@ -11,6 +11,8 @@ #include "wx/qt/timer.h" #elif defined(__WXMAC__) #include "wx/mac/timer.h" +#elif defined(__WXPM__) +#include "wx/os2/timer.h" #elif defined(__WXSTUBS__) #include "wx/stubs/timer.h" #endif diff --git a/include/wx/toolbar.h b/include/wx/toolbar.h index 86d2444de7..7dad6add56 100644 --- a/include/wx/toolbar.h +++ b/include/wx/toolbar.h @@ -19,6 +19,8 @@ # include "wx/qt/tbarqt.h" #elif defined(__WXMAC__) # include "wx/mac/toolbar.h" +#elif defined(__WXPM__) +# include "wx/os2/toolbar.h" #elif defined(__WXSTUBS__) # include "wx/stubs/toolbar.h" #endif diff --git a/include/wx/tooltip.h b/include/wx/tooltip.h index 451765c5e6..017bed7de1 100644 --- a/include/wx/tooltip.h +++ b/include/wx/tooltip.h @@ -11,6 +11,8 @@ #include "wx/qt/tooltip.h" #elif defined(__WXMAC__) #include "wx/mac/tooltip.h" +#elif defined(__WXPM__) +#include "wx/os2/tooltip.h" #elif defined(__WXSTUBS__) // #include "wx/stubs/tooltip.h" #endif diff --git a/include/wx/treectrl.h b/include/wx/treectrl.h index 55642822d7..799425a95f 100644 --- a/include/wx/treectrl.h +++ b/include/wx/treectrl.h @@ -26,6 +26,8 @@ #include "wx/qt/treectrl.h" #elif defined(__WXMAC__) #include "wx/generic/treectrl.h" +#elif defined(__WXPM__) + #include "wx/generic/treectrl.h" #elif defined(__WXSTUBS__) #include "wx/generic/treectrl.h" #endif diff --git a/include/wx/version.h b/include/wx/version.h index 6d3d427b2a..e22c21138e 100644 --- a/include/wx/version.h +++ b/include/wx/version.h @@ -22,4 +22,4 @@ #define wxVERSION_FLOAT wxMAJOR_VERSION + (wxMINOR_VERSION/10.0) + (wxRELEASE_NUMBER/100.0) + (wxBETA_NUMBER/10000.0) #endif - // _WX_VERSIONH__ +// _WX_VERSIONH__ diff --git a/include/wx/wave.h b/include/wx/wave.h index cd61bad818..f0756b1cdc 100644 --- a/include/wx/wave.h +++ b/include/wx/wave.h @@ -7,6 +7,8 @@ #include "wx/gtk/wave.h" #elif defined(__WXQT__) #include "wx/qt/wave.h" +#elif defined(__WXPM__) +#include "wx/os2/wave.h" #endif #endif diff --git a/include/wx/window.h b/include/wx/window.h index d6ee431600..5ae7d448c9 100644 --- a/include/wx/window.h +++ b/include/wx/window.h @@ -819,6 +819,8 @@ private: #include "wx/qt/window.h" #elif defined(__WXMAC__) #include "wx/mac/window.h" +#elif defined(__WXPM__) + #include "wx/os2/window.h" #endif // ---------------------------------------------------------------------------- diff --git a/include/wx/wxchar.h b/include/wx/wxchar.h index 7e05283622..9aac1f6a7b 100644 --- a/include/wx/wxchar.h +++ b/include/wx/wxchar.h @@ -18,131 +18,131 @@ // only do SBCS or _UNICODE #if defined (_MBCS ) -#error "MBCS is not supported by wxChar" +# error "MBCS is not supported by wxChar" #endif // set wxUSE_UNICODE to 1 if UNICODE or _UNICODE is defined #if defined(_UNICODE) || defined(UNICODE) -#undef wxUSE_UNICODE -#define wxUSE_UNICODE 1 +# undef wxUSE_UNICODE +# define wxUSE_UNICODE 1 #else -#ifndef wxUSE_UNICODE -#define wxUSE_UNICODE 0 -#endif +# ifndef wxUSE_UNICODE +# define wxUSE_UNICODE 0 +# endif #endif // and vice versa: define UNICODE and _UNICODE if wxUSE_UNICODE is 1... #if wxUSE_UNICODE -#ifndef _UNICODE -#define _UNICODE -#endif -#ifndef UNICODE -#define UNICODE -#endif +# ifndef _UNICODE +# define _UNICODE +# endif +# ifndef UNICODE +# define UNICODE +# endif #endif // Windows (VC++) has broad TCHAR support #if defined(__VISUALC__) && defined(__WIN32__) -#define HAVE_WCSLEN 1 +# define HAVE_WCSLEN 1 -#include -#if wxUSE_UNICODE // temporary - preserve binary compatibility +# include +# if wxUSE_UNICODE // temporary - preserve binary compatibility typedef _TCHAR wxChar; typedef _TSCHAR wxSChar; typedef _TUCHAR wxUChar; -#else -#define wxChar char -#define wxSChar signed char -#define wxUChar unsigned char -#endif +# else +# define wxChar char +# define wxSChar signed char +# define wxUChar unsigned char +# endif // wchar_t is available -#undef wxUSE_WCHAR_T -#define wxUSE_WCHAR_T 1 +# undef wxUSE_WCHAR_T +# define wxUSE_WCHAR_T 1 // ctype.h functions -#define wxIsalnum _istalnum -#define wxIsalpha _istalpha -#define wxIsctrl _istctrl -#define wxIsdigit _istdigit -#define wxIsgraph _istgraph -#define wxIslower _istlower -#define wxIsprint _istprint -#define wxIspunct _istpunct -#define wxIsspace _istspace -#define wxIsupper _istupper -#define wxIsxdigit _istxdigit -#define wxTolower _totlower -#define wxToupper _totupper +# define wxIsalnum _istalnum +# define wxIsalpha _istalpha +# define wxIsctrl _istctrl +# define wxIsdigit _istdigit +# define wxIsgraph _istgraph +# define wxIslower _istlower +# define wxIsprint _istprint +# define wxIspunct _istpunct +# define wxIsspace _istspace +# define wxIsupper _istupper +# define wxIsxdigit _istxdigit +# define wxTolower _totlower +# define wxToupper _totupper // locale.h functons -#define wxSetlocale _tsetlocale +# define wxSetlocale _tsetlocale // string.h functions -#define wxStrcat _tcscat -#define wxStrchr _tcschr -#define wxStrcmp _tcscmp -#define wxStrcoll _tcscoll -#define wxStrcpy _tcscpy -#define wxStrcspn _tcscspn -#define wxStrftime _tcsftime -#define wxStricmp _tcsicmp -#define wxStrlen_ _tcslen // used in wxStrlen inline function -#define wxStrncat _tcsncat -#define wxStrncmp _tcsncmp -#define wxStrncpy _tcsncpy -#define wxStrpbrk _tcspbrk -#define wxStrrchr _tcsrchr -#define wxStrspn _tcsspn -#define wxStrstr _tcsstr -#define wxStrtod _tcstod +# define wxStrcat _tcscat +# define wxStrchr _tcschr +# define wxStrcmp _tcscmp +# define wxStrcoll _tcscoll +# define wxStrcpy _tcscpy +# define wxStrcspn _tcscspn +# define wxStrftime _tcsftime +# define wxStricmp _tcsicmp +# define wxStrlen_ _tcslen // used in wxStrlen inline function +# define wxStrncat _tcsncat +# define wxStrncmp _tcsncmp +# define wxStrncpy _tcsncpy +# define wxStrpbrk _tcspbrk +# define wxStrrchr _tcsrchr +# define wxStrspn _tcsspn +# define wxStrstr _tcsstr +# define wxStrtod _tcstod // is there a _tcstok[_r] ? -#define wxStrtol _tcstol -#define wxStrtoul _tcstoul -#define wxStrxfrm _tcsxfrm +# define wxStrtol _tcstol +# define wxStrtoul _tcstoul +# define wxStrxfrm _tcsxfrm // stdio.h functions -#define wxFgetc _fgettc -#define wxFgetchar _fgettchar -#define wxFgets _fgetts -#define wxFopen _tfopen -#define wxFputc _fputtc -#define wxFputchar _fputtchar -#define wxFprintf _ftprintf -#define wxFreopen _tfreopen -#define wxFscanf _ftscanf -#define wxGetc _gettc -#define wxGetchar _gettchar -#define wxGets _getts -#define wxPerror _tperror -#define wxPrintf _tprintf -#define wxPutc _puttc -#define wxPutchar _puttchar -#define wxPuts _putts -#define wxRemove _tremove -#define wxRename _trename -#define wxScanf _tscanf -#define wxSprintf _stprintf -#define wxSscanf _stscanf -#define wxTmpnam _ttmpnam -#define wxUngetc _tungetc -#define wxVfprint _vftprintf -#define wxVprintf _vtprintf -#define wxVsscanf _vstscanf -#define wxVsprintf _vstprintf +# define wxFgetc _fgettc +# define wxFgetchar _fgettchar +# define wxFgets _fgetts +# define wxFopen _tfopen +# define wxFputc _fputtc +# define wxFputchar _fputtchar +# define wxFprintf _ftprintf +# define wxFreopen _tfreopen +# define wxFscanf _ftscanf +# define wxGetc _gettc +# define wxGetchar _gettchar +# define wxGets _getts +# define wxPerror _tperror +# define wxPrintf _tprintf +# define wxPutc _puttc +# define wxPutchar _puttchar +# define wxPuts _putts +# define wxRemove _tremove +# define wxRename _trename +# define wxScanf _tscanf +# define wxSprintf _stprintf +# define wxSscanf _stscanf +# define wxTmpnam _ttmpnam +# define wxUngetc _tungetc +# define wxVfprint _vftprintf +# define wxVprintf _vtprintf +# define wxVsscanf _vstscanf +# define wxVsprintf _vstprintf // stdlib.h functions -#if !wxUSE_UNICODE -#define wxAtof atof -#endif -#define wxAtoi _ttoi -#define wxAtol _ttol -#define wxGetenv _tgetenv -#define wxSystem _tsystem +# if !wxUSE_UNICODE +# define wxAtof atof +# endif +# define wxAtoi _ttoi +# define wxAtol _ttol +# define wxGetenv _tgetenv +# define wxSystem _tsystem // time.h functions -#define wxAsctime _tasctime -#define wxCtime _tctime +# define wxAsctime _tasctime +# define wxCtime _tctime // #elif defined(XXX) // #include XXX-specific files here @@ -156,281 +156,281 @@ typedef _TUCHAR wxUChar; // maybe Borland C++ 5.02 has, can't check right now // but I'll use the Win32 API instead here -#include -#if wxUSE_UNICODE // temporary - preserve binary compatibility +# include +# if wxUSE_UNICODE // temporary - preserve binary compatibility typedef _TCHAR wxChar; typedef _TSCHAR wxSChar; typedef _TUCHAR wxUChar; -#else -#define wxChar char -#define wxSChar signed char -#define wxUChar unsigned char -#endif +# else +# define wxChar char +# define wxSChar signed char +# define wxUChar unsigned char +# endif // wchar_t is available -#undef wxUSE_WCHAR_T -#define wxUSE_WCHAR_T 1 +# undef wxUSE_WCHAR_T +# define wxUSE_WCHAR_T 1 -#define wxNEED_WX_CTYPE_H +# define wxNEED_WX_CTYPE_H // #define wxStrtok strtok_r // Borland C++ 4.52 doesn't have strtok_r -#define wxNEED_WX_STRING_H -#define wxNEED_WX_STDIO_H -#define wxNEED_WX_STDLIB_H -#define wxNEED_WX_TIME_H -#define wxNEED_WCSLEN +# define wxNEED_WX_STRING_H +# define wxNEED_WX_STDIO_H +# define wxNEED_WX_STDLIB_H +# define wxNEED_WX_TIME_H +# define wxNEED_WCSLEN #else//!TCHAR-aware compilers // check whether we should include wchar.h or equivalent -#if wxUSE_UNICODE - #undef wxUSE_WCHAR_T - #define wxUSE_WCHAR_T 1 // wchar_t *must* be available in Unicode mode -#elif !defined(wxUSE_WCHAR_T) - #if defined(__VISUALC__) && (__VISUALC__ < 900) - #define wxUSE_WCHAR_T 0 // wchar_t is not available for MSVC++ 1.5 - #elif defined(__UNIX__) - #if defined(HAVE_WCSTR_H) || defined(HAVE_WCHAR_H) || defined(__FreeBSD__) - #define wxUSE_WCHAR_T 1 - #else - #define wxUSE_WCHAR_T 0 - #endif - #elif defined(__GNUWIN32__) && !defined(__MINGW32__) // Cygwin (not Mingw32) doesn't have wcslen.h, needed in buffer.h - #define wxUSE_WCHAR_T 0 - #elif defined(__BORLANDC__) // WIN16 BC++ - #define wxUSE_WCHAR_T 0 - #elif defined(__WATCOMC__) - #define wxUSE_WCHAR_T 0 - #else +# if wxUSE_UNICODE +# undef wxUSE_WCHAR_T +# define wxUSE_WCHAR_T 1 // wchar_t *must* be available in Unicode mode +# elif !defined(wxUSE_WCHAR_T) +# if defined(__VISUALC__) && (__VISUALC__ < 900) +# define wxUSE_WCHAR_T 0 // wchar_t is not available for MSVC++ 1.5 +# elif defined(__UNIX__) +# if defined(HAVE_WCSTR_H) || defined(HAVE_WCHAR_H) || defined(__FreeBSD__) +# define wxUSE_WCHAR_T 1 +# else +# define wxUSE_WCHAR_T 0 +# endif +# elif defined(__GNUWIN32__) && !defined(__MINGW32__) // Cygwin (not Mingw32) doesn't have wcslen.h, needed in buffer.h +# define wxUSE_WCHAR_T 0 +# elif defined(__BORLANDC__) // WIN16 BC++ +# define wxUSE_WCHAR_T 0 +# elif defined(__WATCOMC__) +# define wxUSE_WCHAR_T 0 +# else // add additional compiler checks if this fails - #define wxUSE_WCHAR_T 1 - #endif -#endif//wxUSE_UNICODE - -#if wxUSE_WCHAR_T - #ifdef HAVE_WCSTR_H - #include - #else - #ifndef __FreeBSD__ - #include - #else - #include - #define wxNEED_WCSLEN - #endif - #endif -#endif +# define wxUSE_WCHAR_T 1 +# endif +# endif//wxUSE_UNICODE + +# if wxUSE_WCHAR_T +# ifdef HAVE_WCSTR_H +# include +# else +# ifndef __FreeBSD__ +# include +# else +# include +# define wxNEED_WCSLEN +# endif +# endif +# endif // check whether we are doing Unicode -#if wxUSE_UNICODE +# if wxUSE_UNICODE -#include +# include // this is probably glibc-specific -#if defined(__WCHAR_TYPE__) +# if defined(__WCHAR_TYPE__) typedef __WCHAR_TYPE__ wxChar; typedef signed __WCHAR_TYPE__ wxSChar; typedef unsigned __WCHAR_TYPE__ wxUChar; -#define _T(x) L##x - - // ctype.h functions (wctype.h) -#define wxIsalnum iswalnum -#define wxIsalpha iswalpha -#define wxIsctrl iswcntrl -#define wxIsdigit iswdigit -#define wxIsgraph iswgraph -#define wxIslower iswlower -#define wxIsprint iswprint -#define wxIspunct iswpunct -#define wxIsspace iswspace -#define wxIsupper iswupper -#define wxIsxdigit iswxdigit - -#if defined(__GLIBC__) && (__GLIBC__ == 2) && (__GLIBC_MINOR__ == 0) - // /usr/include/wctype.h incorrectly declares translations tables which - // provokes tons of compile-time warnings - try to correct this - #define wxTolower(wc) towctrans((wc), (wctrans_t)__ctype_tolower) - #define wxToupper(wc) towctrans((wc), (wctrans_t)__ctype_toupper) -#else - #define wxTolower towlower - #define wxToupper towupper -#endif // gcc/!gcc - - // string.h functions (wchar.h) -#define wxStrcat wcscat -#define wxStrchr wcschr -#define wxStrcmp wcscmp -#define wxStrcoll wcscoll -#define wxStrcpy wcscpy -#define wxStrcspn wcscspn -#define wxStrlen_ wcslen // used in wxStrlen inline function -#define wxStrncat wcsncat -#define wxStrncmp wcsncmp -#define wxStrncpy wcsncpy -#define wxStrpbrk wcspbrk -#define wxStrrchr wcsrchr -#define wxStrspn wcsspn -#define wxStrstr wcsstr -#define wxStrtod wcstod -#define wxStrtok wcstok -#define wxStrtol wcstol -#define wxStrtoul wcstoul -#define wxStrxfrm wcsxfrm +# define _T(x) L##x + + // ctype.h functions (wctype.h) +# define wxIsalnum iswalnum +# define wxIsalpha iswalpha +# define wxIsctrl iswcntrl +# define wxIsdigit iswdigit +# define wxIsgraph iswgraph +# define wxIslower iswlower +# define wxIsprint iswprint +# define wxIspunct iswpunct +# define wxIsspace iswspace +# define wxIsupper iswupper +# define wxIsxdigit iswxdigit + +# if defined(__GLIBC__) && (__GLIBC__ == 2) && (__GLIBC_MINOR__ == 0) + // /usr/include/wctype.h incorrectly declares translations tables which + // provokes tons of compile-time warnings - try to correct this +# define wxTolower(wc) towctrans((wc), (wctrans_t)__ctype_tolower) +# define wxToupper(wc) towctrans((wc), (wctrans_t)__ctype_toupper) +# else +# define wxTolower towlower +# define wxToupper towupper +# endif // gcc/!gcc + + // string.h functions (wchar.h) +# define wxStrcat wcscat +# define wxStrchr wcschr +# define wxStrcmp wcscmp +# define wxStrcoll wcscoll +# define wxStrcpy wcscpy +# define wxStrcspn wcscspn +# define wxStrlen_ wcslen // used in wxStrlen inline function +# define wxStrncat wcsncat +# define wxStrncmp wcsncmp +# define wxStrncpy wcsncpy +# define wxStrpbrk wcspbrk +# define wxStrrchr wcsrchr +# define wxStrspn wcsspn +# define wxStrstr wcsstr +# define wxStrtod wcstod +# define wxStrtok wcstok +# define wxStrtol wcstol +# define wxStrtoul wcstoul +# define wxStrxfrm wcsxfrm // glibc doesn't have wc equivalents of the other stuff -#define wxNEED_WX_STDIO_H -#define wxNEED_WX_STDLIB_H -#define wxNEED_WX_TIME_H +# define wxNEED_WX_STDIO_H +# define wxNEED_WX_STDLIB_H +# define wxNEED_WX_TIME_H -#else//!glibc -#error "Please define your compiler's Unicode conventions in wxChar.h" -#endif -#else//!Unicode +# else//!glibc +# error "Please define your compiler's Unicode conventions in wxChar.h" +# endif +# else//!Unicode -#include -#include +# include +# include -#if 0 // temporary - preserve binary compatibilty +# if 0 // temporary - preserve binary compatibilty typedef char wxChar; typedef signed char wxSChar; typedef unsigned char wxUChar; -#else -#define wxChar char -#define wxSChar signed char -#define wxUChar unsigned char -#endif - -#ifdef __FreeBSD__ - #undef _T -#endif -#define _T(x) x - - // ctype.h functions -#define wxIsalnum isalnum -#define wxIsalpha isalpha -#define wxIsctrl isctrl -#define wxIsdigit isdigit -#define wxIsgraph isgraph -#define wxIslower islower -#define wxIsprint isprint -#define wxIspunct ispunct -#define wxIsspace isspace -#define wxIsupper isupper -#define wxIsxdigit isxdigit -#define wxTolower tolower -#define wxToupper toupper - - // locale.h functons -#define wxSetlocale setlocale - - // string.h functions -// #define wxStricmp strcasecmp -// wxStricmp is defined below!! - -// #define wxStrtok strtok_r // this needs a configure check - - // leave the rest to defaults below -#define wxNEED_WX_STRING_H -#define wxNEED_WX_STDIO_H -#define wxNEED_WX_STDLIB_H -#define wxNEED_WX_TIME_H - -#endif//Unicode +# else +# define wxChar char +# define wxSChar signed char +# define wxUChar unsigned char +# endif + +# ifdef __FreeBSD__ +# undef _T +# endif +# define _T(x) x + + // ctype.h functions +# define wxIsalnum isalnum +# define wxIsalpha isalpha +# define wxIsctrl isctrl +# define wxIsdigit isdigit +# define wxIsgraph isgraph +# define wxIslower islower +# define wxIsprint isprint +# define wxIspunct ispunct +# define wxIsspace isspace +# define wxIsupper isupper +# define wxIsxdigit isxdigit +# define wxTolower tolower +# define wxToupper toupper + + // locale.h functons +# define wxSetlocale setlocale + + // string.h functions + // #define wxStricmp strcasecmp + // wxStricmp is defined below!! + + // #define wxStrtok strtok_r // this needs a configure check + + // leave the rest to defaults below +# define wxNEED_WX_STRING_H +# define wxNEED_WX_STDIO_H +# define wxNEED_WX_STDLIB_H +# define wxNEED_WX_TIME_H + +# endif//Unicode #endif//TCHAR-aware compilers // define wxStricmp for various compilers without Unicode possibilities #if !defined(wxStricmp) && !wxUSE_UNICODE -#if defined(__BORLANDC__) || defined(__WATCOMC__) || defined(__SALFORDC__) - #define wxStricmp stricmp -#elif defined(__SC__) || defined(__VISUALC__) || (defined(__MWERKS) && defined(__INTEL__)) - #define wxStricmp _stricmp -#elif defined(__UNIX__) || defined(__GNUWIN32__) - #define wxStricmp strcasecmp -#elif defined(__MWERKS__) && !defined(__INTEL__) - // use wxWindows' implementation -#else - // if you leave wxStricmp undefined, wxWindows' implementation will be used - #error "Please define string case-insensitive compare for your OS/compiler" -#endif +# if defined(__BORLANDC__) || defined(__WATCOMC__) || defined(__SALFORDC__) +# define wxStricmp stricmp +# elif defined(__SC__) || defined(__VISUALC__) || defined(__VISAGECPP__) || (defined(__MWERKS) && defined(__INTEL__)) +# define wxStricmp _stricmp +# elif defined(__UNIX__) || defined(__GNUWIN32__) +# define wxStricmp strcasecmp +# elif defined(__MWERKS__) && !defined(__INTEL__) + // use wxWindows' implementation +# else + // if you leave wxStricmp undefined, wxWindows' implementation will be used +# error "Please define string case-insensitive compare for your OS/compiler" +# endif #endif // if we need to define for standard headers, and we're not using Unicode, // just define to standard C library routines #if !wxUSE_UNICODE -#ifdef wxNEED_WX_STRING_H -#define wxStrcat strcat -#define wxStrchr strchr -#define wxStrcmp strcmp -#define wxStrcoll strcoll -#define wxStrcpy strcpy -#define wxStrcspn strcspn -#define wxStrdup strdup -#define wxStrlen_ strlen // used in wxStrlen inline function -#define wxStrncat strncat -#define wxStrncmp strncmp -#define wxStrncpy strncpy -#define wxStrpbrk strpbrk -#define wxStrrchr strrchr -#define wxStrspn strspn -#define wxStrstr strstr -#define wxStrtod strtod -#define wxStrtol strtol -#define wxStrtoul strtoul -#define wxStrxfrm strxfrm -#undef wxNEED_WX_STRING_H -#endif - -#ifdef wxNEED_WX_STDIO_H -#define wxFgetc fgetc -#define wxFgetchar fgetchar -#define wxFgets fgets -#define wxFopen fopen -#define wxFputc fputc -#define wxFputchar fputchar -#define wxFprintf fprintf -#define wxFreopen freopen -#define wxFscanf fscanf -#define wxGetc getc -#define wxGetchar getchar -#define wxGets gets -#define wxPerror perror -#define wxPrintf printf -#define wxPutc putc -#define wxPutchar putchar -#define wxPuts puts -#define wxRemove remove -#define wxRename rename -#define wxScanf scanf -#define wxSprintf sprintf -#define wxSscanf sscanf -#define wxTmpnam tmpnam -#define wxUngetc ungetc -#define wxVfprint vfprintf -#define wxVprintf vprintf -#define wxVsscanf vsscanf -#define wxVsprintf vsprintf -#undef wxNEED_WX_STDIO_H -#endif - -#ifdef wxNEED_WX_STDLIB_H -#define wxAtof atof -#define wxAtoi atoi -#define wxAtol atol -#define wxGetenv getenv -#define wxSystem system -#undef wxNEED_WX_STDLIB_H -#endif - -#ifdef wxNEED_WX_TIME_H -#define wxAsctime asctime -#define wxCtime ctime -#define wxStrftime strftime -#undef wxNEED_WX_TIME_H -#endif +# ifdef wxNEED_WX_STRING_H +# define wxStrcat strcat +# define wxStrchr strchr +# define wxStrcmp strcmp +# define wxStrcoll strcoll +# define wxStrcpy strcpy +# define wxStrcspn strcspn +# define wxStrdup strdup +# define wxStrlen_ strlen // used in wxStrlen inline function +# define wxStrncat strncat +# define wxStrncmp strncmp +# define wxStrncpy strncpy +# define wxStrpbrk strpbrk +# define wxStrrchr strrchr +# define wxStrspn strspn +# define wxStrstr strstr +# define wxStrtod strtod +# define wxStrtol strtol +# define wxStrtoul strtoul +# define wxStrxfrm strxfrm +# undef wxNEED_WX_STRING_H +# endif + +# ifdef wxNEED_WX_STDIO_H +# define wxFgetc fgetc +# define wxFgetchar fgetchar +# define wxFgets fgets +# define wxFopen fopen +# define wxFputc fputc +# define wxFputchar fputchar +# define wxFprintf fprintf +# define wxFreopen freopen +# define wxFscanf fscanf +# define wxGetc getc +# define wxGetchar getchar +# define wxGets gets +# define wxPerror perror +# define wxPrintf printf +# define wxPutc putc +# define wxPutchar putchar +# define wxPuts puts +# define wxRemove remove +# define wxRename rename +# define wxScanf scanf +# define wxSprintf sprintf +# define wxSscanf sscanf +# define wxTmpnam tmpnam +# define wxUngetc ungetc +# define wxVfprint vfprintf +# define wxVprintf vprintf +# define wxVsscanf vsscanf +# define wxVsprintf vsprintf +# undef wxNEED_WX_STDIO_H +# endif + +# ifdef wxNEED_WX_STDLIB_H +# define wxAtof atof +# define wxAtoi atoi +# define wxAtol atol +# define wxGetenv getenv +# define wxSystem system +# undef wxNEED_WX_STDLIB_H +# endif + +# ifdef wxNEED_WX_TIME_H +# define wxAsctime asctime +# define wxCtime ctime +# define wxStrftime strftime +# undef wxNEED_WX_TIME_H +# endif #endif //!Unicode #if defined(wxNEED_WCSLEN) && wxUSE_UNICODE -#define wcslen wxStrlen -#undef wxNEED_WCSLEN +# define wcslen wxStrlen +# undef wxNEED_WCSLEN #endif /// checks whether the passed in pointer is NULL and if the string is empty @@ -446,25 +446,25 @@ WXDLLEXPORT inline size_t wxStrlen(const wxChar *psz) // multibyte<->widechar conversion WXDLLEXPORT size_t wxMB2WC(wchar_t *buf, const char *psz, size_t n); WXDLLEXPORT size_t wxWC2MB(char *buf, const wchar_t *psz, size_t n); -#if wxUSE_UNICODE -#define wxMB2WX wxMB2WC -#define wxWX2MB wxWC2MB -#define wxWC2WX wxStrncpy -#define wxWX2WC wxStrncpy -#else -#define wxMB2WX wxStrncpy -#define wxWX2MB wxStrncpy -#define wxWC2WX wxWC2MB -#define wxWX2WC wxMB2WC -#endif +# if wxUSE_UNICODE +# define wxMB2WX wxMB2WC +# define wxWX2MB wxWC2MB +# define wxWC2WX wxStrncpy +# define wxWX2WC wxStrncpy +# else +# define wxMB2WX wxStrncpy +# define wxWX2MB wxStrncpy +# define wxWC2WX wxWC2MB +# define wxWX2WC wxMB2WC +# endif #else // No wxUSE_WCHAR_T: we have to do something (JACS) -#define wxMB2WC wxStrncpy -#define wxWC2MB wxStrncpy -#define wxMB2WX wxStrncpy -#define wxWX2MB wxStrncpy -#define wxWC2WX wxWC2MB -#define wxWX2WC wxMB2WC +# define wxMB2WC wxStrncpy +# define wxWC2MB wxStrncpy +# define wxMB2WX wxStrncpy +# define wxWX2MB wxStrncpy +# define wxWC2WX wxWC2MB +# define wxWX2WC wxMB2WC #endif WXDLLEXPORT bool wxOKlibc(); // for internal use @@ -528,8 +528,8 @@ WXDLLEXPORT size_t wxStrxfrm(wxChar *dest, const wxChar *src, size_t n); #endif #ifdef wxNEED_WX_STDIO_H -#include -#include +# include +# include WXDLLEXPORT FILE * wxFopen(const wxChar *path, const wxChar *mode); WXDLLEXPORT FILE * wxFreopen(const wxChar *path, const wxChar *mode, FILE *stream); WXDLLEXPORT int wxPrintf(const wxChar *fmt, ...); @@ -559,3 +559,4 @@ WXDLLEXPORT size_t wxStrftime(wxChar *s, size_t max, const wxChar *fmt, const #endif //_WX_WXCHAR_H_ + diff --git a/include/wx/wxprec.h b/include/wx/wxprec.h index 80526f249b..c79a641ffe 100644 --- a/include/wx/wxprec.h +++ b/include/wx/wxprec.h @@ -13,7 +13,7 @@ #include "wx/defs.h" // compiler definitions // check if to use precompiled headers -#if (defined(__BORLANDC__) || defined(__VISUALC__) || defined(__WATCOMC__)) && defined(__WXMSW__) +#if ((defined(__BORLANDC__) || defined(__VISUALC__) || defined(__WATCOMC__)) && defined(__WXMSW__)) || defined(__WXPM__) #if !defined(NOPCH) #define WX_PRECOMP #endif @@ -32,6 +32,11 @@ #include "wx/msw/winundef.h" #endif +#ifdef __WXPM__ +#define INCL_OS2 +#include +#endif + #include "wx/wx.h" diff --git a/include/wx/xpmhand.h b/include/wx/xpmhand.h index 9a848a0f8c..0d1a9bd10e 100644 --- a/include/wx/xpmhand.h +++ b/include/wx/xpmhand.h @@ -1,11 +1,14 @@ #ifndef _WX_XPMHAND_H_BASE_ #define _WX_XPMHAND_H_BASE_ -// Only wxMSW currently defines a separate XPM handler, since -// mostly Windows apps won't need XPMs. +// Only wxMSW and wxPM currently defines a separate XPM handler, since +// mostly Windows and Presentation Manager apps won't need XPMs. #if defined(__WXMSW__) #include "wx/msw/xpmhand.h" #endif +#if defined(__WXPM__) +#include "wx/os2/xpmhand.h" +#endif #endif // _WX_XPMHAND_H_BASE_ -- 2.45.2