S
shablool
Hi,
Could someone please explain why stdscr.getxy() always raise an
exception:
import curses
import traceback
def init(stdscr):
x = y = 0
while 1:
c = stdscr.getch()
if c == ord('q'):
break
stdscr.addch(c)
(x, y) = stdscr.getxy()
stdscr.refresh()
def main():
try:
curses.wrapper(init)
except Exception, e:
traceback.print_exc()
if __name__ == "__main__":
main()
Could someone please explain why stdscr.getxy() always raise an
exception:
import curses
import traceback
def init(stdscr):
x = y = 0
while 1:
c = stdscr.getch()
if c == ord('q'):
break
stdscr.addch(c)
(x, y) = stdscr.getxy()
stdscr.refresh()
def main():
try:
curses.wrapper(init)
except Exception, e:
traceback.print_exc()
if __name__ == "__main__":
main()