also fix the backspace problem

parent 2c1a05a1
......@@ -44,7 +44,9 @@ def read_char(s):
(first, char) = get_next_byte(s)
if first == None: # Keyboard special, like KEY_HOME etc
return char
if first <= 127: # ASCII char on one byte
if first == 127 or first == 8:
return "KEY_BACKSPACE"
if first < 127: # ASCII char on one byte
if first <= 26: # transform Ctrl+* keys
char = "^"+chr(first + 64)
if first == 27:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment