--- /tmp/pyte-0.8.0-215luj7j3/debian/python-pyte-doc_0.8.0-2_all.deb +++ python-pyte-doc_0.8.0-2_all.deb ├── file list │ @@ -1,3 +1,3 @@ │ -rw-r--r-- 0 0 0 4 2020-06-20 14:53:48.000000 debian-binary │ -rw-r--r-- 0 0 0 1440 2020-06-20 14:53:48.000000 control.tar.xz │ --rw-r--r-- 0 0 0 61908 2020-06-20 14:53:48.000000 data.tar.xz │ +-rw-r--r-- 0 0 0 61896 2020-06-20 14:53:48.000000 data.tar.xz ├── control.tar.xz │ ├── control.tar │ │ ├── ./md5sums │ │ │ ├── ./md5sums │ │ │ │┄ Files differ ├── data.tar.xz │ ├── data.tar │ │ ├── file list │ │ │ @@ -22,15 +22,15 @@ │ │ │ -rw-r--r-- 0 root (0) root (0) 4260 2020-06-20 14:53:48.000000 ./usr/share/doc/python-pyte-doc/html/_static/classic.css │ │ │ -rw-r--r-- 0 root (0) root (0) 329 2020-06-20 14:53:48.000000 ./usr/share/doc/python-pyte-doc/html/_static/documentation_options.js │ │ │ -rw-r--r-- 0 root (0) root (0) 286 2020-02-17 15:00:30.000000 ./usr/share/doc/python-pyte-doc/html/_static/file.png │ │ │ -rw-r--r-- 0 root (0) root (0) 10847 2020-06-20 14:53:48.000000 ./usr/share/doc/python-pyte-doc/html/_static/language_data.js │ │ │ -rw-r--r-- 0 root (0) root (0) 90 2020-02-17 15:00:30.000000 ./usr/share/doc/python-pyte-doc/html/_static/minus.png │ │ │ -rw-r--r-- 0 root (0) root (0) 90 2020-02-17 15:00:30.000000 ./usr/share/doc/python-pyte-doc/html/_static/plus.png │ │ │ -rw-r--r-- 0 root (0) root (0) 4395 2020-06-20 14:53:48.000000 ./usr/share/doc/python-pyte-doc/html/_static/pygments.css │ │ │ --rw-r--r-- 0 root (0) root (0) 127014 2020-06-20 14:53:48.000000 ./usr/share/doc/python-pyte-doc/html/api.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 127062 2020-06-20 14:53:48.000000 ./usr/share/doc/python-pyte-doc/html/api.html │ │ │ -rw-r--r-- 0 root (0) root (0) 6222 2020-06-20 14:53:48.000000 ./usr/share/doc/python-pyte-doc/html/changelog.html.gz │ │ │ -rw-r--r-- 0 root (0) root (0) 22615 2020-06-20 14:53:48.000000 ./usr/share/doc/python-pyte-doc/html/genindex.html │ │ │ -rw-r--r-- 0 root (0) root (0) 14855 2020-06-20 14:53:48.000000 ./usr/share/doc/python-pyte-doc/html/index.html │ │ │ -rw-r--r-- 0 root (0) root (0) 1166 2020-06-20 14:53:48.000000 ./usr/share/doc/python-pyte-doc/html/objects.inv │ │ │ -rw-r--r-- 0 root (0) root (0) 4639 2020-06-20 14:53:48.000000 ./usr/share/doc/python-pyte-doc/html/py-modindex.html │ │ │ -rw-r--r-- 0 root (0) root (0) 3243 2020-06-20 14:53:48.000000 ./usr/share/doc/python-pyte-doc/html/search.html │ │ │ -rw-r--r-- 0 root (0) root (0) 15275 2020-06-20 14:53:48.000000 ./usr/share/doc/python-pyte-doc/html/searchindex.js │ │ ├── ./usr/share/doc/python-pyte-doc/html/api.html │ │ │ @@ -79,15 +79,15 @@ │ │ │ class pyte.Stream(screen=None, strict=True)[source] │ │ │

A stream is a state machine that parses a stream of bytes and │ │ │ dispatches events based on what it sees.

│ │ │
│ │ │
Parameters
│ │ │
    │ │ │
  • screen (pyte.screens.Screen) – a screen to dispatch events to.

  • │ │ │ -
  • strict (bool) – check if a given screen implements all required │ │ │ +

  • strict (bool) – check if a given screen implements all required │ │ │ events.

  • │ │ │
