Expand description
An abstraction over a terminal device
Re-exports§
pub use self::unix::UnixTerminal;pub use self::unix::UnixTerminalWaker as TerminalWaker;
Modules§
Structs§
- Screen
Size - Represents the size of the terminal screen. The number of rows and columns of character cells are expressed. Some implementations populate the size of those cells in pixels.
Enums§
Traits§
- Terminal
Terminalabstracts over some basic terminal capabilities. If theset_raw_modeorset_cooked_modefunctions are used in any combination, the implementation is required to restore the terminal mode that was in effect when it was created.
Functions§
- new_
terminal - Construct a new instance of Terminal.
The terminal will have a renderer that is influenced by the configuration
in the provided
Capabilitiesinstance. The terminal will explicitly open/dev/ttyon Unix systems andCONIN$andCONOUT$on Windows systems, so that it should yield a functioning console with minimal headaches. If you have a more advanced use case you will want to look to the constructors forUnixTerminalandWindowsTerminaland call whichever one is most suitable for your needs.
Type Aliases§
- System
Terminal SystemTerminalis a concrete implementation ofTerminal. Ideally you wouldn’t referenceSystemTerminalin consuming code. This type is exposed for convenience if you are doing something unusual and want easier access to the constructors.