summaryrefslogtreecommitdiffstats
path: root/cholerab/cholerab-live
diff options
context:
space:
mode:
authormakefu <github@syntax-fehler.de>2011-07-21 00:37:13 +0200
committermakefu <github@syntax-fehler.de>2011-07-21 00:37:13 +0200
commit82fda4544b2d3a04a2c67d8af2e11ddce0c61195 (patch)
tree52db0fe3bf42737a8039aece1efc42215e0eddfb /cholerab/cholerab-live
parent1e604f2408861120d8168a3f88c29f9da3ddf7df (diff)
fixed cur_set bug/added todo
Diffstat (limited to 'cholerab/cholerab-live')
-rw-r--r--cholerab/cholerab-live/view.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/cholerab/cholerab-live/view.py b/cholerab/cholerab-live/view.py
index 34891e5c..b798e712 100644
--- a/cholerab/cholerab-live/view.py
+++ b/cholerab/cholerab-live/view.py
@@ -26,6 +26,7 @@ class CursesView(threading.Thread):
elif c == KEY_UP : self.y -=1
elif c == KEY_DOWN : self.y +=1
elif c == ord('q') : self.stop()
+ #TODO handle backspace correctly
else :
try:
self.win.addch(c) #TODO UTF8 here
@@ -57,10 +58,13 @@ class CursesView(threading.Thread):
self.cholerab = cholerab
threading.Thread.__init__(self)
self.scr = initscr()
- noecho()
+ noecho()
cbreak()
self.scr.keypad(1)
- curs_set(2)
+ try:
+ curs_set(2)
+ except: # go home with your non-standard terminals!
+ pass
begin_x = 0;begin_y = 0
self.height = height