^[control-codes
live in libghostty-vt

Device control strings

View as Markdown

Functions carried by a device control string: DCS, what identifies the function, then data, then ST. A string can carry much more than a control sequence’s parameters, which is why DEC used it for key definitions and soft fonts, and why xterm uses it for questions whose answers are text.

DECAUPSS Assign User-Preference Supplemental Set DCS Ps ! u Pt ST …
DECDLD Down Line Load DCS Pfn ; Pcn ; Pe ; Pcmw ; Pss ; Pu ; Pcmh ; Pcss { Dscs Sxbp1 ; … ; Sxbpn ST …
DECRPSS Report Selection or Setting
DECRQSS Request Selection or Setting DCS $ q Pt ST …
DECRQUPSS Request User-Preference Supplemental Set
DECUDK User Defined Keys DCS Pc ; Pl | Ky1/St1 ; … ; Kyn/Stn ST …
ReGIS Remote Graphic Instruction Set DCS Pm p commands ST …
Sixel Sixel Graphics DCS P1 ; P2 ; P3 q s…s ST …
XTGETTCAP Request Termcap/Terminfo String DCS + q Pt ST …
XTGETXRES Request Resource Values DCS + Q Pt ST …
XTSETTCAP Set Termcap Data DCS + p Pt ST …
Every example on these pages runs in your browser, in libghostty-vt compiled to WebAssembly.