│ │ │
│ │ │
│ │ │
│ │ │

Note

│ │ │

Stream only accepts text as input, but if for some reason │ │ │ @@ -164,16 +164,16 @@ │ │ │

│ │ │
│ │ │ class pyte.screens.Cursor(x, y, attrs=Char(data=' ', fg='default', bg='default', bold=False, italics=False, underscore=False, strikethrough=False, reverse=False))[source]
│ │ │

Screen cursor.

│ │ │
│ │ │
Parameters
│ │ │
    │ │ │ -
  • x (int) – 0-based horizontal cursor position.

  • │ │ │ -
  • y (int) – 0-based vertical cursor position.

  • │ │ │ +
  • x (int) – 0-based horizontal cursor position.

  • │ │ │ +
  • y (int) – 0-based vertical cursor position.

  • │ │ │
  • attrs (pyte.screens.Char) – cursor attributes (see │ │ │ select_graphic_rendition() │ │ │ for details).

  • │ │ │
│ │ │
│ │ │
│ │ │
│ │ │ @@ -181,26 +181,26 @@ │ │ │
│ │ │
│ │ │ class pyte.screens.Char[source]
│ │ │

A single styled on-screen character.

│ │ │
│ │ │
Parameters
│ │ │
    │ │ │ -
  • data (str) – unicode character. Invariant: len(data) == 1.

  • │ │ │ -
  • fg (str) – foreground colour. Defaults to "default".

  • │ │ │ -
  • bg (str) – background colour. Defaults to "default".

  • │ │ │ -
  • bold (bool) – flag for rendering the character using bold font. │ │ │ +

  • data (str) – unicode character. Invariant: len(data) == 1.

  • │ │ │ +
  • fg (str) – foreground colour. Defaults to "default".

  • │ │ │ +
  • bg (str) – background colour. Defaults to "default".

  • │ │ │ +
  • bold (bool) – flag for rendering the character using bold font. │ │ │ Defaults to False.

  • │ │ │ -
  • italics (bool) – flag for rendering the character using italic font. │ │ │ +

  • italics (bool) – flag for rendering the character using italic font. │ │ │ Defaults to False.

  • │ │ │ -
  • underscore (bool) – flag for rendering the character underlined. │ │ │ +

  • underscore (bool) – flag for rendering the character underlined. │ │ │ Defaults to False.

  • │ │ │ -
  • strikethrough (bool) – flag for rendering the character with a │ │ │ +

  • strikethrough (bool) – flag for rendering the character with a │ │ │ strike-through line. Defaults to False.

  • │ │ │ -
  • reverse (bool) – flag for swapping foreground and background colours │ │ │ +

  • reverse (bool) – flag for swapping foreground and background colours │ │ │ during rendering. Defaults to False.

  • │ │ │
│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │ @@ -330,16 +330,16 @@ │ │ │ clipped at the top of the screen. Similarly, if the existing │ │ │ screen has less columns than the requested screen, columns will │ │ │ be added at the right, and if it has more – columns will be │ │ │ clipped at the right.

│ │ │
│ │ │
Parameters
│ │ │
    │ │ │ -
  • lines (int) – number of lines in the new screen.

  • │ │ │ -
  • columns (int) – number of columns in the new screen.

  • │ │ │ +
  • lines (int) – number of lines in the new screen.

  • │ │ │ +
  • columns (int) – number of columns in the new screen.

  • │ │ │
│ │ │
│ │ │
│ │ │
│ │ │

Changed in version 0.7.0: If the requested screen size is identical to the current screen │ │ │ size, the method does nothing.

│ │ │
│ │ │ @@ -348,55 +348,55 @@ │ │ │
│ │ │
│ │ │ set_margins(top=None, bottom=None)[source]
│ │ │

Select top and bottom margins for the scrolling region.

│ │ │
│ │ │
Parameters
│ │ │
    │ │ │ -
  • top (int) – the smallest line number that is scrolled.

  • │ │ │ -
  • bottom (int) – the biggest line number that is scrolled.

  • │ │ │ +
  • top (int) – the smallest line number that is scrolled.

  • │ │ │ +
  • bottom (int) – the biggest line number that is scrolled.

  • │ │ │
│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ set_mode(*modes, **kwargs)[source]
│ │ │

Set (enable) a given list of modes.

│ │ │
│ │ │
Parameters
│ │ │ -

modes (list) – modes to set, where each mode is a constant │ │ │ +

