Constants
AltScreenBufferMode = DECMode.new(1049)
Alternate Screen Buffer mode.
Deprecated: use [ModeAltScreenSaveCursor] instead.
AltScreenMode = DECMode.new(1047)
Alternate Screen Mode determines whether the alternate screen buffer is active.
Deprecated: use [ModeAltScreen] instead.
AltScreenSaveCursorMode = DECMode.new(1049)
Alternate Screen Save Cursor Mode saves the cursor position and switches to alternate screen.
Deprecated: use [ModeAltScreenSaveCursor] instead.
AnyEventMouseMode = DECMode.new(1003)
Any Event Mouse Tracking reports all motion events.
Deprecated: use [ModeMouseAnyEvent] instead.
AttrBlackBackgroundColor = 40
AttrBlackForegroundColor = 30
AttrBlueBackgroundColor = 44
AttrBlueForegroundColor = 34
AttrBrightBlackBackgroundColor = 100
AttrBrightBlackForegroundColor = 90
AttrBrightBlueBackgroundColor = 104
AttrBrightBlueForegroundColor = 94
AttrBrightCyanBackgroundColor = 106
AttrBrightCyanForegroundColor = 96
AttrBrightGreenBackgroundColor = 102
AttrBrightGreenForegroundColor = 92
AttrBrightMagentaBackgroundColor = 105
AttrBrightMagentaForegroundColor = 95
AttrBrightRedBackgroundColor = 101
AttrBrightRedForegroundColor = 91
AttrBrightWhiteBackgroundColor = 107
AttrBrightWhiteForegroundColor = 97
AttrBrightYellowBackgroundColor = 103
AttrBrightYellowForegroundColor = 93
AttrCyanBackgroundColor = 46
AttrCyanForegroundColor = 36
AttrDefaultBackgroundColor = 49
AttrDefaultForegroundColor = 39
AttrDefaultUnderlineColor = 59
AttrExtendedBackgroundColor = 48
AttrExtendedColorIntroducer = 5
AttrExtendedForegroundColor = 38
AttrExtendedUnderlineColor = 58
AttrGreenBackgroundColor = 42
AttrGreenForegroundColor = 32
AttrMagentaBackgroundColor = 45
AttrMagentaForegroundColor = 35
AttrRedBackgroundColor = 41
AttrRedForegroundColor = 31
AttrReset = 0
SGR (Select Graphic Rendition) style attributes.
See: https://en.wikipedia.org/wiki/ANSI_escape_code#SGR_(Select_Graphic_Rendition)_parameters
AttrRGBColorIntroducer = 2
AttrWhiteBackgroundColor = 47
AttrWhiteForegroundColor = 37
AttrYellowBackgroundColor = 43
AttrYellowForegroundColor = 33
AutoWrapMode = DECMode.new(7)
Auto Wrap Mode (DECAWM) determines whether the cursor wraps to the next line.
Deprecated: use [ModeAutoWrap] instead.
BackarrowKeyMode = DECMode.new(67)
Backarrow Key Mode (DECBKM) determines whether the backspace key sends backspace or delete.
Deprecated: use [ModeBackarrowKey] instead.
BDSM = ModeBiDirectionalSupport
BiDirectionalSupportMode = ANSIMode.new(8)
BiDirectional Support Mode (BDSM) determines whether the terminal supports bidirectional text.
Deprecated: use [ModeBiDirectionalSupport] instead.
BlackBackgroundColorAttr = AttrBlackBackgroundColor
BlackForegroundColorAttr = AttrBlackForegroundColor
BlueBackgroundColorAttr = AttrBlueBackgroundColor
BlueForegroundColorAttr = AttrBlueForegroundColor
Blur = "\e[O"
Blur is an escape sequence to notify the terminal that it has lost focus.
This is used with [ModeFocusEvent].
BracketedPasteEnd = "\e[201~"
BracketedPasteEnd is the control sequence to disable bracketed paste mode.
BracketedPasteMode = DECMode.new(2004)
Bracketed Paste Mode determines whether pasted text is bracketed with escape sequences.
Deprecated: use [ModeBracketedPaste] instead.
BracketedPasteStart = "\e[200~"
BracketedPasteStart is the control sequence to enable bracketed paste mode.
BrightBlackBackgroundColorAttr = AttrBrightBlackBackgroundColor
BrightBlackForegroundColorAttr = AttrBrightBlackForegroundColor
BrightBlueBackgroundColorAttr = AttrBrightBlueBackgroundColor
BrightBlueForegroundColorAttr = AttrBrightBlueForegroundColor
BrightCyanBackgroundColorAttr = AttrBrightCyanBackgroundColor
BrightCyanForegroundColorAttr = AttrBrightCyanForegroundColor
BrightGreenBackgroundColorAttr = AttrBrightGreenBackgroundColor
BrightGreenForegroundColorAttr = AttrBrightGreenForegroundColor
BrightMagentaBackgroundColorAttr = AttrBrightMagentaBackgroundColor
BrightMagentaForegroundColorAttr = AttrBrightMagentaForegroundColor
BrightRedBackgroundColorAttr = AttrBrightRedBackgroundColor
BrightRedForegroundColorAttr = AttrBrightRedForegroundColor
BrightWhiteBackgroundColorAttr = AttrBrightWhiteBackgroundColor
BrightWhiteForegroundColorAttr = AttrBrightWhiteForegroundColor
BrightYellowBackgroundColorAttr = AttrBrightYellowBackgroundColor
BrightYellowForegroundColorAttr = AttrBrightYellowForegroundColor
ButtonEventMouseMode = DECMode.new(1002)
Button Event Mouse Tracking reports button-motion events when a button is pressed.
Deprecated: use [ModeMouseButtonEvent] instead.
ConcealAttr = AttrConceal
CUB1 = "\e[D"
CUB1 is a sequence for moving the cursor left one cell.
CUD1 = "\e[B"
CUD1 is a sequence for moving the cursor down one cell.
CUF1 = "\e[C"
CUF1 is a sequence for moving the cursor right one cell.
CursorDown1 = "\e[B"
CursorDown1 is a sequence for moving the cursor down one cell.
This is equivalent to CursorDown(1).
Deprecated: use [CUD1] instead.
CursorEnableMode = DECMode.new(25)
Text Cursor Enable mode.
Deprecated: use [SetModeTextCursorEnable] and [ResetModeTextCursorEnable] instead.
CursorHomePosition = "\e[H"
CursorHomePosition is a sequence for moving the cursor to the upper left
corner of the scrolling region.
This is equivalent to [cursor_position](1, 1).
CursorKeysMode = DECMode.new(1)
Cursor Keys Mode (DECCKM) determines whether cursor keys send ANSI or application sequences.
Deprecated: use [ModeCursorKeys] instead.
CursorLeft1 = CUB1
CursorLeft1 is a sequence for moving the cursor left one cell.
This is equivalent to CursorLeft(1).
Deprecated: use [CUB1] instead.
CursorOrigin = "\e[1;1H"
CursorOrigin is a sequence for moving the cursor to the upper left corner of
the display. This is equivalent to set_cursor_position(1, 1).
Deprecated: use [CursorHomePosition] instead.
CursorRight1 = CUF1
CursorRight1 is a sequence for moving the cursor right one cell.
This is equivalent to CursorRight(1).
Deprecated: use [CUF1] instead.
CursorUp1 = "\e[A"
CursorUp1 is a sequence for moving the cursor up one cell.
This is equivalent to CursorUp(1).
Deprecated: use [CUU1] instead.
CUU1 = "\e[A"
CUU1 is a sequence for moving the cursor up one cell.
CyanBackgroundColorAttr = AttrCyanBackgroundColor
CyanForegroundColorAttr = AttrCyanForegroundColor
DECBKM = ModeBackarrowKey
DECKPAM = KeypadApplicationMode
DECKPNM = KeypadNumericMode
DECLRMM = ModeLeftRightMargin
DECNKM = ModeNumericKeypad
DECST8C = SetTabEvery8Columns
DECTCEM = ModeTextCursorEnable
DefaultBackgroundColorAttr = AttrDefaultBackgroundColor
DefaultForegroundColorAttr = AttrDefaultForegroundColor
DefaultUnderlineColorAttr = AttrDefaultUnderlineColor
DisableAltScreenBuffer = "\e[?1049l"
DisableBracketedPaste = "\e[?2004l"
DisableCursorKeys = "\e[?1l"
DisableGraphemeClustering = "\e[?2027l"
DisableKittyKeyboard = "\e[>u"
DisableKittyKeyboard is a sequence to push zero into the terminal Kitty
Keyboard stack to disable the protocol.
This is equivalent to PushKittyKeyboard(0).
DisableModifyOtherKeys = "\e[>4;0m"
DisableModifyOtherKeys disables the modifyOtherKeys mode.
CSI > 4 ; 0 m
See: https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-Functions-using-CSI--ordered-by-the-final-character_s
See: https://invisible-island.net/xterm/manpage/xterm.html#VT100-Widget-Resources:modifyOtherKeys
Deprecated: use [ResetModifyOtherKeys] instead.
DisableMouse = "\e[?1000l"
DisableMouseAllMotion = "\e[?1003l"
DisableMouseCellMotion = "\e[?1002l"
DisableMouseHilite = "\e[?1001l"
DisableMouseSgrExt = "\e[?1006l"
DisableReportFocus = "\e[?1004l"
DisableSyncdOutput = "\e[?2026l"
DisableWin32Input = "\e[?9001l"
EnableAltScreenBuffer = "\e[?1049h"
EnableBracketedPaste = "\e[?2004h"
Deprecated: use [SetModeBracketedPaste], [ResetModeBracketedPaste], and
[RequestModeBracketedPaste] instead.
EnableCursorKeys = "\e[?1h"
Cursor Keys mode.
Deprecated: use [SetModeCursorKeys] and [ResetModeCursorKeys] instead.
EnableGraphemeClustering = "\e[?2027h"
Unicode Core mode.
Deprecated: use [SetModeUnicodeCore], [ResetModeUnicodeCore], and
[RequestModeUnicodeCore] instead.
EnableModifyOtherKeys1 = "\e[>4;1m"
EnableModifyOtherKeys1 enables the modifyOtherKeys mode 1.
CSI > 4 ; 1 m
See: https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-Functions-using-CSI--ordered-by-the-final-character_s
See: https://invisible-island.net/xterm/manpage/xterm.html#VT100-Widget-Resources:modifyOtherKeys
Deprecated: use [SetModifyOtherKeys1] instead.
EnableModifyOtherKeys2 = "\e[>4;2m"
EnableModifyOtherKeys2 enables the modifyOtherKeys mode 2.
CSI > 4 ; 2 m
See: https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-Functions-using-CSI--ordered-by-the-final-character_s
See: https://invisible-island.net/xterm/manpage/xterm.html#VT100-Widget-Resources:modifyOtherKeys
Deprecated: use [SetModifyOtherKeys2] instead.
EnableMouse = "\e[?1000h"
EnableMouseAllMotion = "\e[?1003h"
EnableMouseCellMotion = "\e[?1002h"
EnableMouseHilite = "\e[?1001h"
EnableMouseSgrExt = "\e[?1006h"
EnableReportFocus = "\e[?1004h"
EnableSyncdOutput = "\e[?2026h"
EnableWin32Input = "\e[?9001h"
Deprecated: use [SetModeWin32Input], [ResetModeWin32Input], and
[RequestModeWin32Input] instead.
EraseEntireDisplay = "\e[3J"
EraseEntireLine = "\e[2K"
EraseEntireScreen = "\e[2J"
EraseLineRight = "\e[K"
EraseLine constants.
These are the possible values for the EraseLine function.
EraseScreenAbove = "\e[1J"
EraseScreenBelow = "\e[J"
EraseDisplay constants.
These are the possible values for the EraseDisplay function.
ExtendedBackgroundColorAttr = AttrExtendedBackgroundColor
ExtendedColorIntroducerAttr = AttrExtendedColorIntroducer
ExtendedForegroundColorAttr = AttrExtendedForegroundColor
ExtendedUnderlineColorAttr = AttrExtendedUnderlineColor
Focus = "\e[I"
Focus is an escape sequence to notify the terminal that it has focus.
This is used with [ModeFocusEvent].
FocusEventMode = DECMode.new(1004)
Focus Event Mode determines whether the terminal reports focus and blur events.
Deprecated: use [ModeFocusEvent] instead.
GraphemeClusteringMode = DECMode.new(2027)
Grapheme Clustering Mode determines whether the terminal looks for grapheme clusters.
Deprecated: use [ModeUnicodeCore], [SetModeUnicodeCore],
[ResetModeUnicodeCore], and [RequestModeUnicodeCore] instead.
GraphemeWidth = Method::GraphemeWidth
GreenBackgroundColorAttr = AttrGreenBackgroundColor
GreenForegroundColorAttr = AttrGreenForegroundColor
HideCursor = ResetModeTextCursorEnable
HighlightMouseMode = DECMode.new(1001)
Highlight Mouse Tracking determines whether the mouse reports on button presses and highlighted cells.
Deprecated: use [ModeMouseHighlight] instead.
HomeCursorPosition = CursorHomePosition
HomeCursorPosition is a sequence for moving the cursor to the upper left
corner of the scrolling region. This is equivalent to set_cursor_position(1, 1).
Deprecated: use [CursorHomePosition] instead.
HorizontalTabSet = "\eH"
HorizontalTabSet (HTS) sets a horizontal tab stop at the current cursor
column.
This is equivalent to [HTS].
ESC H
See: https://vt100.net/docs/vt510-rm/HTS.html
HorizontalVerticalHomePosition = "\e[f"
HorizontalVerticalHomePosition is a sequence for moving the cursor to the
upper left corner of the scrolling region. This is equivalent to
horizontal_vertical_position(1, 1).
InBandResizeMode = DECMode.new(2048)
In Band Resize Mode reports terminal resize events as escape sequences.
Deprecated: use [ModeInBandResize] instead.
Index = "\eD"
Index (IND) is an escape sequence for moving the cursor down one line in the
same column. If the cursor is at the bottom margin, the screen scrolls up.
This has the same effect as [IND].
InsertReplaceMode = ANSIMode.new(4)
Insert/Replace Mode (IRM) determines whether characters are inserted or replaced.
Deprecated: use [ModeInsertReplace] instead.
KeyboardActionMode = ANSIMode.new(2)
Keyboard Action Mode (KAM) controls locking of the keyboard.
Deprecated: use [ModeKeyboardAction] instead.
KeypadApplicationMode = "\e="
Keypad Application Mode (DECKPAM) is a mode that determines whether the
keypad sends application sequences or ANSI sequences.
This works like enabling [DECNKM].
Use [ModeNumericKeypad] to set the numeric keypad mode.
ESC =
See: https://vt100.net/docs/vt510-rm/DECKPAM.html
KeypadNumericMode = "\e>"
Keypad Numeric Mode (DECKPNM) is a mode that determines whether the keypad
sends application sequences or ANSI sequences.
This works the same as disabling [DECNKM].
ESC >
See: https://vt100.net/docs/vt510-rm/DECKPNM.html
KittyAllFlags = (((KittyDisambiguateEscapeCodes | KittyReportEventTypes) | KittyReportAlternateKeys) | KittyReportAllKeysAsEscapeCodes) | KittyReportAssociatedKeys
KittyDisambiguateEscapeCodes = 1
Kitty keyboard protocol progressive enhancement flags.
See: https://sw.kovidgoyal.net/kitty/keyboard-protocol/#progressive-enhancement
KittyReportAllKeysAsEscapeCodes = 1 << 3
KittyReportAlternateKeys = 1 << 2
KittyReportAssociatedKeys = 1 << 4
KittyReportEventTypes = 1 << 1
LeftRightMarginMode = DECMode.new(69)
Left Right Margin Mode (DECLRMM) determines whether left and right margins can be set.
Deprecated: use [ModeLeftRightMargin] instead.
LightDarkMode = DECMode.new(2031)
Light Dark Mode enables reporting the operating system's color scheme preference.
Deprecated: use [ModeLightDark] instead.
LineFeedNewLineMode = ANSIMode.new(20)
Line Feed/New Line Mode (LNM) determines whether the terminal interprets line feed as new line.
Deprecated: use [ModeLineFeedNewLine] instead.
LNM = ModeLineFeedNewLine
LocalEchoMode = SendReceiveMode
LS1R = "\e~"
LS1R (Locking Shift 1 Right) shifts G1 into GR character set.
LS2 = "\en"
LS2 (Locking Shift 2) shifts G2 into GL character set.
LS2R = "\e}"
LS2R (Locking Shift 2 Right) shifts G2 into GR character set.
LS3 = "\eo"
LS3 (Locking Shift 3) shifts G3 into GL character set.
LS3R = "\e|"
LS3R (Locking Shift 3 Right) shifts G3 into GR character set.
MagentaBackgroundColorAttr = AttrMagentaBackgroundColor
MagentaForegroundColorAttr = AttrMagentaForegroundColor
ModeAltScreen = DECMode.new(1047)
ModeAltScreenSaveCursor = DECMode.new(1049)
Alternate Screen Save Cursor Mode
ModeAutoWrap = DECMode.new(7)
ModeBackarrowKey = DECMode.new(67)
Backarrow Key Mode (DECBKM)
ModeBiDirectionalSupport = ANSIMode.new(8)
BiDirectional Support Mode (BDSM)
ModeBracketedPaste = DECMode.new(2004)
ModeCursorKeys = DECMode.new(1)
Cursor Keys Mode (DECCKM)
ModeFocusEvent = DECMode.new(1004)
ModeInBandResize = DECMode.new(2048)
ModeInsertReplace = ANSIMode.new(4)
Insert/Replace Mode (IRM)
ModeKeyboardAction = ANSIMode.new(2)
Keyboard Action Mode (KAM)
ModeLeftRightMargin = DECMode.new(69)
Left Right Margin Mode (DECLRMM)
ModeLightDark = DECMode.new(2031)
ModeLineFeedNewLine = ANSIMode.new(20)
Line Feed/New Line Mode (LNM)
ModeLocalEcho = ModeSendReceive
ModeMouseAnyEvent = DECMode.new(1003)
ModeMouseButtonEvent = DECMode.new(1002)
ModeMouseExtSgr = DECMode.new(1006)
ModeMouseExtSgrPixel = DECMode.new(1016)
SGR Pixel Extended Mouse Mode
ModeMouseExtUrxvt = DECMode.new(1015)
URXVT Extended Mouse Mode
ModeMouseExtUtf8 = DECMode.new(1005)
UTF-8 Extended Mouse Mode
ModeMouseHighlight = DECMode.new(1001)
ModeMouseNormal = DECMode.new(1000)
ModeMouseX10 = DECMode.new(9)
ModeNotRecognized = ModeSetting::ModeNotRecognized
ModeNumericKeypad = DECMode.new(66)
Numeric Keypad Mode (DECNKM)
ModeOrigin = DECMode.new(6)
ModePermanentlyReset = ModeSetting::ModePermanentlyReset
ModePermanentlySet = ModeSetting::ModePermanentlySet
ModeReset = ModeSetting::ModeReset
ModeSaveCursor = DECMode.new(1048)
ModeSendReceive = ANSIMode.new(12)
Send Receive Mode (SRM) / Local Echo
ModeSet = ModeSetting::ModeSet
ModeSynchronizedOutput = DECMode.new(2026)
ModeTextCursorEnable = DECMode.new(25)
Text Cursor Enable Mode (DECTCEM)
ModeUnicodeCore = DECMode.new(2027)
ModeWin32Input = DECMode.new(9001)
MouseAllMotionMode = DECMode.new(1003)
All Mouse Tracking mode.
Deprecated: use [ModeMouseAnyEvent] instead.
MouseBackward = MouseButton8
MouseButton1 = MouseButton.new(1_u8)
MouseButton10 = MouseButton.new(10_u8)
MouseButton11 = MouseButton.new(11_u8)
MouseButton2 = MouseButton.new(2_u8)
MouseButton3 = MouseButton.new(3_u8)
MouseButton4 = MouseButton.new(4_u8)
MouseButton5 = MouseButton.new(5_u8)
MouseButton6 = MouseButton.new(6_u8)
MouseButton7 = MouseButton.new(7_u8)
MouseButton8 = MouseButton.new(8_u8)
MouseButton9 = MouseButton.new(9_u8)
MouseCellMotionMode = DECMode.new(1002)
Cell Motion Mouse Tracking mode.
Deprecated: use [ModeMouseButtonEvent] instead.
MouseForward = MouseButton9
MouseHiliteMode = DECMode.new(1001)
VT Hilite Mouse Tracking mode.
Deprecated: use [ModeMouseHighlight] instead.
MouseMiddle = MouseButton2
MouseMode = DECMode.new(1000)
VT Mouse Tracking mode.
Deprecated: use [ModeMouseNormal] instead.
MouseNone = MouseButton.new(0_u8)
MouseRight = MouseButton3
MouseSgrExtMode = DECMode.new(1006)
Mouse SGR Extended mode.
Deprecated: use [ModeMouseExtSgr], [SetModeMouseExtSgr],
[ResetModeMouseExtSgr], and [RequestModeMouseExtSgr] instead.
MouseWheelDown = MouseButton5
MouseWheelLeft = MouseButton6
MouseWheelRight = MouseButton7
MouseWheelUp = MouseButton4
MoveCursorOrigin = CursorOrigin
MoveCursorOrigin is a sequence for moving the cursor to the upper left
corner of the display. This is equivalent to set_cursor_position(1, 1).
Deprecated: use [CursorHomePosition] instead.
NoBlinkAttr = AttrNoBlink
NoConcealAttr = AttrNoConceal
NoItalicAttr = AttrNoItalic
NoReverseAttr = AttrNoReverse
NormalIntensityAttr = AttrNormalIntensity
NormalMouseMode = DECMode.new(1000)
Normal Mouse Mode determines whether the mouse reports on button presses and releases.
Deprecated: use [ModeMouseNormal] instead.
NoStrikethroughAttr = AttrNoStrikethrough
NoUnderlineAttr = AttrNoUnderline
NUL = C0::NUL
Constants for easy access at module top level
NumericKeypadMode = DECMode.new(66)
Numeric Keypad Mode (DECNKM) determines whether the keypad sends application or numeric sequences.
Deprecated: use [ModeNumericKeypad] instead.
OriginMode = DECMode.new(6)
Origin Mode (DECOM) determines whether the cursor moves to home or margin position.
Deprecated: use [ModeOrigin] instead.
PAD = C1::PAD
Constants for easy access at module top level
PrimaryClipboard = 'p'.ord.to_u8
QueryModifyOtherKeys = "\e[?4m"
RapidBlinkAttr = AttrRapidBlink
RedBackgroundColorAttr = AttrRedBackgroundColor
RedForegroundColorAttr = AttrRedForegroundColor
ReportFocusMode = DECMode.new(1004)
Focus reporting mode.
Deprecated: use [SetModeFocusEvent], [ResetModeFocusEvent], and
[RequestModeFocusEvent] instead.
RequestAltScreenBuffer = "\e[?1049$p"
RequestAltScreenBufferMode = "\e[?1049$p"
RequestAltScreenMode = "\e[?1047$p"
RequestAltScreenSaveCursorMode = "\e[?1049$p"
RequestAnyEventMouseMode = "\e[?1003$p"
RequestAutoWrapMode = "\e[?7$p"
RequestBackarrowKeyMode = "\e[?67$p"
RequestBackgroundColor = "\e]11;?\a"
RequestBackgroundColor is a sequence that requests the current default
terminal background color.
See: https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-Operating-System-Commands
RequestBiDirectionalSupportMode = "\e[8$p"
RequestBracketedPaste = "\e[?2004$p"
RequestBracketedPasteMode = "\e[?2004$p"
RequestButtonEventMouseMode = "\e[?1002$p"
RequestCellSizeWinOp = 16
RequestCellSizeWinOp is a window operation that requests a report of
the size of the terminal cell size in pixels. The response is in the form:
CSI 6 ; height ; width t
Deprecated: Use constant number directly with [window_op].
RequestCursorColor = "\e]12;?\a"
RequestCursorColor is a sequence that requests the current terminal cursor
color.
See: https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-Operating-System-Commands
RequestCursorKeysMode = "\e[?1$p"
RequestCursorPosition = "\e[6n"
RequestCursorPosition is an escape sequence that requests the current cursor
position.
CSI 6 n
The terminal will report the cursor position as a CSI sequence in the
following format:
CSI Pl ; Pc R
Where Pl is the line number and Pc is the column number.
See: https://vt100.net/docs/vt510-rm/CPR.html
Deprecated: use [RequestCursorPositionReport] instead.
RequestCursorPositionReport = "\e[6n"
RequestCursorPositionReport is an escape sequence that requests the current
cursor position.
CSI 6 n
The terminal will report the cursor position as a CSI sequence in the
following format:
CSI Pl ; Pc R
Where Pl is the line number and Pc is the column number.
See: https://vt100.net/docs/vt510-rm/CPR.html
RequestCursorVisibility = "\e[?25$p"
RequestExtendedCursorPosition = "\e[?6n"
RequestExtendedCursorPosition (DECXCPR) is a sequence for requesting the
cursor position report including the current page number.
CSI ? 6 n
The terminal will report the cursor position as a CSI sequence in the
following format:
CSI ? Pl ; Pc ; Pp R
Where Pl is the line number, Pc is the column number, and Pp is the page
number.
See: https://vt100.net/docs/vt510-rm/DECXCPR.html
Deprecated: use [RequestExtendedCursorPositionReport] instead.
RequestExtendedCursorPositionReport = "\e[?6n"
RequestExtendedCursorPositionReport (DECXCPR) is a sequence for requesting
the cursor position report including the current page number.
CSI ? 6 n
The terminal will report the cursor position as a CSI sequence in the
following format:
CSI ? Pl ; Pc ; Pp R
Where Pl is the line number, Pc is the column number, and Pp is the page
number.
See: https://vt100.net/docs/vt510-rm/DECXCPR.html
RequestFocusEventMode = "\e[?1004$p"
RequestForegroundColor = "\e]10;?\a"
RequestForegroundColor is a sequence that requests the current default
terminal foreground color.
See: https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-Operating-System-Commands
RequestGraphemeClustering = "\e[?2027$p"
RequestGraphemeClusteringMode = "\e[?2027$p"
RequestHighlightMouseMode = "\e[?1001$p"
RequestInBandResizeMode = "\e[?2048$p"
RequestInsertReplaceMode = "\e[4$p"
RequestKeyboardActionMode = "\e[2$p"
RequestKittyKeyboard = "\e[?u"
RequestKittyKeyboard is a sequence to request the terminal Kitty keyboard
protocol enabled flags.
See: https://sw.kovidgoyal.net/kitty/keyboard-protocol/
RequestLeftRightMarginMode = "\e[?69$p"
RequestLightDarkMode = "\e[?2031$p"
RequestLightDarkReport = "\e[?996n"
RequestLightDarkReport is a control sequence that requests the terminal to
report its operating system light/dark color preference. Supported terminals
should respond with a [LightDarkReport] sequence as follows:
CSI ? 997 ; 1 n for dark mode
CSI ? 997 ; 2 n for light mode
See: https://contour-terminal.org/vt-extensions/color-palette-update-notifications/
RequestLineFeedNewLineMode = "\e[20$p"
RequestLocalEchoMode = "\e[12$p"
RequestModeAltScreen = "\e[?1047$p"
RequestModeAltScreenSaveCursor = "\e[?1049$p"
RequestModeAutoWrap = "\e[?7$p"
RequestModeBackarrowKey = "\e[?67$p"
RequestModeBiDirectionalSupport = "\e[8$p"
RequestModeBracketedPaste = "\e[?2004$p"
RequestModeCursorKeys = "\e[?1$p"
RequestModeFocusEvent = "\e[?1004$p"
RequestModeInBandResize = "\e[?2048$p"
RequestModeInsertReplace = "\e[4$p"
RequestModeKeyboardAction = "\e[2$p"
RequestModeLeftRightMargin = "\e[?69$p"
RequestModeLightDark = "\e[?2031$p"
RequestModeLineFeedNewLine = "\e[20$p"
RequestModeLocalEcho = "\e[12$p"
RequestModeMouseAnyEvent = "\e[?1003$p"
RequestModeMouseButtonEvent = "\e[?1002$p"
RequestModeMouseExtSgr = "\e[?1006$p"
RequestModeMouseExtSgrPixel = "\e[?1016$p"
RequestModeMouseExtUrxvt = "\e[?1015$p"
RequestModeMouseExtUtf8 = "\e[?1005$p"
RequestModeMouseHighlight = "\e[?1001$p"
RequestModeMouseNormal = "\e[?1000$p"
RequestModeMouseX10 = "\e[?9$p"
RequestModeNumericKeypad = "\e[?66$p"
RequestModeOrigin = "\e[?6$p"
RequestModeSaveCursor = "\e[?1048$p"
RequestModeSendReceive = "\e[12$p"
RequestModeSynchronizedOutput = "\e[?2026$p"
RequestModeTextCursorEnable = "\e[?25$p"
RequestModeUnicodeCore = "\e[?2027$p"
RequestModeWin32Input = "\e[?9001$p"
RequestModifyOtherKeys = "\e[?4m"
RequestModifyOtherKeys requests the modifyOtherKeys mode.
CSI ? 4 m
See: https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-Functions-using-CSI--ordered-by-the-final-character_s
See: https://invisible-island.net/xterm/manpage/xterm.html#VT100-Widget-Resources:modifyOtherKeys
Deprecated: use [QueryModifyOtherKeys] instead.
RequestMouse = "\e[?1000$p"
RequestMouseAllMotion = "\e[?1003$p"
RequestMouseCellMotion = "\e[?1002$p"
RequestMouseHilite = "\e[?1001$p"
RequestMouseSgrExt = "\e[?1006$p"
RequestNameVersion = "\e[>q"
RequestNameVersion (XTVERSION) is a control sequence that requests the
terminal's name and version. It responds with a DSR sequence identifying the
terminal.
CSI > 0 q
DCS > | text ST
See https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-PC-Style-Function-Keys
RequestNormalMouseMode = "\e[?1000$p"
RequestNumericKeypadMode = "\e[?66$p"
RequestOriginMode = "\e[?6$p"
RequestPrimaryClipboard = "\e]52;p;?\a"
RequestPrimaryClipboard is a sequence for requesting the primary clipboard.
This is equivalent to RequestClipboard(PrimaryClipboard).
RequestPrimaryDeviceAttributes = "\e[c"
RequestPrimaryDeviceAttributes is a control sequence that requests the
terminal's primary device attributes (DA1).
CSI c
See https://vt100.net/docs/vt510-rm/DA1.html
RequestReportFocus = "\e[?1004$p"
RequestSaveCursorMode = "\e[?1048$p"
RequestSecondaryDeviceAttributes = "\e[>c"
RequestSecondaryDeviceAttributes is a control sequence that requests the
terminal's secondary device attributes (DA2).
CSI > c
See https://vt100.net/docs/vt510-rm/DA2.html
RequestSendReceiveMode = "\e[12$p"
RequestSgrExtMouseMode = "\e[?1006$p"
RequestSgrPixelExtMouseMode = "\e[?1016$p"
RequestSyncdOutput = "\e[?2026$p"
RequestSynchronizedOutputMode = "\e[?2026$p"
RequestSystemClipboard = "\e]52;c;?\a"
RequestSystemClipboard is a sequence for requesting the system clipboard.
This is equivalent to RequestClipboard(SystemClipboard).
RequestTertiaryDeviceAttributes = "\e[=c"
RequestTertiaryDeviceAttributes is a control sequence that requests the
terminal's tertiary device attributes (DA3).
CSI = c
See https://vt100.net/docs/vt510-rm/DA3.html
RequestTextCursorEnableMode = "\e[?25$p"
RequestUnicodeCoreMode = "\e[?2027$p"
RequestUrxvtExtMouseMode = "\e[?1015$p"
RequestUtf8ExtMouseMode = "\e[?1005$p"
RequestWin32Input = "\e[?9001$p"
RequestWin32InputMode = "\e[?9001$p"
RequestWindowSizeWinOp = 14
RequestWindowSizeWinOp is a window operation that requests a report of
the size of the terminal window in pixels. The response is in the form:
CSI 4 ; height ; width t
Deprecated: Use constant number directly with [window_op].
RequestX10MouseMode = "\e[?9$p"
RequestXTVersion = RequestNameVersion
RequestXTVersion is a control sequence that requests the terminal's XTVERSION. It responds with a DSR sequence identifying the version.
CSI > Ps q
DCS > | text ST
See https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-PC-Style-Function-Keys
Deprecated: use [RequestNameVersion] instead.
ResetAltScreenBufferMode = "\e[?1049l"
ResetAltScreenMode = "\e[?1047l"
ResetAltScreenSaveCursorMode = "\e[?1049l"
ResetAnyEventMouseMode = "\e[?1003l"
ResetAttr = AttrReset
Deprecated: use Attr* constants instead.
ResetAutoWrapMode = "\e[?7l"
ResetBackarrowKeyMode = "\e[?67l"
ResetBackgroundColor = "\e]111\a"
ResetBackgroundColor is a sequence that resets the default terminal
background color.
See: https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-Operating-System-Commands
ResetBiDirectionalSupportMode = "\e[8l"
ResetBracketedPasteMode = "\e[?2004l"
ResetButtonEventMouseMode = "\e[?1002l"
ResetCursorColor = "\e]112\a"
ResetCursorColor is a sequence that resets the terminal cursor color.
See: https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-Operating-System-Commands
ResetCursorKeysMode = "\e[?1l"
ResetFocusEventMode = "\e[?1004l"
ResetForegroundColor = "\e]110\a"
ResetForegroundColor is a sequence that resets the default terminal
foreground color.
See: https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-Operating-System-Commands
ResetGraphemeClusteringMode = "\e[?2027l"
ResetHighlightMouseMode = "\e[?1001l"
ResetInBandResizeMode = "\e[?2048l"
ResetInitialState = "\ec"
ResetInitialState (RIS) resets the terminal to its initial state.
ESC c
See: https://vt100.net/docs/vt510-rm/RIS.html
ResetInsertReplaceMode = "\e[4l"
ResetKeyboardActionMode = "\e[2l"
ResetLeftRightMarginMode = "\e[?69l"
ResetLightDarkMode = "\e[?2031l"
ResetLineFeedNewLineMode = "\e[20l"
ResetLocalEchoMode = "\e[12l"
ResetModeAltScreen = "\e[?1047l"
ResetModeAltScreenSaveCursor = "\e[?1049l"
ResetModeAutoWrap = "\e[?7l"
ResetModeBackarrowKey = "\e[?67l"
ResetModeBiDirectionalSupport = "\e[8l"
ResetModeBracketedPaste = "\e[?2004l"
ResetModeCursorKeys = "\e[?1l"
ResetModeFocusEvent = "\e[?1004l"
ResetModeInBandResize = "\e[?2048l"
ResetModeInsertReplace = "\e[4l"
ResetModeKeyboardAction = "\e[2l"
ResetModeLeftRightMargin = "\e[?69l"
ResetModeLightDark = "\e[?2031l"
ResetModeLineFeedNewLine = "\e[20l"
ResetModeLocalEcho = "\e[12l"
ResetModeMouseAnyEvent = "\e[?1003l"
ResetModeMouseButtonEvent = "\e[?1002l"
ResetModeMouseExtSgr = "\e[?1006l"
ResetModeMouseExtSgrPixel = "\e[?1016l"
ResetModeMouseExtUrxvt = "\e[?1015l"
ResetModeMouseExtUtf8 = "\e[?1005l"
ResetModeMouseHighlight = "\e[?1001l"
ResetModeMouseNormal = "\e[?1000l"
ResetModeMouseX10 = "\e[?9l"
ResetModeNumericKeypad = "\e[?66l"
ResetModeOrigin = "\e[?6l"
ResetModeSaveCursor = "\e[?1048l"
ResetModeSendReceive = "\e[12l"
ResetModeSynchronizedOutput = "\e[?2026l"
ResetModeTextCursorEnable = "\e[?25l"
ResetModeUnicodeCore = "\e[?2027l"
ResetModeWin32Input = "\e[?9001l"
ResetModifyOtherKeys = "\e[>4m"
ResetNormalMouseMode = "\e[?1000l"
ResetNumericKeypadMode = "\e[?66l"
ResetOriginMode = "\e[?6l"
ResetPalette = "\e]R\a"
ResetPalette resets the color palette to the default values.
This sequence is specific to the Linux Console and may not work in other
terminal emulators.
See https://man7.org/linux/man-pages/man4/console_codes.4.html
ResetPrimaryClipboard = "\e]52;p;\a"
ResetPrimaryClipboard is a sequence for resetting the primary clipboard.
This is equivalent to ResetClipboard(PrimaryClipboard).
ResetProgressBar = "\e]9;4;0\a"
ResetProgressBar is a sequence that resets the progress bar to its default
state (hidden).
OSC 9 ; 4 ; 0 BEL
See: https://learn.microsoft.com/en-us/windows/terminal/tutorials/progress-bar-sequences
ResetSaveCursorMode = "\e[?1048l"
ResetSendReceiveMode = "\e[12l"
ResetSgrExtMouseMode = "\e[?1006l"
ResetSgrPixelExtMouseMode = "\e[?1016l"
ResetStyle = "\e[m"
ResetStyle is a SGR (Select Graphic Rendition) style sequence that resets
all attributes.
See: https://en.wikipedia.org/wiki/ANSI_escape_code#SGR_(Select_Graphic_Rendition)_parameters
ResetSynchronizedOutputMode = "\e[?2026l"
ResetSystemClipboard = "\e]52;c;\a"
ResetSystemClipboard is a sequence for resetting the system clipboard.
This is equivalent to ResetClipboard(SystemClipboard).
ResetTextCursorEnableMode = "\e[?25l"
ResetUnicodeCoreMode = "\e[?2027l"
ResetUrxvtExtMouseMode = "\e[?1015l"
ResetUtf8ExtMouseMode = "\e[?1005l"
ResetWin32InputMode = "\e[?9001l"
ResetX10MouseMode = "\e[?9l"
ResizeWindowWinOp = 4
ResizeWindowWinOp is a window operation that resizes the terminal
window.
Deprecated: Use constant number directly with [window_op].
RestoreCurrentCursorPosition = "\e[u"
RestoreCurrentCursorPosition (SCORC) is a sequence for restoring the current
cursor position for SCO console mode.
CSI u
This acts like [DECRC], except the page number where the cursor was saved is
not restored.
See: https://vt100.net/docs/vt510-rm/SCORC.html
RestoreCursor = "\e8"
RestoreCursor (DECRC) is an escape sequence that restores the cursor
position.
ESC 8
See: https://vt100.net/docs/vt510-rm/DECRC.html
RestoreCursorPosition = "\e[u"
RestoreCursorPosition (RCP or SCORC) is a sequence for restoring the cursor
position.
CSI u
This acts like Restore, except the cursor stays on the same page where the
cursor was saved.
See: https://vt100.net/docs/vt510-rm/SCORC.html
Deprecated: use [RestoreCurrentCursorPosition] instead.
ReverseAttr = AttrReverse
ReverseIndex = "\eM"
ReverseIndex (RI) is an escape sequence for moving the cursor up one line in
the same column. If the cursor is at the top margin, the screen scrolls
down.
This has the same effect as [RI].
RGBColorIntroducerAttr = AttrRGBColorIntroducer
SaveCurrentCursorPosition = "\e[s"
SaveCurrentCursorPosition (SCOSC) is a sequence for saving the current cursor
position for SCO console mode.
CSI s
This acts like [DECSC], except the page number where the cursor is located
is not saved.
See: https://vt100.net/docs/vt510-rm/SCOSC.html
SaveCursor = "\e7"
SaveCursor (DECSC) is an escape sequence that saves the current cursor
position.
ESC 7
See: https://vt100.net/docs/vt510-rm/DECSC.html
SaveCursorMode = DECMode.new(1048)
Save Cursor Mode saves the cursor position.
Deprecated: use [ModeSaveCursor] instead.
SaveCursorPosition = "\e[s"
SaveCursorPosition (SCP or SCOSC) is a sequence for saving the cursor
position.
CSI s
This acts like Save, except the page number where the cursor is located is
not saved.
See: https://vt100.net/docs/vt510-rm/SCOSC.html
Deprecated: use [SaveCurrentCursorPosition] instead.
SCORC = RestoreCurrentCursorPosition
SCOSC = SaveCurrentCursorPosition
SendReceiveMode = ANSIMode.new(12)
Send Receive Mode (SRM) or Local Echo Mode determines whether the terminal echoes characters.
Deprecated: use [ModeSendReceive] instead.
SetAltScreenBufferMode = "\e[?1049h"
SetAltScreenMode = "\e[?1047h"
SetAltScreenSaveCursorMode = "\e[?1049h"
SetAnyEventMouseMode = "\e[?1003h"
SetAutoWrapMode = "\e[?7h"
SetBackarrowKeyMode = "\e[?67h"
SetBiDirectionalSupportMode = "\e[8h"
SetBracketedPasteMode = "\e[?2004h"
SetButtonEventMouseMode = "\e[?1002h"
SetCursorKeysMode = "\e[?1h"
SetFocusEventMode = "\e[?1004h"
SetGraphemeClusteringMode = "\e[?2027h"
SetHighlightMouseMode = "\e[?1001h"
SetInBandResizeMode = "\e[?2048h"
SetIndeterminateProgressBar = "\e]9;4;3\a"
SetIndeterminateProgressBar is a sequence that sets the progress bar to the
indeterminate state.
OSC 9 ; 4 ; 3 BEL
See: https://learn.microsoft.com/en-us/windows/terminal/tutorials/progress-bar-sequences
SetInsertReplaceMode = "\e[4h"
SetKeyboardActionMode = "\e[2h"
SetLeftRightMarginMode = "\e[?69h"
SetLightDarkMode = "\e[?2031h"
SetLineFeedNewLineMode = "\e[20h"
SetLocalEchoMode = "\e[12h"
SetModeAltScreen = "\e[?1047h"
SetModeAltScreenSaveCursor = "\e[?1049h"
SetModeAutoWrap = "\e[?7h"
SetModeBackarrowKey = "\e[?67h"
SetModeBiDirectionalSupport = "\e[8h"
SetModeBracketedPaste = "\e[?2004h"
SetModeCursorKeys = "\e[?1h"
SetModeFocusEvent = "\e[?1004h"
SetModeInBandResize = "\e[?2048h"
SetModeInsertReplace = "\e[4h"
SetModeKeyboardAction = "\e[2h"
SetModeLeftRightMargin = "\e[?69h"
SetModeLightDark = "\e[?2031h"
SetModeLineFeedNewLine = "\e[20h"
SetModeLocalEcho = "\e[12h"
SetModeMouseAnyEvent = "\e[?1003h"
SetModeMouseButtonEvent = "\e[?1002h"
SetModeMouseExtSgr = "\e[?1006h"
SetModeMouseExtSgrPixel = "\e[?1016h"
SetModeMouseExtUrxvt = "\e[?1015h"
SetModeMouseExtUtf8 = "\e[?1005h"
SetModeMouseHighlight = "\e[?1001h"
SetModeMouseNormal = "\e[?1000h"
SetModeMouseX10 = "\e[?9h"
SetModeNumericKeypad = "\e[?66h"
SetModeSaveCursor = "\e[?1048h"
SetModeSendReceive = "\e[12h"
SetModeSynchronizedOutput = "\e[?2026h"
SetModeTextCursorEnable = "\e[?25h"
SetModeUnicodeCore = "\e[?2027h"
SetModeWin32Input = "\e[?9001h"
SetModifyOtherKeys1 = "\e[>4;1m"
Modify Other Keys (modifyOtherKeys) is an xterm feature that allows the
terminal to modify the behavior of certain keys to send different escape
sequences when pressed.
See: https://invisible-island.net/xterm/manpage/xterm.html#VT100-Widget-Resources:modifyOtherKeys
SetModifyOtherKeys2 = "\e[>4;2m"
SetNormalMouseMode = "\e[?1000h"
SetNumericKeypadMode = "\e[?66h"
SetSaveCursorMode = "\e[?1048h"
SetSendReceiveMode = "\e[12h"
SetSgrExtMouseMode = "\e[?1006h"
SetSgrPixelExtMouseMode = "\e[?1016h"
SetSynchronizedOutputMode = "\e[?2026h"
SetTabEvery8Columns = "\e[?5W"
SetTabEvery8Columns (DECST8C) sets the tab stops at every 8 columns.
CSI ? 5 W
See: https://vt100.net/docs/vt510-rm/DECST8C.html
SetTextCursorEnableMode = "\e[?25h"
SetUnicodeCoreMode = "\e[?2027h"
SetUrxvtExtMouseMode = "\e[?1015h"
SetUtf8ExtMouseMode = "\e[?1005h"
SetWin32InputMode = "\e[?9001h"
SetX10MouseMode = "\e[?9h"
SgrExtMouseMode = DECMode.new(1006)
SGR Extended Mouse Mode changes the mouse tracking encoding to use SGR parameters.
Deprecated: use [ModeMouseExtSgr] instead.
SgrPixelExtMouseMode = DECMode.new(1016)
SGR Pixel Extended Mouse Mode changes the mouse tracking encoding to use SGR parameters with pixel coordinates.
Deprecated: use [ModeMouseExtSgrPixel] instead.
ShowCursor = SetModeTextCursorEnable
SlowBlinkAttr = AttrBlink
SP = ASCII::SP
Constants for easy access at module top level
StrikethroughAttr = AttrStrikethrough
SyncdOutputMode = DECMode.new(2026)
Synchronized output mode.
Deprecated: use [ModeSynchronizedOutput], [SetModeSynchronizedOutput],
[ResetModeSynchronizedOutput], and [RequestModeSynchronizedOutput] instead.
SynchronizedOutputMode = DECMode.new(2026)
Synchronized Output Mode determines whether output is synchronized with the terminal.
Deprecated: use [ModeSynchronizedOutput] instead.
SystemClipboard = 'c'.ord.to_u8
TextCursorEnableMode = DECMode.new(25)
Text Cursor Enable Mode (DECTCEM) shows/hides the cursor.
Deprecated: use [ModeTextCursorEnable] instead.
UnderlineAttr = AttrUnderline
UnicodeCoreMode = DECMode.new(2027)
Unicode Core Mode determines whether the terminal uses Unicode grapheme clustering.
Deprecated: use [ModeUnicodeCore] instead.
UrxvtExtMouseMode = DECMode.new(1015)
URXVT Extended Mouse Mode changes the mouse tracking encoding to use an alternate encoding.
Deprecated: use [ModeMouseUrxvtExt] instead.
Utf8ExtMouseMode = DECMode.new(1005)
UTF-8 Extended Mouse Mode changes the mouse tracking encoding to use UTF-8 parameters.
Deprecated: use [ModeMouseExtUtf8] instead.
WcWidth = Method::WcWidth
WhiteBackgroundColorAttr = AttrWhiteBackgroundColor
WhiteForegroundColorAttr = AttrWhiteForegroundColor
Win32InputMode = DECMode.new(9001)
Win32Input determines whether input is processed by the Win32 console and Conpty.
Deprecated: use [ModeWin32Input] instead.
X10MouseMode = DECMode.new(9)
X10 Mouse Mode determines whether the mouse reports on button presses.
Deprecated: use [ModeMouseX10] instead.
XTVERSION = RequestNameVersion
YellowBackgroundColorAttr = AttrYellowBackgroundColor
YellowForegroundColorAttr = AttrYellowForegroundColor