Wait for a keypress before continuing?

John Doe jdoe at usenetlove.invalid
Tue Aug 16 20:42:52 CEST 2011

def wait_for_keystroke():
  while not char==0x1B:

That freezes the process. Am I using the right code for the escape 
key, or doing anything else wrong?

Again, I know it could be my system. But I must find a way to do this 
from within Windows. I use a keyboard hook written in C++, maybe 
something from that would be useful, but maybe complex.


More information about the Python-list mailing list