Trait move_bytecode_viewer::tui::tui_interface::TUIInterface
source · pub trait TUIInterface {
const LEFT_TITLE: &'static str;
const RIGHT_TITLE: &'static str;
// Required methods
fn on_redraw(&mut self, line_number: u16, column_number: u16) -> TUIOutput<'_>;
fn bound_line(&self, line_number: u16) -> u16;
fn bound_column(&self, line_number: u16, column_number: u16) -> u16;
}
Required Associated Constants§
sourceconst LEFT_TITLE: &'static str
const LEFT_TITLE: &'static str
The title to be used for the left screen
sourceconst RIGHT_TITLE: &'static str
const RIGHT_TITLE: &'static str
The title to be used for the right screen
Required Methods§
sourcefn on_redraw(&mut self, line_number: u16, column_number: u16) -> TUIOutput<'_>
fn on_redraw(&mut self, line_number: u16, column_number: u16) -> TUIOutput<'_>
Function called on each redraw. The TUIOutput
contains that updated data to display on
each pane.
sourcefn bound_line(&self, line_number: u16) -> u16
fn bound_line(&self, line_number: u16) -> u16
Bounds the line number so that it does not run past the text.
sourcefn bound_column(&self, line_number: u16, column_number: u16) -> u16
fn bound_column(&self, line_number: u16, column_number: u16) -> u16
Bounds the column number (w.r.t. the current line_number
) so that the cursor does not
overrun the line.