| |
- screen.screen
-
- term
-
- ANSI
class ANSI(term) |
|
This class encapsulates a generic terminal.
It filters a stream and maintains the state of
a screen object. |
|
- Method resolution order:
- ANSI
- term
- screen.screen
Methods defined here:
- __init__(self, r=24, c=80)
- process(self, c)
- process_list(self, l)
- test(self)
- write(self, ch)
- Puts a character at the current cursor position.
cursor position if moved forward with wrap-around, but
no scrolling is done if the cursor hits the lower-right corner
of the screen.
and
both produce a call to crlf().
Methods inherited from screen.screen:
- __str__(self)
- clear_all_tabs(self)
- Clears all tabs.
- clear_tab(self)
- Clears tab at the current position.
- cr(self)
- This moves the cursor to the beginning (col 1) of the current row.
- crlf(self)
- This advances the cursor with CRLF properties.
The cursor will line wrap and the screen may scroll.
- cursor_back(self, count=1)
- cursor_constrain(self)
- This keeps the cursor within the screen area.
- cursor_down(self, count=1)
- cursor_force_position(self, r, c)
- Identical to Cursor Home.
- cursor_forward(self, count=1)
- cursor_home(self, r=1, c=1)
- cursor_restore_attrs(self)
- Restores cursor position after a Save Cursor.
- cursor_save(self)
- Save current cursor position.
- cursor_save_attrs(self)
- Save current cursor position.
- cursor_unsave(self)
- Restores cursor position after a Save Cursor.
- cursor_up(self, count=1)
- cursor_up_reverse(self)
- erase_down(self)
- Erases the screen from the current line down to
the bottom of the screen.
- erase_end_of_line(self)
- Erases from the current cursor position to
the end of the current line.
- erase_line(self)
- Erases the entire current line.
- erase_screen(self)
- Erases the screen with the background color.
- erase_start_of_line(self)
- Erases from the current cursor position to
the start of the current line.
- erase_up(self)
- Erases the screen from the current line up to
the top of the screen.
- fill(self, ch=' ')
- fill_region(self, rs, cs, re, ce, ch=' ')
- get(self)
- get_abs(self, r, c)
- get_region(self, rs, cs, re, ce)
- This returns a list of lines representing the region.
- insert(self, ch)
- insert_abs(self, r, c, ch)
- This inserts a character at (r,c). Everything under
and to the right is shifted right one character.
The last character of the line is lost.
- lf(self)
- This moves the cursor down with scrolling.
- put(self, ch)
- put_abs(self, r, c, ch)
- Screen array starts at 1 index.
- scroll_constrain(self)
- This keeps the scroll region within the screen region.
- scroll_down(self)
- Scroll display down one line.
- scroll_screen(self)
- Enable scrolling for entire display.
- scroll_screen_rows(self, rs, re)
- Enable scrolling from row {start} to row {end}.
- scroll_up(self)
- Scroll display up one line.
- set_tab(self)
- Sets a tab at the current position.
|
class term(screen.screen) |
|
This is a placeholder.
In theory I might want to add other terminal types. |
|
Methods defined here:
- __init__(self, r=24, c=80)
Methods inherited from screen.screen:
- __str__(self)
- clear_all_tabs(self)
- Clears all tabs.
- clear_tab(self)
- Clears tab at the current position.
- cr(self)
- This moves the cursor to the beginning (col 1) of the current row.
- crlf(self)
- This advances the cursor with CRLF properties.
The cursor will line wrap and the screen may scroll.
- cursor_back(self, count=1)
- cursor_constrain(self)
- This keeps the cursor within the screen area.
- cursor_down(self, count=1)
- cursor_force_position(self, r, c)
- Identical to Cursor Home.
- cursor_forward(self, count=1)
- cursor_home(self, r=1, c=1)
- cursor_restore_attrs(self)
- Restores cursor position after a Save Cursor.
- cursor_save(self)
- Save current cursor position.
- cursor_save_attrs(self)
- Save current cursor position.
- cursor_unsave(self)
- Restores cursor position after a Save Cursor.
- cursor_up(self, count=1)
- cursor_up_reverse(self)
- erase_down(self)
- Erases the screen from the current line down to
the bottom of the screen.
- erase_end_of_line(self)
- Erases from the current cursor position to
the end of the current line.
- erase_line(self)
- Erases the entire current line.
- erase_screen(self)
- Erases the screen with the background color.
- erase_start_of_line(self)
- Erases from the current cursor position to
the start of the current line.
- erase_up(self)
- Erases the screen from the current line up to
the top of the screen.
- fill(self, ch=' ')
- fill_region(self, rs, cs, re, ce, ch=' ')
- get(self)
- get_abs(self, r, c)
- get_region(self, rs, cs, re, ce)
- This returns a list of lines representing the region.
- insert(self, ch)
- insert_abs(self, r, c, ch)
- This inserts a character at (r,c). Everything under
and to the right is shifted right one character.
The last character of the line is lost.
- lf(self)
- This moves the cursor down with scrolling.
- put(self, ch)
- put_abs(self, r, c, ch)
- Screen array starts at 1 index.
- scroll_constrain(self)
- This keeps the scroll region within the screen region.
- scroll_down(self)
- Scroll display down one line.
- scroll_screen(self)
- Enable scrolling for entire display.
- scroll_screen_rows(self, rs, re)
- Enable scrolling from row {start} to row {end}.
- scroll_up(self)
- Scroll display up one line.
- set_tab(self)
- Sets a tab at the current position.
| |