use-font-metrics Examples
-
Quickstart - measure string
width and display the result (source)
-
Horizontal Metrics - measure
string width and chop off
advanceWidth (source)
-
Vertical Metrics - display
font
baseline and xHeight (source)
-
Fit Text Height - Resize the
browser window to see text
capHeight sizing to DOM element
height (source)