FontCache
See also
Constructors
Types
Functions
Link copied to clipboard
fun addText(font: Font, text: CharSequence, x: Float, y: Float, scaleX: Float = 1.0f, scaleY: Float = 1.0f, rotation: Angle = Angle.ZERO, color: Color = Color.WHITE, targetWidth: Float = 0.0f, align: HAlign = HAlign.LEFT, wrap: Boolean = false, truncate: String? = null)
Adds new glyphs of the specified string of text on top of any existing glyphs.
Link copied to clipboard
Sets the position of the text.
Link copied to clipboard
fun setText(layout: GlyphLayout, x: Float, y: Float, scaleX: Float = 1.0f, scaleY: Float = 1.0f, rotation: Angle = Angle.ZERO, color: Color = Color.WHITE)
Clears any existing glyphs of previous text and uses layout to compile the glyphs to cache.
fun setText(font: Font, text: CharSequence, x: Float, y: Float, scaleX: Float = 1.0f, scaleY: Float = 1.0f, rotation: Angle = Angle.ZERO, color: Color = Color.WHITE, targetWidth: Float = 0.0f, align: HAlign = HAlign.LEFT, wrap: Boolean = false, truncate: String? = null)
Clears any existing glyphs of previous text and adds the new glyphs of the specified string of text.