TextMetrics

data class TextMetrics(val width: Float, val ascent: Float, val descent: Float, val lineGap: Float = 0.0f)

Resolved metrics for one piece of laid-out text.

All distances are in PDF points and all values are positive (ascent grows up from the baseline, descent grows down).

Constructors

Link copied to clipboard
constructor(width: Float, ascent: Float, descent: Float, lineGap: Float = 0.0f)

Properties

Link copied to clipboard

Distance from the baseline to the top of the tallest glyph.

Link copied to clipboard

Distance from the baseline to the bottom of the lowest glyph.

Link copied to clipboard
val lineGap: Float = 0.0f

Typographic line gap defined by the font; zero if the font omits it.

Link copied to clipboard

Total height occupied by one line of this run.

Link copied to clipboard

Advance width of the measured glyph run in PDF points.