RichTextBuffer
class RichTextBuffer
A buffer for safely mutating both text and attributes of a RichTextState within an edit block. This class provides attribute operations by delegating to RichStringScope and adds text operations like insert, delete, and replace.
Functions
Link copied to clipboard
fun editAll(ranges: <Error class: unknown class><IntRange>, editAction: <Error class: unknown class>.() -> Unit)
Applies a set of attribute mutations to all specified ranges using a DSL builder.
fun <T : Any> editAll(runs: <Error class: unknown class><<Error class: unknown class><T>>, editAction: <Error class: unknown class>.(<Error class: unknown class><T>) -> Unit)
Applies a set of attribute mutations to all specified runs using a DSL builder. The editAction receives each RichRun to allow conditional logic based on existing attributes.
Link copied to clipboard
fun editAttributes(range: IntRange = 0 until textLength, editAction: <Error class: unknown class>.() -> Unit)
Applies a set of attribute mutations to the specified range using a DSL builder.
Link copied to clipboard
fun RichTextBuffer.editAttributes(selection: TextRange, editAction: <Error class: unknown class>.() -> Unit)
Link copied to clipboard
Link copied to clipboard
fun <T> removeParagraphAttribute(key: <Error class: unknown class><T>, range: IntRange = 0 until textLength)
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard