Skip to main content

Module terminal

Module terminal 

Source
Expand description

Terminal mode guards.

RawModeGuard puts the terminal into raw mode on construction and restores cooked mode on drop. AltScreenGuard enters the alternate screen on construction and leaves it on drop. MouseCaptureGuard enables mouse-event reporting on construction and disables it on drop. Use in RAII order — drop in the reverse of construction for clean restoration.

Structs§

AltScreenGuard
RAII guard that keeps the terminal on the alternate screen.
MouseCaptureGuard
RAII guard that enables terminal mouse-event reporting.
RawModeGuard
RAII guard that keeps the terminal in raw mode.