Terminal

Trait Terminal 

Source
pub trait Terminal {
Show 16 methods // Required methods fn is_tty_input(&self) -> bool; fn is_tty_output(&self) -> bool; fn start_input(&mut self) -> Result<()>; fn supported_styles(&self) -> Style; fn max_colors(&self) -> (usize, usize, bool); fn get_size(&self) -> Result<WinSize>; fn get_style(&self) -> Style; fn get_fg(&self) -> Color; fn get_bg(&self) -> Color; fn set_style(&mut self, style: Style, fg: Color, bg: Color) -> Result<()>; fn set_cursor(&mut self, coords: Coords) -> Result<()>; fn cursor_visible(&mut self, visible: bool) -> Result<()>; fn write(&mut self, text: &str) -> Result<()>; fn clear(&mut self) -> Result<()>; fn flush_output(&mut self) -> Result<()>; fn log(&mut self, text: &str);
}

Required Methods§

Source

fn is_tty_input(&self) -> bool

Source

fn is_tty_output(&self) -> bool

Source

fn start_input(&mut self) -> Result<()>

Source

fn supported_styles(&self) -> Style

Source

fn max_colors(&self) -> (usize, usize, bool)

Source

fn get_size(&self) -> Result<WinSize>

Source

fn get_style(&self) -> Style

Source

fn get_fg(&self) -> Color

Source

fn get_bg(&self) -> Color

Source

fn set_style(&mut self, style: Style, fg: Color, bg: Color) -> Result<()>

Source

fn set_cursor(&mut self, coords: Coords) -> Result<()>

Source

fn cursor_visible(&mut self, visible: bool) -> Result<()>

Source

fn write(&mut self, text: &str) -> Result<()>

Source

fn clear(&mut self) -> Result<()>

Source

fn flush_output(&mut self) -> Result<()>

Source

fn log(&mut self, text: &str)

Implementors§