Raxol.Terminal.ScreenUpdater (Raxol Terminal v2.6.0)

Copy Markdown View Source

Handles screen update operations for the terminal.

This module manages updating the terminal screen content, including batched updates and differential rendering.

Summary

Functions

Performs a batched screen update for efficiency.

Clears the screen.

Refreshes the entire screen.

Scrolls the screen content.

Updates a specific region of the screen.

Updates the screen with new buffer content.

Functions

batch_update_screen(buffers, options \\ %{})

@spec batch_update_screen([Raxol.Terminal.ScreenBuffer.t()], map()) ::
  :ok | {:error, term()}

Performs a batched screen update for efficiency.

clear_screen()

@spec clear_screen() :: :ok

Clears the screen.

refresh_screen(buffer)

@spec refresh_screen(Raxol.Terminal.ScreenBuffer.t()) :: :ok | {:error, term()}

Refreshes the entire screen.

scroll_screen(lines)

@spec scroll_screen(integer()) :: :ok

Scrolls the screen content.

update_region(buffer, x, y, width, height)

@spec update_region(
  Raxol.Terminal.ScreenBuffer.t(),
  integer(),
  integer(),
  integer(),
  integer()
) :: :ok | {:error, term()}

Updates a specific region of the screen.

update_screen(buffer, options \\ %{})

@spec update_screen(Raxol.Terminal.ScreenBuffer.t(), map()) :: :ok | {:error, term()}

Updates the screen with new buffer content.