""Martin v. Löwis"" <[EMAIL PROTECTED]> schrieb im Newsbeitrag news:[EMAIL PROTECTED] | phil wrote: | > These work fine on Linux | > s.const = {} | > s.const['DEG'] = '%c' % (0xb0) | > s.const['DIV'] = '%c' % (0xf7) | > s.const['ANG'] = '%c' % (0xd8) | > | > On WinXP the symbols for division and angle work fine. | > But the symbol for degrees, a little circle, produces | > a vertical bar in Tkinter Text box or Canvas. | | I don't understand what you mean by that. Do you have | the symbol for degrees in your source code (so that | the editor for the source code displays it as a little | circle)? Or do you use the numeric code? | | Can you show a small program that demonstrates this | effect?
OP probably means something like: import Tkinter root = Tkinter.Tk() t = Tkinter.Text() t.pack() t.insert(0.0, '%c' % 0xb0) root.mainloop() which shows a vertical bar in the Text widget. Changing: t.insert(0.0, '%c' % 0xb0) to t.insert(0.0, u'%c' % 0xb0) should do the trick though. -- Regards, Vincent Wehren | | Regards, | Martin |
-- http://mail.python.org/mailman/listinfo/python-list