[Idle-dev] [ idlefork-Patches-521908 ] print Unicode strings in OutputWindow
noreply@sourceforge.net
noreply@sourceforge.net
Sat, 23 Feb 2002 15:38:43 -0800
Patches item #521908, was opened at 2002-02-23 15:38
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=309579&aid=521908&group_id=9579
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Jason Orendorff (jorend)
Assigned to: Nobody/Anonymous (nobody)
Summary: print Unicode strings in OutputWindow
Initial Comment:
This one-line patch makes OutputWindow handle Unicode
correctly. For example,
>>> print u'\xbfQu\xe9 pas\xf3?'
Without the patch this throws a UnicodeError,
not because of any problem with Unicode handling
in either Python or Tk, but because IDLE does str(s)
on the Unicode string. I just took out the
call to str().
Then I searched through IDLE to find where write()
is called to make sure it is only called with
string or unicode data.
"loewis" has checked this in to the Python tip.
I've been using it a while here with no ill
effects.
----------------------------------------------------------------------
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=309579&aid=521908&group_id=9579