Modules
A terminal emulator: bytes in, cell grid out.
One character cell.
Terminal display width of text, in columns.
A cell colour: terminal default, a palette index, or a direct RGB triple.
Applies parser events to a grid: the terminal's actual behaviour.
The character grid: a fixed cols by rows rectangle of cells.
A byte-stream state machine over the DEC ANSI / ECMA-48 grammar.
A bounded history of rows that have scrolled off the top of the screen.
Foreground, background, and text attributes for a cell.
The last limit lines of a stream, kept as they arrive.