^[control-codes live in libghostty-vt

ANSI modes

TTM Transfer Termination Mode

Whether a transmission stops at the cursor.

CSI 16 h
ECMA-48
§7.2.18 TTM – Transfer Termination Mode, p. 25

Mode 16 decides whether a transmission of the screen stops at the cursor, or takes in what follows it as well.

StateECMA-48 calls itMeaning
Reset, CSI 16 lCURSORonly what precedes the cursor is sent
Set, CSI 16 hALLwhat precedes, follows and is at the cursor is sent

DEC STD 070 does not list it, but the VT510 manual’s table of ANSI modes for DECRPM gives it as permanently reset.

xterm ignores CSI 16 h and CSI 16 l (ansi_modes handles only modes 2, 4, 12 and 20), and DECRQM reports the mode as permanently reset, 4 (do_ansi_rqm). libghostty-vt ignores it too, but does not recognize the number, so it answers DECRQM with 0. Both DECRQM cases are known differences.

Validation

TTM-1: Reported as permanently reset

\e[16$p
|_____|
reply \e[16;4$y

TTM-2: Even after it is set

\e[16h
\e[16$p
|_____|
reply \e[16;4$y
Every example on these pages runs in your browser, in libghostty-vt compiled to WebAssembly.