Skip to main content

setup_terminal

Function setup_terminal 

Source
pub fn setup_terminal() -> Result<(), Box<dyn Error + Send + Sync>>
Expand description

What: Enter raw mode and switch to the alternate screen with mouse capture enabled.

Inputs:

  • None

Output:

  • Ok(()) if the terminal was prepared; Err on I/O or terminal backend failure.

ยงErrors

Returns an error if raw mode cannot be enabled or the alternate screen cannot be entered.