modes (list) – modes to set, where each mode is a constant │ │ │ from pyte.modes.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ reset_mode(*modes, **kwargs)[source]
│ │ │

Reset (disable) a given list of modes.

│ │ │
│ │ │
Parameters
│ │ │ -

modes (list) – modes to reset – hopefully, each mode is a │ │ │ +

modes (list) – modes to reset – hopefully, each mode is a │ │ │ constant from pyte.modes.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ define_charset(code, mode)[source]
│ │ │

Define G0 or G1 charset.

│ │ │
│ │ │
Parameters
│ │ │
    │ │ │ -
  • code (str) – character set code, should be a character │ │ │ +

  • code (str) – character set code, should be a character │ │ │ from "B0UK", otherwise ignored.

  • │ │ │ -
  • mode (str) – if "(" G0 charset is defined, if │ │ │ +

  • mode (str) – if "(" G0 charset is defined, if │ │ │ ")" – we operate on G1.

  • │ │ │
│ │ │
│ │ │
│ │ │
│ │ │

Warning

│ │ │

User-defined charsets are currently not supported.

│ │ │ @@ -418,15 +418,15 @@ │ │ │
│ │ │
│ │ │ draw(data)[source]
│ │ │

Display decoded characters at the current cursor position and │ │ │ advances the cursor if DECAWM is set.

│ │ │
│ │ │
Parameters
│ │ │ -

data (str) – text to display.

│ │ │ +

data (str) – text to display.

│ │ │
│ │ │
│ │ │
│ │ │

Changed in version 0.5.0: Character width is taken into account. Specifically, zero-width │ │ │ and unprintable characters do not affect screen state. Full-width │ │ │ characters are rendered into two consecutive character containers.

│ │ │
│ │ │ @@ -524,56 +524,56 @@ │ │ │ delete_lines(count=None)[source] │ │ │

Delete the indicated # of lines, starting at line with │ │ │ cursor. As lines are deleted, lines displayed below cursor │ │ │ move up. Lines added to bottom of screen have spaces with same │ │ │ character attributes as last line moved up.

│ │ │
│ │ │
Parameters
│ │ │ -

count (int) – number of lines to delete.

│ │ │ +

count (int) – number of lines to delete.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ insert_characters(count=None)[source]
│ │ │

Insert the indicated # of blank characters at the cursor │ │ │ position. The cursor does not move and remains at the beginning │ │ │ of the inserted blank characters. Data on the line is shifted │ │ │ forward.

│ │ │
│ │ │
Parameters
│ │ │ -

count (int) – number of characters to insert.

│ │ │ +

count (int) – number of characters to insert.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ delete_characters(count=None)[source]
│ │ │

Delete the indicated # of characters, starting with the │ │ │ character at cursor position. When a character is deleted, all │ │ │ characters to the right of cursor move left. Character attributes │ │ │ move with the characters.

│ │ │
│ │ │
Parameters
│ │ │ -

count (int) – number of characters to delete.

│ │ │ +

count (int) – number of characters to delete.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ erase_characters(count=None)[source]
│ │ │

Erase the indicated # of characters, starting with the │ │ │ character at cursor position. Character attributes are set │ │ │ cursor attributes. The cursor remains in the same position.

│ │ │
│ │ │
Parameters
│ │ │ -

count (int) – number of characters to erase.

│ │ │ +

count (int) – number of characters to erase.

│ │ │
│ │ │
│ │ │
│ │ │

Note

│ │ │

Using cursor attributes for character attributes may seem │ │ │ illogical, but if recall that a terminal emulator emulates │ │ │ a type writer, it starts to make sense. The only way a type │ │ │ @@ -585,50 +585,50 @@ │ │ │

│ │ │ erase_in_line(how=0, private=False)[source]
│ │ │

Erase a line in a specific way.

│ │ │

Character attributes are set to cursor attributes.

│ │ │
│ │ │
Parameters
│ │ │
    │ │ │ -
  • how (int) –

    defines the way the line should be erased in:

    │ │ │ +
  • how (int) –

    defines the way the line should be erased in:

    │ │ │
      │ │ │
    • 0 – Erases from cursor to end of line, including cursor │ │ │ position.

    • │ │ │
    • 1 – Erases from beginning of line to cursor, │ │ │ including cursor position.

    • │ │ │
    • 2 – Erases complete line.

    • │ │ │
    │ │ │

  • │ │ │ -
  • private (bool) – when True only characters marked as │ │ │ +

  • private (bool) – when True only characters marked as │ │ │ eraseable are affected not implemented.

  • │ │ │
