From Xojo Documentation

Revision as of 15:31, 7 October 2019 by PLefebvre (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Read-Only Property (As Double )
DoubleValue = aGraphics.FontAscent

New in 2019r2

Supported for all project types and targets.

Returns the ascent of a line of text drawn with the current font.


FontAscent is the height of the tallest font letter above the font baseline.

Sample Code

The following example gets the font ascent of the text that was drawn with DrawText.

g.DrawingColor = &cff0000
g.IsItalic = True
g.DrawText("Hello world", 10, 10)