JsonText

JsonText is an extended data type for the contents of a text editor.

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
Link copied to clipboard
val length: Int
Link copied to clipboard

Functions

Link copied to clipboard
fun clear(): Pair<Int, Int>?

Clears the text.

Link copied to clipboard
fun delete(fromIndex: Int, toIndex: Int): Pair<Int, Int>?

Deletes the text in the given range.

Link copied to clipboard
fun edit(fromIndex: Int, toIndex: Int, content: String, attributes: Map<String, String>? = null): Pair<Int, Int>?

Edits this JsonText with the given content and attributes.

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

Returns TextPosStructRange of the given index range.

Link copied to clipboard

Returns indexes of the given TextPosStructRange.

Link copied to clipboard
fun style(fromIndex: Int, toIndex: Int, attributes: Map<String, String>): Boolean

Styles this JsonText with the given attributes.

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