Skip to content

comfit.HighlightResult

Owned lines and tokens, independent of document updates or disposal.

Functions:

  • render_ansi – Render the snapshot without parsing.
  • render_html – Render without parsing. The config can change line emphasis, but not bracket depths.

Attributes:

comfit.HighlightResult.lines

Python
lines: list[Line]

comfit.HighlightResult.render_ansi

Python
render_ansi(theme: str) -> str

Render the snapshot without parsing.

comfit.HighlightResult.render_html

Python
render_html(theme: str, config: RenderHtmlConfig | None = None) -> str

Render without parsing. The config can change line emphasis, but not bracket depths.