[][src]Struct unsegen_pager::SyntectHighlighter

pub struct SyntectHighlighter<'a> { /* fields omitted */ }

A Highlighter using the syntect library as a backend.

Methods

impl<'a> SyntectHighlighter<'a>[src]

pub fn new(syntax: &SyntaxDefinition, theme: &'a Theme) -> Self[src]

Create a SyntectHighlighter using the specified SyntaxDefinition (e.g., what programming language to assume) and the theme.

The theme reference has to be alive as long as the highlighter is active.

Trait Implementations

impl<'a> Highlighter for SyntectHighlighter<'a>[src]

Auto Trait Implementations

impl<'a> !Send for SyntectHighlighter<'a>

impl<'a> !Sync for SyntectHighlighter<'a>

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]