Help: Chinese charactor in Tkinter

Zhenlei Jia zj8k at node13.unix.Virginia.EDU
Mon Oct 2 10:12:44 EDT 2000


On 1 Oct 2000, Martin von Loewis wrote:

> Zhenlei Jia <zj8k at node14.unix.Virginia.EDU> writes:
> 
> > I am trying to display Chinese charactor in Tkinter. The following is 
> > the code I've tried, but the texts were displied as "?". Had I missed
> > somthing, or just I can't do it on my system? I am using MacPython 2.0b1,
> > Tcl & Tk 8.3.0 on MacOS 8.6, I have installed Chinese Language Kit, and I
> > can display Chinese char in java, also using unicode.
> 
> Can you please try this in a plain wish? It appears that Tk somehow
> cannot determine that your font indeed supports the character, so it
> displays the replacement character instead.
I try the code on a Windows system( win98 English version + external
Chinese system), and it work. So seems it's the operate system can't
handle Chinese char well.
> Also, did you try passing unicode strings but no font? Tk should
> attempt to analyse all available fonts and find a suitable one.
Have tried this, no lucky. 

Anyway, thanks for your advise!

Regards,

Zhenlei Jia 




More information about the Python-list mailing list