module AnsiEscapes::Cursor
Defined in:
ansi-escapes.crConstant Summary
-
GET_POSITION =
"#{ESC}6n" -
Get cursor position.
-
HIDE =
"#{ESC}?25l" -
Hide cursor.
-
LEFT =
"#{ESC}100D" -
Move cursor to the left side.
-
NEXT_LINE =
"#{ESC}E" -
Move cursor to the next line.
-
PREVIOUS_LINE =
"#{ESC}F" -
Move cursor to the previous line.
-
RESTORE_POSITION =
"#{ESC}u" -
Restore saved cursor position.
-
SAVE_POSITION =
"#{ESC}s" -
Save cursor position.
-
SHOW =
"#{ESC}?25h" -
Show cursor.
Class Method Summary
-
.backward(count = 1)
Move cursor backward a specific amount of columns.
-
.down(count = 1)
Move cursor down a specific amount of rows.
-
.forward(count = 1)
Move cursor forward a specific amount of columns.
-
.home
Move the cursor to the home position at the upper-left corner of the screen (
x0y0). -
.move(x : Int32, y : Int32)
Set the position of the cursor relative to its current position.
-
.to(x : Int32, y : Int32)
Absolutely set cursor column and row.
-
.to(x : Int32)
Absolutely set cursor column.
-
.up(count = 1)
Move cursor up a specific amount of rows.
Class Method Detail
def self.home
#
Move the cursor to the home position at the upper-left corner of the screen (x0 y0).
def self.move(x : Int32, y : Int32)
#
Set the position of the cursor relative to its current position.