Skip to main content

Module buffer

Module buffer 

Source
Expand description

The cell grid: a width × height array of Cells that widgets draw into. Two buffers (front = on screen, back = next frame) are diffed so the terminal only receives the cells that actually changed.

Structs§

Buffer
Cell
One character cell. '\0' marks a transparent cell — it is skipped when a surface is composited, letting lower layers show through.

Constants§

WIDE_CONT
Marker in the cell to the right of a double-width glyph. Skipped when flushing ANSI so the terminal does not advance an extra column.

Functions§

center_pad
Pad text to exactly width display columns (centered).
chip_cols
Shared chip width that exactly centers the greatest number of labels.
label_cols
Display columns for a label with pad blank cells on each side.