Why doesn't Python include non-blocking keyboard input function?
Marko Rauhamaa
marko at pacujo.net
Fri Oct 28 03:33:44 EDT 2016
Christian Gollwitzer <auriocus at gmx.de>:
> I still believe that it is not a "basic functionality". You need it,
> if you want to program a text editor or similar thing, but without
> using a real GUI. This is a small niche.
I disagree. It's a very large group of programs. For example, CPython's
input() function puts the terminal in character mode to support
emacs-style editing keys on Linux. And of course, CPython's REPL reader
does it as well.
CPython does that via GNU readline:
<URL: https://docs.python.org/3/library/readline.html>
> It is both easier and more functional to use a real GUI library.
Well, CPython doesn't do that...
Marko
More information about the Python-list
mailing list