Re: [Tutor] Linux library for getch() and kbhit()?

2011-03-17 Thread Bill Allen
Alan, Ah ha, ungetch(), that is what I was needing. I had be trying to simulate kbhit() with getch() and keep being left with unhandled data in the buffer. I had resorted to a trash=raw_input() to clear it. Many thanks, Bill On Thu, Mar 17, 2011 at 04:01, Alan Gauld wrote: > > "Bill All

Re: [Tutor] Linux library for getch() and kbhit()?

2011-03-17 Thread Alan Gauld
"Bill Allen" wrote I have found that for the Windows build of Python the msvcrt library provides getch() and kbhit() functions. Is there a library available for the Linux Python build that provides the same or similar functions? curses. Take a look at the event handling topic in my tuto

[Tutor] Linux library for getch() and kbhit()?

2011-03-16 Thread Bill Allen
I have found that for the Windows build of Python the msvcrt library provides getch() and kbhit() functions. Is there a library available for the Linux Python build that provides the same or similar functions? I have found lots of recipes out there to do these, but have not yet found a canned l