wxPlatform class ?
Olly Betts
olly at survex.com
Thu Jul 6 16:49:08 PDT 2006
On 2006-07-06, Francesco Montorsi wrote:
> wxOS_MAC, // Apple Mac OS 8/9/X with Mac paths
> wxOS_MAC_DARWIN, // Apple Mac OS X with Unix paths
> wxOS_OS2_PM, // OS/2 Workplace
> wxOS_WINDOWS, // Windows or WfW
> wxOS_MICROWINDOWS, // MicroWindows
> wxOS_PENWINDOWS, // Windows for Pen Computing
> wxOS_WINDOWS_NT, // Windows NT
> wxOS_WIN32S, // Windows 32S API
> wxOS_WIN95, // Windows 95
> wxOS_WINDOWS_CE, // Windows CE (generic)
> wxOS_WINDOWS_POCKETPC, // Windows CE PocketPC
> wxOS_WINDOWS_SMARTPHONE, // Windows CE Smartphone
> wxOS_WINDOWS_OS2, // Native OS/2 PM
> wxOS_PALMOS, // PalmOS
> wxOS_DOS, // wxBase under MS-DOS
> wxOS_UNIX, // Unix, Linux, FreeBSD
> wxOS_BEOS, // BeOS
> wxOS_MAX // the number of members of this enum
Why go to the trouble of distinguishing 10 different flavours of
Windows, yet lump a dozen or more different operating systems (some
much more different than Windows 95 vs Windows NT) under "Unix, Linux,
and FreeBSD"?
> wxMGL, // MGL
> wxX11, // Plain X11 and Universal widgets
For consistency the MGL comment should probably also note "and Universal
widgets". I think you can also use wxUniversal on Windows, though I've
never tried.
> wxIsPlatform64Bit.
What will this mean though? Has 64 bit pointers? Has 64 longs? Has 64
bit ints? Or even is running on a 64bit processor (even if in 32 bit mode)?
Probably the most obvious definition is the addressable memory (which
corresponds to "has 64 bit pointers") but I can think of reasons to care
more about other definitions. Besides sizeof(void*)==8 is a more
precise and probably more optimisable way to write that if that's what
you actually want to test.
I think a more useful categorisation might be to describe the data size
model as one of LP64/ILP64/LLP64/ILP32/LP32 - a good summary is here:
http://www.tcl.tk/cgi-bin/tct/tip/69.html (search the page for LP64).
Cheers,
Olly
More information about the wx-dev
mailing list