│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ erase_in_display(how=0, private=False)[source]
│ │ │

Erases display in a specific way.

│ │ │

Character attributes are set to cursor attributes.

│ │ │
│ │ │
Parameters
│ │ │
    │ │ │ -
  • how (int) –

    defines the way the line should be erased in:

    │ │ │ +
  • how (int) –

    defines the way the line should be erased in:

    │ │ │
      │ │ │
    • 0 – Erases from cursor to end of screen, including │ │ │ cursor position.

    • │ │ │
    • 1 – Erases from beginning of screen to cursor, │ │ │ including cursor position.

    • │ │ │
    • 2 and 3 – Erases complete display. All lines │ │ │ are erased and changed to single-width. Cursor does not │ │ │ move.

    • │ │ │
    │ │ │

  • │ │ │ -
  • private (bool) – when True only characters marked as │ │ │ +

  • private (bool) – when True only characters marked as │ │ │ eraseable are affected not implemented.

  • │ │ │
│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │ @@ -639,15 +639,15 @@ │ │ │ │ │ │
│ │ │
│ │ │ clear_tab_stop(how=0)[source]
│ │ │

Clear a horizontal tab stop.

│ │ │
│ │ │
Parameters
│ │ │ -

how (int) –

defines a way the tab stop should be cleared:

│ │ │ +

how (int) –

defines a way the tab stop should be cleared:

│ │ │
    │ │ │
  • 0 or nothing – Clears a horizontal tab stop at cursor │ │ │ position.

  • │ │ │
  • 3 – Clears all horizontal tab stops.

  • │ │ │
│ │ │

│ │ │
│ │ │ @@ -662,129 +662,129 @@ │ │ │ │ │ │
│ │ │
│ │ │ ensure_vbounds(use_margins=None)[source]
│ │ │

Ensure the cursor is within vertical screen bounds.

│ │ │
│ │ │
Parameters
│ │ │ -

use_margins (bool) – when True or when │ │ │ +

use_margins (bool) – when True or when │ │ │ DECOM is set, │ │ │ cursor is bounded by top and and bottom │ │ │ margins, instead of [0; lines - 1].

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ cursor_up(count=None)[source]
│ │ │

Move cursor up the indicated # of lines in same column. │ │ │ Cursor stops at top margin.

│ │ │
│ │ │
Parameters
│ │ │ -

count (int) – number of lines to skip.

│ │ │ +

count (int) – number of lines to skip.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ cursor_up1(count=None)[source]
│ │ │

Move cursor up the indicated # of lines to column 1. Cursor │ │ │ stops at bottom margin.

│ │ │
│ │ │
Parameters
│ │ │ -

count (int) – number of lines to skip.

│ │ │ +

count (int) – number of lines to skip.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ cursor_down(count=None)[source]
│ │ │

Move cursor down the indicated # of lines in same column. │ │ │ Cursor stops at bottom margin.

│ │ │
│ │ │
Parameters
│ │ │ -

count (int) – number of lines to skip.

│ │ │ +

count (int) – number of lines to skip.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ cursor_down1(count=None)[source]
│ │ │

Move cursor down the indicated # of lines to column 1. │ │ │ Cursor stops at bottom margin.

│ │ │
│ │ │
Parameters
│ │ │ -

count (int) – number of lines to skip.

│ │ │ +

count (int) – number of lines to skip.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ cursor_back(count=None)[source]
│ │ │

Move cursor left the indicated # of columns. Cursor stops │ │ │ at left margin.

│ │ │
│ │ │
Parameters
│ │ │ -

count (int) – number of columns to skip.

│ │ │ +

count (int) – number of columns to skip.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ cursor_forward(count=None)[source]
│ │ │

Move cursor right the indicated # of columns. Cursor stops │ │ │ at right margin.

│ │ │
│ │ │
Parameters
│ │ │ -

count (int) – number of columns to skip.

│ │ │ +

count (int) – number of columns to skip.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ cursor_position(line=None, column=None)[source]
│ │ │

Set the cursor to a specific line and column.

│ │ │

Cursor is allowed to move out of the scrolling region only when │ │ │ DECOM is reset, otherwise – the position │ │ │ doesn’t change.

│ │ │
│ │ │
Parameters
│ │ │
    │ │ │ -
  • line (int) – line number to move the cursor to.

  • │ │ │ -
  • column (int) – column number to move the cursor to.

  • │ │ │ +
  • line (int) – line number to move the cursor to.

  • │ │ │ +
  • column (int) – column number to move the cursor to.

  • │ │ │
