cursor

package
Version: v0.0.0-...-d3fb95e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 4, 2018 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package cursor provides ANSI Escape sequences introduced in VT-100 terminals for cursor and screen manipulation operations.

Index

Constants

View Source
const Esc = "\x1b"

Esc is the ANSI escape code prefix

Variables

This section is empty.

Functions

func ClearEntireLine

func ClearEntireLine() string

ClearEntireLine returns ANSI escape sequence to clear current line.

func ClearEntireScreen

func ClearEntireScreen() string

ClearEntireScreen returns ANSI escape sequence to clear the screen.

func ClearLineLeft

func ClearLineLeft() string

ClearLineLeft returns ANSI escape sequence to clear line from left of the cursor.

func ClearLineRight

func ClearLineRight() string

ClearLineRight returns ANSI escape sequence to clear line from right of the cursor.

func ClearScreenDown

func ClearScreenDown() string

ClearScreenDown returns ANSI escape sequence to clear screen below. the cursor.

func ClearScreenUp

func ClearScreenUp() string

ClearScreenUp returns ANSI escape sequence to clear screen above. the cursor.

func Hide

func Hide() string

Hide returns ANSI escape sequence to hide the cursor

func MoveDown

func MoveDown(n int) string

MoveDown returns ANSI escape sequence to move cursor down n lines.

func MoveLeft

func MoveLeft(n int) string

MoveLeft returns ANSI escape sequence to move cursor left n columns.

func MoveNextLine

func MoveNextLine() string

MoveNextLine returns ANSI escape sequence to move cursor to next line.

func MoveRight

func MoveRight(n int) string

MoveRight returns ANSI escape sequence to move cursor right n columns.

func MoveTo

func MoveTo(line, col int) string

MoveTo returns ANSI escape sequence to move cursor to specified position on screen.

func MoveToHorizontal

func MoveToHorizontal(col int) string

MoveToHorizontal returns ANSI escape sequence to move cursor the the specified position on the current line.

func MoveUp

func MoveUp(n int) string

MoveUp returns ANSI escape sequence to move cursor up n lines.

func MoveUpperLeft

func MoveUpperLeft(n int) string

MoveUpperLeft returns ANSI escape sequence to move cursor to upper left corner of screen.

func RestoreAttributes

func RestoreAttributes() string

RestoreAttributes returns ANSI escape sequence to restore saved position and attributes of the cursor.

func SaveAttributes

func SaveAttributes() string

SaveAttributes returns ANSI escape sequence to save current position and attributes of the cursor.

func Show

func Show() string

Show returns ANSI escape sequence to show the cursor

Types

This section is empty.

Source Files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL