Constructs an instance of Terminal representing the capabilities of the current terminal.
A destructor is present on this object, but not explicitly documented in the source.
A postblit is present on this object, but not explicitly documented in the source.
Options for stderrBehavior. Only applied if pipeThroughStdOut is set to true and its redirection actually is performed.
Sets or resets the terminal's text rendering options.
Clears the screen.
Clears the current line from the cursor onwards.
Changes the current color. See enum Color for the values and note colors can be bitwise-or combined with Bright.
Changes the current cursor.
It is not valid to call this if you constructed with minimalProcessing.
Flushes your updates to the terminal. It is important to call this when you are finished writing for now if you are using the version=with_eventloop
Gets a line, including user editing. Convenience method around the LineGetter class and RealTimeConsoleInput facilities - use them if you need more control.
hides the cursor
Outputs a hyperlink to my custom terminal (v0.0.7 or later) or to version TerminalDirectToEmulator. The way it works is a bit strange...
Returns true if the terminal advertised compatibility with the hyperlink function's implementation.
Sets or resets the terminal's text rendering options.
Moves the output cursor to the given position. (0, 0) is the upper left corner of the screen. The force parameter can be used to force an update, even if Terminal doesn't think it is necessary
Returns the terminal to normal output colors
Saves/restores cursor position to a stack.
Saves/restores cursor position to a stack.
Changes the terminal's title
Attempts to set color according to a 24 bit value (r, g, b, each >= 0 and < 256).
shows the cursor
Sets or resets the terminal's text rendering options.
Writes to the terminal at the current cursor position.
Writes to the terminal at the current cursor position.
The current cached x and y positions of the output cursor. 0 == leftmost column for x and topmost row for y.
The current height of the terminal (the number of rows)
The current width of the terminal (the number of columns)
Terminal is only valid to use on an actual console device or terminal handle. You should not attempt to construct a Terminal instance if this returns false. Real time input is similarly impossible if !stdinIsTerminal.
Set this before you create any Terminals if you want it to merge the C stdout and stderr streams into the GUI terminal window. It will always redirect stdout if this is set (you may want to check for existing redirections first before setting this, see Terminal.stdoutIsTerminal), and will redirect stderr as well if it is invalid or points to the parent terminal.
If pipeThroughStdOut is set, this decides what happens to stderr. See: StderrBehavior.
When using the embedded terminal emulator build, closing the terminal signals that the main thread should exit by sending it a hang up event. If the main thread responds, no problem. But if it doesn't, it can keep a thing running in the background with no visible window. This timeout gives it a chance to exit cleanly, but if it doesn't by the end of the time, the program will be forcibly closed automatically.
The cached object used by getline. You can set it yourself if you like.
Encapsulates the I/O capabilities of a terminal.
Warning: do not write out escape sequences to the terminal. This won't work on Windows and will confuse Terminal's internal state on Posix.