[wxPython-users] wxPython and Unicode and widgets
Christopher Barker
Chris.Barker at noaa.gov
Wed Dec 19 14:29:09 PST 2007
Chris Mellon wrote:
> On Dec 19, 2007 12:39 PM, Donn Ingle <donn.ingle at gmail.com> wrote:
> The same rules apply as apply everywhere else that you need to deal
> with string data. By far the best solution is to decode to/from
> strings at the borders of your application and use only unicode
> internally.
To make that clear with your example:
2. "Right" way:
msg = u"Could be a fatal string"
wx.MessageBox( msg, "", wx.OK )
so pass only unicode objects to wxPython.
Where did your "could be a fatal string" come from? when you get that is
when you should handle the decoding, as Chris (the other one) said.
>> I also assume that if the user has the ansi build
You're really better off just making your app a unicode app, and not
supporting the ANSI build at all.
-Chris
--
Christopher Barker, Ph.D.
Oceanographer
Emergency Response Division
NOAA/NOS/OR&R (206) 526-6959 voice
7600 Sand Point Way NE (206) 526-6329 fax
Seattle, WA 98115 (206) 526-6317 main reception
Chris.Barker at noaa.gov
More information about the wxpython-users
mailing list