|
PLUTO
|
Classes | |
| class | gb |
| The class gb contains global variables and pointers to ease up accessibility in coding the functions of this module. More... | |
Functions | |
| def | SetTitle |
| def | |
| Print a message on the screen. More... | |
| def | Prompt (message) |
| Prompt a message, wait for any key to be pressed. More... | |
| def | ShowMenu |
| Show menu using entries (1st column) and default (2nd column). More... | |
| def | UpDown (entries, default, inc) |
| Allow the cursor to move up and down in the list. More... | |
| def | LeftRight (entries, default, options, inc) |
| Allow left/right keys to switch options in the second column and change default values. More... | |
| def | Browse |
| Browse a menu with entries (1st column) and default (2nd column, optional) Note: with Python > 2.5 we had some troubles initializing curses more than once. More... | |
| def | Insert (entries, default) |
| Similar to Browse, but allow the user to directly input the default values by a reading a string. More... | |
| def | RestoreScreen () |
| Restore screen back to shell functionality. More... | |
| def | CursesIsActive () |
| Return 1 if curses have been activated. More... | |
| def | Print_no_curses (message, sleep, row) |
| The next set of functions replicate the previous ones without using curses library. More... | |
| def | Prompt_no_curses (message) |
| def | Browse_no_curses (entries, default, options) |
| def | Insert_no_curses (entries, names) |
Variables | |
| int | have_curses = 1 |
| tuple | q = raw_input() |
| tuple | i = entries.index(x) |
| string | opt_list = '' |
| tuple | c = raw_input(">> choice ["+default[q]+"] ? ") |
| tuple | newname = raw_input(">> new name ? ") |
| def menu.Browse | ( | entries, | |
default = [], |
|||
options = [] |
|||
| ) |
Browse a menu with entries (1st column) and default (2nd column, optional) Note: with Python > 2.5 we had some troubles initializing curses more than once.
For this reason we prefer to initialize curses only at the beginning.
Definition at line 181 of file menu.py.


| def menu.Browse_no_curses | ( | entries, | |
| default, | |||
| options | |||
| ) |
| def menu.CursesIsActive | ( | ) |
| def menu.Insert | ( | entries, | |
| default | |||
| ) |
| def menu.Insert_no_curses | ( | entries, | |
| names | |||
| ) |
| def menu.LeftRight | ( | entries, | |
| default, | |||
| options, | |||
| inc | |||
| ) |
| def menu.Print | ( | message, | |
sleep = 0.7, |
|||
row = 1 |
|||
| ) |
| def menu.Print_no_curses | ( | message, | |
| sleep, | |||
| row | |||
| ) |
| def menu.Prompt | ( | message | ) |
| def menu.Prompt_no_curses | ( | message | ) |
| def menu.RestoreScreen | ( | ) |
| def menu.SetTitle | ( | title, | |
subtitle = '' |
|||
| ) |
| def menu.ShowMenu | ( | entries, | |
| default, | |||
row = 0 |
|||
| ) |
| def menu.UpDown | ( | entries, | |
| default, | |||
| inc | |||
| ) |