^[control-codes live in libghostty-vt

ANSI modes

SRTM Status Report Transfer Mode

Whether a status report goes with every transmission.

CSI 5 h
ECMA-48
§7.2.16 SRTM – Status Report Transfer Mode, p. 24
DEC STD 070
§5.10.1.3 Modes That Cannot Be Changed, p. 5-134

Mode 5 decides whether the terminal adds a status report, as a device control string, to everything it transmits. It is a diagnostic for block-mode terminals.

StateECMA-48 calls itMeaning
Reset, CSI 5 lNORMALstatus reports are not sent on their own
Set, CSI 5 hDIAGNOSTICa status report is included in every transmission

DEC STD 070 §5.10.1.3, p. 5-134 lists it among the X3.64 modes a DEC terminal may treat as fixed, as reset. The VT510 manual’s table of modes for DECRPM marks it as always reset.

xterm ignores CSI 5 h and CSI 5 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

SRTM-1: Reported as permanently reset

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

SRTM-2: Even after it is set

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