class

Fancyline::Tty::Vt100

Inherits Fancyline::Tty / Reference / Object

Implements control codes for VT-100 compatible terminal emulators.

Constants

CLEAR_LINE = "\e[2K"
CURSOR_TO_START = "\r"
PREPARE_LINE = CURSOR_TO_START + CLEAR_LINE

Constructors

new(io : IO)
Source

Instance methods

clear_line

Clears the current line, no matter on which column the cursor is

Source
clear_screen

Clears the screen and moves the cursor to the top left

Source
columns

Terminal columns at program start.

Source
cursor_restore

Saves the cursor position, yields, and restores it afterwards.

Source
cursor_to_start

Moves the cursor to the start of the current line

Source
move_cursor(x, y)

Moves the terminal cursor around relative to its position

Source
prepare_line

Clears the current line and places the cursor at the beginning of it

Source
rows

Terminal rows at program start.

Source
winsize

Currently always returns nil when not compiled with x86_64 and darwin flags

Source