classafTerminal::AnsiTerminal

sys::Obj
  afTerminal::AnsiTerminal

ANSI Terminal FWT Widget.

ansiPalette

Source

const AnsiPalette ansiPalette

The palette to use when printing indexed colours.

caretOffset

Source

Int caretOffset()

The carets current character offset.

caretPos

Source

Point caretPos()

The terminals current caret position.

clear

Source

This clear()

Convenience for:

terminal.print(AnsiBuf().clearScreen.toAnsi) 
cols

Source

Int cols()

A best guess as to the number of columns that are visible on the screen.

defStyle

Source

const RichTextStyle defStyle

Default style to use when the ANSI reset command is printed.

errStyle

Source

const RichTextStyle errStyle

Default style to use when printing errors.

make

Source

new make(|This? f := null)

Standard it-block ctor. Use to set the styles and palette:

terminal := AnsiTerminal {
    defStyle = RichTextStyle { ... }
    errStyle = RichTextStyle { ... }
    palette  = AnsiPalette.putty
}
print

Source

This print(Obj? str)

Prints the given object; usually a Str or an AnsiBuf.

printErr

Source

This printErr(Obj? str)

Prints the given object; usually a Str or an AnsiBuf.

richText

Source

RichText richText

The underlying RichText widget.

rows

Source

Int rows()

A best guess as to the number of rows that are visible on the screen.

text

Source

Str text()

The terminals current text.