Raxol.Terminal.Cursor.Manager (Raxol v0.4.0)
View SourceManages cursor state and operations.
Summary
Types
Cursor struct representing position, style, state, and saved values.
Functions
Adds the current cursor state to history.
Clamps a position to the screen bounds.
Gets the cursor's current position.
Gets the cursor's current state.
Gets the cursor's current style.
Gets whether the cursor is visible.
Moves the cursor down by the specified number of lines, clamped to the screen bounds.
Moves the cursor left by the specified number of columns, clamped to the screen bounds.
Moves the cursor right by the specified number of columns, clamped to the screen bounds.
Moves the cursor to a new position (no clamping, arity 2).
Moves the cursor to a new position (no clamping, arity 3 for compatibility).
Moves the cursor to a new position (clamped to the screen bounds).
Moves the cursor to a new position, clamped to the screen bounds.
Moves the cursor to the specified column, clamped to the screen bounds.
Moves the cursor to the beginning of the line.
Moves the cursor to the next tab stop.
Moves the cursor to the previous tab stop.
Moves the cursor up by the specified number of lines, clamped to the screen bounds.
Creates a new cursor with default values.
Restores the cursor state from history.
Restores the cursor's saved position (if any).
Restores the cursor's saved state.
Saves the cursor's current position (only position, not style or state).
Saves the cursor's current state.
Sets a custom cursor shape and dimensions.
Sets the cursor's state.
Sets the cursor's style.
Sets the cursor visibility.
Updates the cursor's blink state and returns the updated cursor and visibility.
Types
@type position() :: {non_neg_integer(), non_neg_integer()}
@type state() :: :visible | :hidden | :blinking
@type style() :: :block | :underline | :bar | :custom
@type t() :: %Raxol.Terminal.Cursor.Manager{ blink_rate: integer(), custom_dimensions: any() | nil, custom_shape: any() | nil, history: list(), history_index: integer(), history_limit: integer(), position: position(), saved_position: position() | nil, saved_state: state() | nil, saved_style: style() | nil, shape: {integer(), integer()}, state: state(), style: style() }
Cursor struct representing position, style, state, and saved values.
Functions
Adds the current cursor state to history.
Clamps a position to the screen bounds.
Gets the cursor's current position.
Gets the cursor's current state.
Gets the cursor's current style.
Gets whether the cursor is visible.
Moves the cursor down by the specified number of lines, clamped to the screen bounds.
Moves the cursor left by the specified number of columns, clamped to the screen bounds.
Moves the cursor right by the specified number of columns, clamped to the screen bounds.
Moves the cursor to a new position (no clamping, arity 2).
Moves the cursor to a new position (no clamping, arity 3 for compatibility).
Moves the cursor to a new position (clamped to the screen bounds).
Moves the cursor to a new position, clamped to the screen bounds.
Moves the cursor to the specified column, clamped to the screen bounds.
Moves the cursor to the beginning of the line.
Moves the cursor to the next tab stop.
Moves the cursor to the previous tab stop.
Moves the cursor up by the specified number of lines, clamped to the screen bounds.
Creates a new cursor with default values.
Restores the cursor state from history.
Restores the cursor's saved position (if any).
Restores the cursor's saved state.
Saves the cursor's current position (only position, not style or state).
Saves the cursor's current state.
Sets a custom cursor shape and dimensions.
Sets the cursor's state.
Sets the cursor's style.
Sets the cursor visibility.
Updates the cursor's blink state and returns the updated cursor and visibility.