[][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> Unpin for SyntectHighlighter<'a>

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

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

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

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

Blanket Implementations

impl<T> From<T> for T[src]

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

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

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> 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> Borrow<T> for T where
    T: ?Sized
[src]

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

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