This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

作者 vstinner
收信人 Arfrever, simpkins, vstinner
日期 2012-08-26.21:07:39
SpamBayes Score -1.0
Marked as misclassified
Message-id <1346015260.26.0.3127259418.issue15785@psf.upfronthosting.co.za>
In-reply-to
内容
Oh, right. I agree that the current implementation of window.get_wch() is useless. I missed completly key codes.

Attached patch changes the API of get_wch() from get_wch()->key:int to get_wch()->(is_key_code: bool, key: str). Examples: (True, 'KEY_UP'), (False, 'é').

Problem: unget_wch() test fails. "unget_wch('é'); is_key_code, ch = win.get_wch()" returns is_key_code=True, ch=''. I don't see how to specify to unget_wch() if the argument is a key code or not... It's maybe an issue in unget_wch() API that cannot be fixed in Python?
历史
日期 用户 动作 参数
2012-08-26 21:07:40vstinner修改recipients: + vstinner, Arfrever, simpkins
2012-08-26 21:07:40vstinner修改messageid: <1346015260.26.0.3127259418.issue15785@psf.upfronthosting.co.za>
2012-08-26 21:07:39vstinner链接issue15785 messages
2012-08-26 21:07:39vstinner创建