STINNER Victor <victor.stin...@haypocalc.com> added the comment:

Using curses_unicode.patch:

 - without ncursesw: addch('é') raises an OverflowError because 
'é'.encode('UTF-8') is 2 bytes and not 1 byte
 - with ncursesw: the charset is displayable character depends on the locale 
encoding (e.g. € cannot be printed with ISO-8859-1 locale encoding)
 - with ncursesw: any character can be printed with a UTF-8 locale encoding 
(including non-BMP characters: U-10000..U+10FFFF)

It would be possible to support multibyte encoded character (like é in UTF-8) 
for addch() by calling addch() multiple times, one per byte, but I would prefer 
to keep _curses simple and not workaround libncurses limitations (bugs).

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue12567>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to