│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ cursor_to_column(column=None)[source]
│ │ │

Move cursor to a specific column in the current line.

│ │ │
│ │ │
Parameters
│ │ │ -

column (int) – column number to move the cursor to.

│ │ │ +

column (int) – column number to move the cursor to.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ cursor_to_line(line=None)[source]
│ │ │

Move cursor to a specific line in the current column.

│ │ │
│ │ │
Parameters
│ │ │ -

line (int) – line number to move the cursor to.

│ │ │ +

line (int) – line number to move the cursor to.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ bell(*args)[source]
│ │ │ @@ -800,15 +800,15 @@ │ │ │ │ │ │
│ │ │
│ │ │ select_graphic_rendition(*attrs)[source]
│ │ │

Set display attributes.

│ │ │
│ │ │
Parameters
│ │ │ -

attrs (list) – a list of display attributes to set.

│ │ │ +

attrs (list) – a list of display attributes to set.

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ report_device_attributes(mode=0, **kwargs)[source]
│ │ │ @@ -824,15 +824,15 @@ │ │ │ │ │ │
│ │ │
│ │ │ report_device_status(mode)[source]
│ │ │

Report terminal status or cursor position.

│ │ │
│ │ │
Parameters
│ │ │ -

mode (int) – if 5 – terminal status, 6 – cursor position, │ │ │ +

mode (int) – if 5 – terminal status, 6 – cursor position, │ │ │ otherwise a noop.

│ │ │
│ │ │
│ │ │
│ │ │

New in version 0.5.0.

│ │ │
│ │ │
│ │ │ @@ -840,15 +840,15 @@ │ │ │
│ │ │
│ │ │ write_process_input(data)[source]
│ │ │

Write data to the process running inside the terminal.

│ │ │

By default is a noop.

│ │ │
│ │ │
Parameters
│ │ │ -

data (str) – text to write to the process stdin.

│ │ │ +

data (str) – text to write to the process stdin.

│ │ │
│ │ │
│ │ │
│ │ │

New in version 0.5.0.

│ │ │
│ │ │
│ │ │ │ │ │ @@ -890,17 +890,17 @@ │ │ │ class pyte.screens.HistoryScreen(columns, lines, history=100, ratio=0.5)[source] │ │ │

A :class:~`pyte.screens.Screen` subclass, which keeps track │ │ │ of screen history and allows pagination. This is not linux-specific, │ │ │ but still useful; see page 462 of VT520 User’s Manual.

│ │ │
│ │ │
Parameters
│ │ │
    │ │ │ -
  • history (int) – total number of history lines to keep; is split │ │ │ +

  • history (int) – total number of history lines to keep; is split │ │ │ between top and bottom queues.

  • │ │ │ -
  • ratio (int) – defines how much lines to scroll on next_page() │ │ │ +

  • ratio (int) – defines how much lines to scroll on next_page() │ │ │ and prev_page() calls.

  • │ │ │
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ history
│ │ │ @@ -936,28 +936,28 @@ │ │ │
│ │ │
│ │ │
│ │ │ before_event(event)[source]
│ │ │

Ensure a screen is at the bottom of the history buffer.

│ │ │
│ │ │
Parameters
│ │ │ -

event (str) – event name, for example "linefeed".

│ │ │ +

event (str) – event name, for example "linefeed".

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ after_event(event)[source]
│ │ │

Ensure all lines on a screen have proper width (columns).

│ │ │

Extra characters are truncated, missing characters are filled │ │ │ with whitespace.

│ │ │
│ │ │
Parameters
│ │ │ -

event (str) – event name, for example "linefeed".

│ │ │ +

event (str) – event name, for example "linefeed".

│ │ │
│ │ │
│ │ │
│ │ │ │ │ │
│ │ │
│ │ │ reset()[source]
│ │ │ @@ -1021,15 +1021,15 @@ │ │ │ ["select_graphic_rendition", [0, 10], {}] │ │ │
│ │ │ │ │ │
│ │ │
Parameters
│ │ │
    │ │ │
  • to (file) – a file-like object to write debug information to.

  • │ │ │ -
  • only (list) – a list of events you want to debug (empty by │ │ │ +

  • only (list) – a list of events you want to debug (empty by │ │ │ default, which means – debug all events).

  • │ │ │
│ │ │
│ │ │
│ │ │
│ │ │

Warning

│ │ │

This is developer API with no backward compatibility guarantees.