draw

fun draw(batch: Batch, text: CharSequence, x: Float, y: Float, rotation: Angle = Angle.ZERO, color: Color = Color.WHITE, targetWidth: Float = 0.0f, align: HAlign = HAlign.LEFT, wrap: Boolean = false)

Draws a string of text.

See also

Parameters

batch

the batch to draw the text with

text

the string of text to draw

x

the x position to draw the text

y

the y position to draw the text

rotation

the rotation of the text to draw

color

the color of the text to draw

targetWidth

the width of the area the text will be drawn, for wrapping or truncation

align

the horizontal alignment of the text, see HAlign

wrap

if true, the text will be wrapped within the targetWidth