Expand description
Managing raw mode.
Raw mode is a particular state a TTY can have. It signifies that:
- No line buffering (the input is given byte-by-byte).
- The input is not written out, instead it has to be done manually by the programmer.
- The output is not canonicalized (for example,
\n
means “go one line down”, not “line break”).
It is essential to design terminal programs.
§Example
use sl_console::*;
use std::io::Write;
let mut conout = conout().into_raw_mode().unwrap();
write!(conout, "Hey there.").unwrap();
Structs§
- A terminal restorer, which keeps the previous state of the terminal, and restores it, when dropped.
Traits§
- Types which can be converted into “raw mode”.