TextComponent

A gui element which renders a string in a single line

Constructors

Link copied to clipboard
constructor(string: StructuredText, width: Int, alignment: TextComponent.TextAlignment)
constructor(string: StructuredText, width: Int)
constructor(string: StructuredText)
constructor(string: String)

Types

Link copied to clipboard

Functions

Link copied to clipboard
open fun getHeight(): Int
Get the requested y size for this element.
Link copied to clipboard
open fun getWidth(): Int
Get the requested x size for this element.
Link copied to clipboard
open fun render(context: GuiImmediateContext)
Called by the parent renderer.
Link copied to clipboard
open fun split(text: StructuredText, width: Int): List<StructuredText>