Struct rushell_deps_linefeed::terminal::DefaultTerminal [−][src]
pub struct DefaultTerminal(_);
Default Terminal
interface
Implementations
impl DefaultTerminal
[src]
impl DefaultTerminal
[src]pub fn new() -> Result<DefaultTerminal>
[src]
pub fn new() -> Result<DefaultTerminal>
[src]Opens access to the terminal device associated with standard output.
pub fn stderr() -> Result<DefaultTerminal>
[src]
pub fn stderr() -> Result<DefaultTerminal>
[src]Opens access to the terminal device associated with standard error.
Trait Implementations
impl Terminal for DefaultTerminal
[src]
impl Terminal for DefaultTerminal
[src]type PrepareState = PrepareState
type PrepareState = PrepareState
Returned by prepare
; passed to restore
to restore state.
fn lock_read<'a>(&'a self) -> Box<dyn TerminalReader<Self> + 'a>
[src]
fn lock_read<'a>(&'a self) -> Box<dyn TerminalReader<Self> + 'a>
[src]Acquires a lock on terminal read operations and returns a value holding that lock and granting access to such operations. Read more
fn lock_write<'a>(&'a self) -> Box<dyn TerminalWriter<Self> + 'a>
[src]
fn lock_write<'a>(&'a self) -> Box<dyn TerminalWriter<Self> + 'a>
[src]Acquires a lock on terminal write operations and returns a value holding that lock and granting access to such operations. Read more
impl<'a> TerminalReader<DefaultTerminal> for TerminalReadGuard<'a>
[src]
impl<'a> TerminalReader<DefaultTerminal> for TerminalReadGuard<'a>
[src]fn prepare(
&mut self,
block_signals: bool,
report_signals: SignalSet
) -> Result<PrepareState>
[src]
fn prepare(
&mut self,
block_signals: bool,
report_signals: SignalSet
) -> Result<PrepareState>
[src]Prepares the terminal for line reading and editing operations. Read more
unsafe fn prepare_with_lock(
&mut self,
lock: &mut dyn TerminalWriter<DefaultTerminal>,
block_signals: bool,
report_signals: SignalSet
) -> Result<PrepareState>
[src]
unsafe fn prepare_with_lock(
&mut self,
lock: &mut dyn TerminalWriter<DefaultTerminal>,
block_signals: bool,
report_signals: SignalSet
) -> Result<PrepareState>
[src]Like prepare
, but called when the write lock is already held. Read more
fn restore(&mut self, state: PrepareState) -> Result<()>
[src]
fn restore(&mut self, state: PrepareState) -> Result<()>
[src]Restores the terminal state using the given state data.
unsafe fn restore_with_lock(
&mut self,
lock: &mut dyn TerminalWriter<DefaultTerminal>,
state: PrepareState
) -> Result<()>
[src]
unsafe fn restore_with_lock(
&mut self,
lock: &mut dyn TerminalWriter<DefaultTerminal>,
state: PrepareState
) -> Result<()>
[src]Like restore
, but called when the write lock is already held. Read more
impl<'a> TerminalWriter<DefaultTerminal> for TerminalWriteGuard<'a>
[src]
impl<'a> TerminalWriter<DefaultTerminal> for TerminalWriteGuard<'a>
[src]fn clear_screen(&mut self) -> Result<()>
[src]
fn clear_screen(&mut self) -> Result<()>
[src]Presents a clear terminal screen, with cursor at first row, first column. Read more
fn clear_to_screen_end(&mut self) -> Result<()>
[src]
fn clear_to_screen_end(&mut self) -> Result<()>
[src]Clears characters on the line occupied by the cursor, beginning with the cursor and ending at the end of the line. Also clears all characters on all lines after the cursor. Read more
fn move_right(&mut self, n: usize) -> Result<()>
[src]
fn move_right(&mut self, n: usize) -> Result<()>
[src]Moves the cursor right n
cells; n
may be zero.
fn move_to_first_column(&mut self) -> Result<()>
[src]
fn move_to_first_column(&mut self) -> Result<()>
[src]Moves the cursor to the first column of the current line
fn set_cursor_mode(&mut self, mode: CursorMode) -> Result<()>
[src]
fn set_cursor_mode(&mut self, mode: CursorMode) -> Result<()>
[src]Set the current cursor mode