Re: get_key() vs wait_key()
- Posted by Robert Craig <rds at RapidEuphoria.com> Oct 17, 2003
- 430 views
C. K. Lester wrote: > Of course, I still don't understand why, in the same environment, get_key() > returns a valid keycode (one number for an arrow key) and wait_key() does > not (multiple numbers for an arrow key). > > Shouldn't they both return the same value? On my Linux system, ed and key.ex pick up the same key codes, as they should. For me, only Home and End generate 3 codes at once. wait_key() and get_key() are handled by the the same routine in the interpreter, with a parameter indicating if the routine should wait or return -1. Picking a different key to use instead of Esc sounds like the easiest thing to do, although Esc is certainly in a nice position on the keyboard. Regards, Rob Craig Rapid Deployment Software http://www.RapidEuphoria.com