Raxol.Terminal.TerminalState.Manager (Raxol v0.5.0)
View SourceManages terminal state operations for the terminal emulator. This module handles the state stack, saved states, and state transitions.
Summary
Functions
Clears all saved states.
Gets the current state.
Gets the number of saved states.
Gets the current state stack.
Checks if there are saved states.
Creates a new terminal state.
Restores the last saved state.
Saves the current state.
Updates the current state.
Updates the state stack.
Functions
@spec clear_saved_states(Raxol.Terminal.Emulator.t()) :: Raxol.Terminal.Emulator.t()
Clears all saved states.
@spec get_current_state(Raxol.Terminal.Emulator.t()) :: map()
Gets the current state.
@spec get_saved_states_count(Raxol.Terminal.Emulator.t()) :: non_neg_integer()
Gets the number of saved states.
@spec get_state_stack(Raxol.Terminal.Emulator.t()) :: Raxol.Terminal.ANSI.TerminalState.t()
Gets the current state stack.
@spec has_saved_states?(Raxol.Terminal.Emulator.t()) :: boolean()
Checks if there are saved states.
@spec new() :: Raxol.Terminal.ANSI.TerminalState.t()
Creates a new terminal state.
@spec restore_state(Raxol.Terminal.Emulator.t()) :: Raxol.Terminal.Emulator.t()
Restores the last saved state.
@spec save_state(Raxol.Terminal.Emulator.t()) :: Raxol.Terminal.Emulator.t()
Saves the current state.
@spec update_current_state(Raxol.Terminal.Emulator.t(), map()) :: Raxol.Terminal.Emulator.t()
Updates the current state.
@spec update_state_stack( Raxol.Terminal.Emulator.t(), Raxol.Terminal.ANSI.TerminalState.t() ) :: Raxol.Terminal.Emulator.t()
Updates the state stack.