wxToolkit?

Is there a way to find out what toolkit is in use?
I need to know if my app is running GTK or GTK2
wxPlatform returns "__WXGTK__"
I'm going off the 'u' in wxVERSION[4] for the moment hence I am assuming
that all GTK2 apps are unicode enabled. But that doesn't seem right.
Is/shouldn't there be a wxToolkit constant defined somewhere?

Thx
- - -- ---- ----------------------------------------- --- -- - -
Ahmad Baitalmal
BitBuilder
web: http://www.bitbuilder.com
-------------------------------------------------------------- --- -- -

Is there a way to find out what toolkit is in use? I need to know if my
app is running GTK or GTK2 wxPlatform returns "__WXGTK__"
I'm going off the 'u' in wxVERSION[4] for the moment hence I am assuming
that all GTK2 apps are unicode enabled. But that doesn't seem right.
Is/shouldn't there be a wxToolkit constant defined somewhere?

I'd like to have this too. AFAIK it's not possible at the moment. But I
just wanted to note that the 'u' trick is not reliable, since you can
build wxGTK2 in ansi mode.

Alberto

Ahmad Baitalmal wrote:

Is there a way to find out what toolkit is in use?
I need to know if my app is running GTK or GTK2
wxPlatform returns "__WXGTK__"
I'm going off the 'u' in wxVERSION[4] for the moment hence I am assuming
that all GTK2 apps are unicode enabled. But that doesn't seem right. Is/shouldn't there be a wxToolkit constant defined somewhere?

Unfortunatly there isn't anything like that exposed in wxPython now.
The wxPlatform value was meant to serve that purpose, but since wxGTK2
is not really a new platform I didn't change the value. In the C++ code
*both* __WXGTK__ and __WXGTK20__ are defined. Suggestions?

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

Turn wxPlatform into (or create another) list of platforms? This would turn platform tests into:

if '__WXGTK__' in wxPlatforms:

instead of the current

if wxPlatform == '__WXGTK__':

This could help future systems if diverse toolkits (or theme libraries?) ever co-existed, and could allow wxPython to expose other relevant system facilities to the developer so that they could probe the list and choose which extended features to implement.

J.

···

On Mon, 07 Jul 2003 16:59:00 -0700, Robin Dunn <robin@alldunn.com> wrote:

Ahmad Baitalmal wrote:

Is there a way to find out what toolkit is in use?
I need to know if my app is running GTK or GTK2
wxPlatform returns "__WXGTK__"
I'm going off the 'u' in wxVERSION[4] for the moment hence I am assuming
that all GTK2 apps are unicode enabled. But that doesn't seem right. Is/shouldn't there be a wxToolkit constant defined somewhere?

Unfortunatly there isn't anything like that exposed in wxPython now.
The wxPlatform value was meant to serve that purpose, but since wxGTK2
is not really a new platform I didn't change the value. In the C++ code
*both* __WXGTK__ and __WXGTK20__ are defined. Suggestions?