Package-level declarations

Functions

Link copied to clipboard
fun rememberSyntaxHighlightedString(state: TextFieldState, language: Language, theme: SyntaxTheme = LocalSyntaxTheme.current): State<AnnotatedString>

Returns a State holding the syntax-highlighted form of state.text. The returned state recomputes incrementally as the user edits via the underlying IncrementalHighlighter.

Link copied to clipboard
fun SyntaxHighlightedTextField(state: TextFieldState, language: Language, modifier: Modifier = Modifier, theme: SyntaxTheme = LocalSyntaxTheme.current, textStyle: TextStyle = LocalTextStyle.current.copy(fontFamily = FontFamily.Monospace), enabled: Boolean = true, readOnly: Boolean = false, cursorBrush: Brush = SolidColor(MaterialTheme.colorScheme.primary), lineLimits: TextFieldLineLimits = TextFieldLineLimits.MultiLine(), scrollState: ScrollState = rememberScrollState(), keyboardOptions: KeyboardOptions = KeyboardOptions.Default, onKeyboardAction: KeyboardActionHandler? = null, interactionSource: MutableInteractionSource? = null)

Renders an editable, syntax-highlighted code surface backed by IncrementalHighlighter.