HighlightedLine

class HighlightedLine(val lineNumber: Int, val text: String, val spans: List<HighlightSpan>)

One line of source text together with its theme-independent highlight spans.

Span offsets are UTF-16 offsets into text. spans is in application order: spans may overlap, and a later span merges over an earlier one with Compose addStyle semantics, so the order must not be changed. Rendering through toAnnotatedString never reads SyntaxTheme.background.

Constructors

Link copied to clipboard
constructor(lineNumber: Int, text: String, spans: List<HighlightSpan>)

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard

Resolves this line's spans against theme and returns the styled AnnotatedString.

Link copied to clipboard
open override fun toString(): String