Raxol.Terminal.ScreenBuffer.EraseOperations (Raxol v2.0.1)

View Source

Handles all erase operations for the terminal screen buffer.

This module provides focused functionality for erasing content from the buffer, including line erasing, display erasing, and region clearing operations.

Summary

Functions

Clears a specific region of the buffer.

Erases the entire buffer.

Erases from the cursor to the end of the screen using the current cursor position.

Erases from cursor to end of display.

Erases from start to cursor position.

Erases part or all of the display based on the cursor position and type. Type can be :to_end, :to_beginning, or :all.

Erases part or all of the current line based on the cursor position and type. Type can be :to_end, :to_beginning, or :all.

Functions

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

Clears a specific region of the buffer.

erase_all(buffer)

Erases the entire buffer.

erase_from_cursor_to_end(buffer)

@spec erase_from_cursor_to_end(Raxol.Terminal.ScreenBuffer.t()) ::
  Raxol.Terminal.ScreenBuffer.t()

Erases from the cursor to the end of the screen using the current cursor position.

erase_from_cursor_to_end(buffer, x, y, top, bottom)

Erases from cursor to end of display.

erase_from_start_to_cursor(buffer, x, y, top, bottom)

Erases from start to cursor position.

erase_in_display(buffer, arg, type)

Erases part or all of the display based on the cursor position and type. Type can be :to_end, :to_beginning, or :all.

erase_in_line(buffer, arg, type)

Erases part or all of the current line based on the cursor position and type. Type can be :to_end, :to_beginning, or :all.