Skip to main content

Module highlight

Module highlight 

Source
Expand description

Whole-file syntax highlighting sliced into per-line styled ranges. Highlighting whole files (not hunks) keeps stateful constructs like multi-line strings correct across hunk boundaries.

Structs§

Highlighter
StyledRange
Foreground color + style for a byte range of one line.

Enums§

SyntaxTheme
Syntax-highlight palette, paired with a UI theme so foreground colors stay legible against the diff backgrounds (a dark UI needs dark-theme syntax, a light UI light-theme syntax).