VtTerminal class final
Stateful VT terminal emulator instance.
Constructors
- VtTerminal({required int cols, required int rows, int maxScrollback = 10_000})
Properties
- activeScreen → GhosttyTerminalScreen
-
no setter
- cols → int
-
no setter
- cursorPendingWrap → bool
-
no setter
- cursorStyle → VtStyle
-
no setter
- cursorVisible → bool
-
no setter
- cursorX → int
-
no setter
- cursorY → int
-
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- kittyKeyboardFlags → int
-
no setter
- maxScrollback → int
-
no setter
- rows → int
-
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scrollbar → VtTerminalScrollbar
-
no setter
Methods
-
activeCell(
int x, int y) → VtGridRefSnapshot -
Resolves the active-screen cell at zero-based column
xand rowy. -
close(
) → void - Releases terminal resources.
-
createFormatter(
[VtFormatterTerminalOptions options = const VtFormatterTerminalOptions()]) → VtTerminalFormatter - Creates a formatter that reflects the terminal state on each call.
-
createRenderState(
) → VtRenderState - Creates a high-level render-state wrapper for this terminal.
-
getMode(
VtMode mode) → bool -
Returns whether
modeis currently set on this terminal. -
gridRef(
VtPoint point) → VtGridRefSnapshot - Resolves a cell position within the terminal grid.
-
historyCell(
int x, int y) → VtGridRefSnapshot -
Resolves the history cell at zero-based column
xand rowy. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
reset(
) → void - Performs a full terminal reset while preserving dimensions.
-
resize(
{required int cols, required int rows}) → void - Resizes the terminal to the given cell dimensions.
-
screenCell(
int x, int y) → VtGridRefSnapshot -
Resolves the screen cell at zero-based column
xand rowy. -
scrollBy(
int delta) → void -
Scrolls by
deltarows. Negative values move up. -
scrollToBottom(
) → void - Scrolls back to the active bottom of the terminal.
-
scrollToTop(
) → void - Scrolls to the top of the terminal scrollback.
-
scrollViewport(
VtTerminalScrollViewport behavior) → void - Scrolls the visible viewport within the terminal scrollback.
-
setMode(
VtMode mode, bool value) → void -
Sets
modetovalueon this terminal. -
toString(
) → String -
A string representation of this object.
inherited
-
viewportCell(
int x, int y) → VtGridRefSnapshot -
Resolves the viewport cell at zero-based column
xand rowy. -
write(
String text, {Encoding encoding = utf8}) → void - Writes text bytes into the terminal stream.
-
writeBytes(
List< int> bytes) → void - Writes raw VT-encoded bytes into the terminal stream.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited