Terminal width in columns.
Terminal height in rows.
Clear captured output.
Hide the terminal cursor.
Simulate keyboard input.
Simulate terminal resize.
Show the terminal cursor.
Enter raw mode, enable Kitty level 1 keyboard reporting, enable bracketed paste mode, enable mouse tracking, and hide the cursor.
The framework prefers Kitty semantics but its parser also accepts mixed tmux/legacy keyboard encodings that may still arrive on stdin.
Restore terminal state.
Write a string to the terminal output.
In-memory terminal for testing.
Captures all written output into a buffer and allows setting fixed dimensions. No real I/O.