Trait Highlighter
pub trait Highlighter {
// Required method
fn spans(&self, line: &str, carry: u64) -> LineSpans;
}Expand description
A pluggable, per-line source tokenizer. The CodeEditor owns rendering,
caret, and selection; a Highlighter owns only the language lexing —
mapping a line of source to coloured Spans. SyntaxHighlighter
covers every language with a grammar; hand it (or a wrapper that adds
app-specific spans) to CodeEditor::with_highlighter.