Struct broot::syntactic::SyntacticView
source · pub struct SyntacticView {
pub path: PathBuf,
pub pattern: InputPattern,
/* private fields */
}
Fields§
§path: PathBuf
§pattern: InputPattern
Implementations§
source§impl SyntacticView
impl SyntacticView
sourcepub fn new(
path: &Path,
pattern: InputPattern,
dam: &mut Dam,
con: &AppContext,
no_style: bool
) -> Result<Option<Self>, ProgramError>
pub fn new( path: &Path, pattern: InputPattern, dam: &mut Dam, con: &AppContext, no_style: bool ) -> Result<Option<Self>, ProgramError>
Return a prepared text view with syntax coloring if possible. May return Ok(None) only when a pattern is given and there was an event before the end of filtering.
sourcepub fn line_counts(&self) -> (usize, usize)
pub fn line_counts(&self) -> (usize, usize)
Give the count of lines which can be seen when scrolling, total count including filtered ones
pub fn get_selected_line(&self) -> Option<String>
pub fn get_selected_line_number(&self) -> Option<LineNumber>
pub fn unselect(&mut self)
pub fn try_select_y(&mut self, y: u16) -> bool
pub fn select_first(&mut self)
pub fn select_last(&mut self)
pub fn try_select_line_number(&mut self, number: LineNumber) -> bool
pub fn move_selection(&mut self, dy: i32, cycle: bool)
pub fn try_scroll(&mut self, cmd: ScrollCommand) -> bool
pub fn display( &mut self, w: &mut W, _screen: Screen, panel_skin: &PanelSkin, area: &Area, con: &AppContext ) -> Result<(), ProgramError>
pub fn display_info( &mut self, w: &mut W, _screen: Screen, panel_skin: &PanelSkin, area: &Area ) -> Result<(), ProgramError>
Auto Trait Implementations§
impl RefUnwindSafe for SyntacticView
impl Send for SyntacticView
impl Sync for SyntacticView
impl Unpin for SyntacticView
impl UnwindSafe for SyntacticView
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more