Struct ultron_syntaxes_themes::TextHighlighter
source · pub struct TextHighlighter { /* private fields */ }
Implementations§
source§impl TextHighlighter
impl TextHighlighter
pub fn with_theme(theme_name: &str) -> Self
pub fn set_syntax_token(&mut self, syntax_token: &str)
sourcepub fn select_theme(&mut self, theme_name: &str)
pub fn select_theme(&mut self, theme_name: &str)
set the theme name
pub fn highlight_line<'l>( &mut self, line: &'l str ) -> Result<Vec<(Style, &'l str)>, Error>
pub fn active_theme(&self) -> &'static Theme
pub fn gutter_background(&self) -> Option<Color>
pub fn gutter_foreground(&self) -> Option<Color>
pub fn theme_background(&self) -> Option<Color>
pub fn theme_foreground(&self) -> Option<Color>
pub fn selection_background(&self) -> Option<Color>
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for TextHighlighter
impl Send for TextHighlighter
impl Sync for TextHighlighter
impl Unpin for TextHighlighter
impl UnwindSafe for TextHighlighter
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