X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/3f4a0c5be34be837210768501c13dbcff81e533c..d3dcceb4363163ea8eeba75234ac938e690230c8:/include/wx/defs.h diff --git a/include/wx/defs.h b/include/wx/defs.h index fd5cd7c644..10fe0fa316 100644 --- a/include/wx/defs.h +++ b/include/wx/defs.h @@ -49,6 +49,8 @@ #endif // Sun CC #endif #endif // Sun +#elif defined(applec) || defined(THINK_C) || ( defined( __MWERKS__ ) && !defined(__INTEL__) ) + // MacOS #else // Windows #ifndef __WINDOWS__ #define __WINDOWS__ @@ -57,7 +59,7 @@ // define another standard symbol for Microsoft Visual C++: the standard one // (_MSC_VER) is also defined by Metrowerks compiler #if defined(_MSC_VER) && !defined(__MWERKS__) - #define __VISUALC__ + #define __VISUALC__ _MSC_VER #elif defined(__BCPLUSPLUS__) && !defined(__BORLANDC__) #define __BORLANDC__ #elif defined(__WATCOMC__) @@ -158,7 +160,12 @@ #elif defined(__BORLANDC__) && (__BORLANDC__ < 0x500) typedef unsigned int bool; #elif defined(__WATCOMC__) +// typedef unsigned int bool; + + #if (__WATCOMC__ < 1100) typedef unsigned int bool; + #endif + #elif defined(__SUNCC__) #ifdef __SUNPRO_CC // starting from version 5.0 Sun CC understands 'bool' @@ -194,6 +201,7 @@ typedef int wxWindowID; #ifdef __WXMSW__ +/* #ifdef __BORLANDC__ # ifdef WXMAKINGDLL @@ -211,14 +219,18 @@ typedef int wxWindowID; # endif #else +*/ + +// _declspec works in BC++ 5 and later, as well as VC++ +#if defined(__VISUALC__) || defined(__BORLANDC__) # ifdef WXMAKINGDLL -# define WXDLLEXPORT __declspec( dllexport ) -# define WXDLLEXPORT_DATA(type) __declspec( dllexport ) type -# define WXDLLEXPORT_CTORFN // __declspec( dllexport ) +# define WXDLLEXPORT _declspec( dllexport ) +# define WXDLLEXPORT_DATA(type) _declspec( dllexport ) type +# define WXDLLEXPORT_CTORFN # elif defined(WXUSINGDLL) -# define WXDLLEXPORT __declspec( dllimport ) -# define WXDLLEXPORT_DATA(type) __declspec( dllimport ) type +# define WXDLLEXPORT _declspec( dllimport ) +# define WXDLLEXPORT_DATA(type) _declspec( dllimport ) type # define WXDLLEXPORT_CTORFN # else # define WXDLLEXPORT @@ -226,6 +238,10 @@ typedef int wxWindowID; # define WXDLLEXPORT_CTORFN # endif +#else +# define WXDLLEXPORT +# define WXDLLEXPORT_DATA(type) type +# define WXDLLEXPORT_CTORFN #endif #else @@ -432,17 +448,24 @@ typedef void (*wxFunction) (wxObject&, wxEvent&); /* * wxToolBar style flags */ - #define wxTB_3DBUTTONS 0x8000 #define wxTB_HORIZONTAL 0x0002 #define wxTB_VERTICAL 0x0004 // Flatbar/Coolbar under Win98 #define wxTB_FLAT 0x0008 +// use native docking +#define wxTB_DOCKABLE 0x0010 /* - * Apply to all panel items + * wxMenuBar style flags */ +// use native docking +#define wxMB_DOCKABLE 0x0001 + +/* + * Apply to all panel items + */ #define wxCOLOURED 0x0800 // Alignment for panel item labels: replaces characters with zeros // when creating label, so spaces can be included in string for alignment. @@ -455,7 +478,6 @@ typedef void (*wxFunction) (wxObject&, wxEvent&); /* * Styles for wxListBox */ - #define wxLB_SORT 0x0010 #define wxLB_SINGLE 0x0020 #define wxLB_MULTIPLE 0x0040 @@ -511,7 +533,6 @@ typedef void (*wxFunction) (wxObject&, wxEvent&); /* * wxSlider flags */ - #define wxSL_HORIZONTAL wxHORIZONTAL #define wxSL_VERTICAL wxVERTICAL // The next one is obsolete - use scroll events instead @@ -529,21 +550,18 @@ typedef void (*wxFunction) (wxObject&, wxEvent&); /* * wxScrollBar flags */ - #define wxSB_HORIZONTAL wxHORIZONTAL #define wxSB_VERTICAL wxVERTICAL /* * wxButton flags */ - #define wxBU_AUTODRAW 0x0004 #define wxBU_NOAUTODRAW 0x0000 /* * wxTreeCtrl flags */ - #define wxTR_HAS_BUTTONS 0x0004 #define wxTR_EDIT_LABELS 0x0008 #define wxTR_LINES_AT_ROOT 0x0010 @@ -551,7 +569,6 @@ typedef void (*wxFunction) (wxObject&, wxEvent&); /* * wxListCtrl flags */ - #define wxLC_ICON 0x0004 #define wxLC_SMALL_ICON 0x0008 #define wxLC_LIST 0x0010 @@ -938,6 +955,19 @@ enum #define wxID_HIGHEST 5999 +// Mapping modes (as per Windows) +#define wxMM_TEXT 1 +#define wxMM_LOMETRIC 2 +#define wxMM_HIMETRIC 3 +#define wxMM_LOENGLISH 4 +#define wxMM_HIENGLISH 5 +#define wxMM_TWIPS 6 +#define wxMM_ISOTROPIC 7 +#define wxMM_ANISOTROPIC 8 + +#define wxMM_POINTS 9 +#define wxMM_METRIC 10 + /* Shortcut for easier dialog-unit-to-pixel conversion */ #define wxDLG_UNIT(parent, pt) parent->ConvertDialogToPixels(pt)