FontMetrics

data class FontMetrics(var size: Double = 0.0, var top: Double = 0.0, var ascent: Double = 0.0, var baseline: Double = 0.0, var descent: Double = 0.0, var bottom: Double = 0.0, var lineGap: Double = 0.0, var maxWidth: Double = 0.0, var unitsPerEm: Double = 0.0)
                         ... [top] (Positive)

      ##                 --- [ascent] (Positive)

    ######       ##
   ##   ##
  ########       ##
 ##     ##       ##
##      ##       ##      ---- [baseline] (Always 0)
            ##  ##
             ####        ---- [descent] (Negative)

                         ---- [bottom] (Negative)

.......................  ---- [bottom] - [lineGap] (Negative)

Constructors

Link copied to clipboard
constructor(size: Double = 0.0, top: Double = 0.0, ascent: Double = 0.0, baseline: Double = 0.0, descent: Double = 0.0, bottom: Double = 0.0, lineGap: Double = 0.0, maxWidth: Double = 0.0, unitsPerEm: Double = 0.0)

Properties

Link copied to clipboard

ascent part of E

Link copied to clipboard

base of 'E'

Link copied to clipboard

lowest part without the gap

Link copied to clipboard

lower part of 'j'

Link copied to clipboard

extra height, line-gap

Link copied to clipboard

Total size of a line including from top to bottom + lineGap

Link copied to clipboard
Link copied to clipboard

maximum number of width

Link copied to clipboard

Bottom-most part of the glyphs (without the lineGap between lines)

Link copied to clipboard

Top-most part of the glyphs

Link copied to clipboard

size of the font metric, typically top - bottom

Link copied to clipboard
var top: Double

maximum top for any character like É

Link copied to clipboard

units per EM (historically 'M' width)

Functions

Link copied to clipboard
fun clear()
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open override fun toString(): String