]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/defs.h
Numerous changes to comply with use of wxCoord.
[wxWidgets.git] / include / wx / defs.h
index 456b71b9510667ed13adea1102c17a3570d3ec3d..ed28273f398be3a2f272ac2f7ae44349c4f19a24 100644 (file)
@@ -506,9 +506,25 @@ enum
 };
 
 // ----------------------------------------------------------------------------
-// machine specific settings
+// standard wxWindows types
 // ----------------------------------------------------------------------------
 
+// the type for screen and DC coordinates
+
+#if wxUSE_COMPATIBLE_COORD_TYPES
+    // to ensure compatibility with 2.0, we must use long
+    #define wxCoord long
+#else  // !wxUSE_COMPATIBLE_COORD_TYPES
+    #ifdef __WIN16__
+        // under Win16, int is too small, so use long to allow for bigger
+        // virtual canvases
+        typedef long wxCoord;
+    #else // !Win16
+        // other platforms we support have at least 32bit int - quite enough
+        typedef int wxCoord;
+    #endif // Win16/!Win16
+#endif // wxUSE_COMPATIBLE_COORD_TYPES/!wxUSE_COMPATIBLE_COORD_TYPES
+
 // fixed length types
 
 #define wxInt8    char    signed
@@ -560,6 +576,10 @@ enum
 #define  wxByte   wxUint8
 #define  wxWord   wxUint16
 
+// ----------------------------------------------------------------------------
+// byte ordering related definition and macros
+// ----------------------------------------------------------------------------
+
 // byte sex
 
 #define  wxBIG_ENDIAN     4321