object.baselineOffset

Type Number
Object TextObject
Library display.*
Revision 2017.3184
Keywords text, string, baselineOffset
See also display.newText()

Overview

The amount by which the baseline of the first line is offset from the center of the text object.

Note

The baseline is the imaginary horizontal line with which the base of each character in a line of text is aligned.

Example

local text = display.newText( "Baseline Offset sample", 0, 0, native.systemFont, 24 )

print( text.baselineOffset )
text:translate( 0, text.baselineOffset )