Skip to main content

Module RenderStateData

Module RenderStateData 

Source

Constants§

COLOR_BACKGROUND
Default/current background color (GhosttyColorRgb).
COLOR_CURSOR
Cursor color when explicitly set by terminal state (GhosttyColorRgb). Returns GHOSTTY_INVALID_VALUE if no explicit cursor color is set; use COLOR_CURSOR_HAS_VALUE to check first.
COLOR_CURSOR_HAS_VALUE
Whether an explicit cursor color is set (bool).
COLOR_FOREGROUND
Default/current foreground color (GhosttyColorRgb).
COLOR_PALETTE
The active 256-color palette (GhosttyColorRgb[256]).
COLS
Viewport width in cells (uint16_t).
CURSOR_BLINKING
Whether the cursor should blink based on terminal modes (bool).
CURSOR_PASSWORD_INPUT
Whether the cursor is at a password input field (bool).
CURSOR_VIEWPORT_HAS_VALUE
Whether the cursor is visible within the viewport (bool). If false, the cursor viewport position values are undefined.
CURSOR_VIEWPORT_WIDE_TAIL
Whether the cursor is on the tail of a wide character (bool). Only valid when CURSOR_VIEWPORT_HAS_VALUE is true.
CURSOR_VIEWPORT_X
Cursor viewport x position in cells (uint16_t). Only valid when CURSOR_VIEWPORT_HAS_VALUE is true.
CURSOR_VIEWPORT_Y
Cursor viewport y position in cells (uint16_t). Only valid when CURSOR_VIEWPORT_HAS_VALUE is true.
CURSOR_VISIBLE
Whether the cursor is visible based on terminal modes (bool).
CURSOR_VISUAL_STYLE
The visual style of the cursor (GhosttyRenderStateCursorVisualStyle).
DIRTY
Current dirty state (GhosttyRenderStateDirty).
INVALID
Invalid / sentinel value.
MAX_VALUE
Whether the cursor is on the tail of a wide character (bool). Only valid when CURSOR_VIEWPORT_HAS_VALUE is true.
ROWS
Viewport height in cells (uint16_t).
ROW_ITERATOR
Populate a pre-allocated GhosttyRenderStateRowIterator with row data from the render state (GhosttyRenderStateRowIterator). Row data is only valid as long as the underlying render state is not updated. It is unsafe to use row data after updating the render state.

Type Aliases§

Type
Queryable data kinds for ghostty_render_state_get().