how can i write a hello world in chinese with python

John Machin sjmachin at lexicon.net
Wed Dec 13 07:01:14 EST 2006


Leo Kislov wrote:
> kernel1983 wrote:
> > and I tried unicode and utf-8
>
> How did you try unicode? Like this? :
>
> EasyDialogs.Message(u'\u4e2d')
>
> > I tried to both use unicode&utf-8 head just like "\xEF\xBB\xBF" and not
> > to use
> >
> > Anyone knows about the setting in the python code file?
> > Maybe python doesn't know I'm to use chinese?!
>
> It depends on how EasyDialogs works. And by the way, when you say utf-8
> encoded text is not displayed correctly, what do you actually see on
> the screen?

There is a Windows version of EasyDialogs -- unfortunately it appears
not to support Unicode, even for the most simple case.

This works:
| >>> EasyDialogs.Message('fubar')
but this doesn't:
| >>> EasyDialogs.Message(u'fubar')

The title of the window is empty, the text consists of only 'f", and
there is no OK button.
Not very robust.




More information about the Python-list mailing list