Raxol.Terminal.Integration (Raxol Terminal v2.8.0)

Copy Markdown View Source

Coordinates terminal integration components and provides a unified interface for terminal operations.

This module manages the interaction between various terminal components:

  • State management
  • Buffer management
  • Rendering
  • Configuration

Summary

Functions

Clears the terminal (delegates to buffer manager and renderer).

Gets the current terminal configuration.

Gets the current cursor position.

Gets the current terminal dimensions.

Gets the current scroll position.

Gets the current terminal title.

Gets the total number of lines in the buffer.

Gets the current visible content.

Gets the number of visible lines.

Handles a user input event and returns the rendered state.

Initializes a new terminal integration state.

Moves the cursor to a specific position.

Resets the terminal configuration to default values.

Resizes the terminal.

Sets a specific configuration value.

Shows or hides the cursor.

Sets the terminal title.

Updates the configuration.

Renders the state after a write and returns it.

Functions

clear(state)

Clears the terminal (delegates to buffer manager and renderer).

get_config(state)

Gets the current terminal configuration.

get_cursor_position(state)

Gets the current cursor position.

get_dimensions(state)

Gets the current terminal dimensions.

get_scroll_position(state)

Gets the current scroll position.

get_title(state)

Gets the current terminal title.

get_total_lines(state)

Gets the total number of lines in the buffer.

get_visible_content(state)

Gets the current visible content.

get_visible_lines(state)

Gets the number of visible lines.

handle_input(state, input_event)

Handles a user input event and returns the rendered state.

init(opts \\ [])

Initializes a new terminal integration state.

move_cursor(state, x, y)

Moves the cursor to a specific position.

reset_config(state)

Resets the terminal configuration to default values.

resize(state, width, height)

Resizes the terminal.

scroll(state, direction, amount \\ 1)

Scrolls the terminal.

set_config_value(state, key, value)

Sets a specific configuration value.

set_cursor_visibility(state, visible)

Shows or hides the cursor.

set_title(state, title)

Sets the terminal title.

update_config(state, config)

Updates the configuration.

write(state, text)

Renders the state after a write and returns it.

text is not applied to the screen buffer.