diff options
| author | Simon Robertshaw <simon@hardwired.org.uk> | 2011-10-26 13:50:50 (GMT) |
|---|---|---|
| committer | Simon Robertshaw <simon@hardwired.org.uk> | 2011-10-26 13:50:50 (GMT) |
| commit | e46ef289e142982d7bd592faa7b0f85470364c01 (patch) | |
| tree | cda253e03788f7db0a7cdcd05662f66b4455e298 /src/python/stdlib/test/curses_tests.py | |
| parent | d0d0d62bbcbb5c3417f8cba419c83bac192ea985 (diff) | |
| download | powder-e46ef289e142982d7bd592faa7b0f85470364c01.zip powder-e46ef289e142982d7bd592faa7b0f85470364c01.tar.gz | |
Remove Python console stuff
Diffstat (limited to 'src/python/stdlib/test/curses_tests.py')
| -rw-r--r-- | src/python/stdlib/test/curses_tests.py | 46 |
1 files changed, 0 insertions, 46 deletions
diff --git a/src/python/stdlib/test/curses_tests.py b/src/python/stdlib/test/curses_tests.py deleted file mode 100644 index 7dedbbc..0000000 --- a/src/python/stdlib/test/curses_tests.py +++ /dev/null @@ -1,46 +0,0 @@ -#!/usr/bin/env python -# -# $Id: ncurses.py 36559 2004-07-18 05:56:09Z tim_one $ -# -# Interactive test suite for the curses module. -# This script displays various things and the user should verify whether -# they display correctly. -# - -import curses -from curses import textpad - -def test_textpad(stdscr, insert_mode=False): - ncols, nlines = 8, 3 - uly, ulx = 3, 2 - if insert_mode: - mode = 'insert mode' - else: - mode = 'overwrite mode' - - stdscr.addstr(uly-3, ulx, "Use Ctrl-G to end editing (%s)." % mode) - stdscr.addstr(uly-2, ulx, "Be sure to try typing in the lower-right corner.") - win = curses.newwin(nlines, ncols, uly, ulx) - textpad.rectangle(stdscr, uly-1, ulx-1, uly + nlines, ulx + ncols) - stdscr.refresh() - - box = textpad.Textbox(win, insert_mode) - contents = box.edit() - stdscr.addstr(uly+ncols+2, 0, "Text entered in the box\n") - stdscr.addstr(repr(contents)) - stdscr.addstr('\n') - stdscr.addstr('Press any key') - stdscr.getch() - - for i in range(3): - stdscr.move(uly+ncols+2 + i, 0) - stdscr.clrtoeol() - -def main(stdscr): - stdscr.clear() - test_textpad(stdscr, False) - test_textpad(stdscr, True) - - -if __name__ == '__main__': - curses.wrapper(main) |
