Are there any known terminals which support the ANSI escape sequences for cursor keys up, down, forward and back:
CSI n A Cursor Up
CSI n B Cursor Down
CSI n C Cursor Forward
CSI n D Cursor Back
but don't support the save-cursor-position and restore-cursor-position escape sequences?
CSI s Save Cursor Position
CSI u Restore Cursor Position
Escape sequence is used to escape from the normal representation of the string. It is a combination of \ (Backslash) and some character. As an example, \n is used to move cursor to the new line and \r is used to move the cursor to the beginning of the current line.
Background Colors Background Black: \u001b[40m. Background Red: \u001b[41m. Background Green: \u001b[42m. Background Yellow: \u001b[43m.
ANSI escape sequences are a standard for in-band signaling to control cursor location, color, font styling, and other options on video text terminals and terminal emulators. Certain sequences of bytes, most starting with an ASCII escape character and a bracket character, are embedded into text.
A genuine VT100 (or VT220 for that matter) did not recognize these control sequences for save/restore cursor position. They use (as noted in xterm's control sequences list)
ESC 7 Save Cursor (DECSC).
ESC 8 Restore Cursor (DECRC).
Those are the sc
and rc
capabilities in terminfo; you may see these listed using
infocmp vt100
infocmp vt220
The origin of CSI s
and CSI u
likely is from ansi.sys
(see terminal database entry for ansi.sys-old), though an older source is always possible.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With