FontTypeMetric

class Draft.FontTypeMetric((object)arg1) → None

A class to retrieve font and text properties for annotations.

__init__( (object)arg1) -> None

property Ascent

The distance in pixels from the text baseline to the highest/upper grid coordinate used to place an outline point.

property BaselineOffset

Offset in pixels from the bottom of the image to the baseline used to write the text. Use this to align text from different point sizes and fonts.

property Descent

The distance in pixels from the baseline to the lowest grid coordinate used to place an outline point. Always a negative value.

property MaxHorizontalAdvance

Maximum horizontal advance in pixels.

property TextHeight

The height in pixels of the text written, this does not include any padding.

property TextWidth

The width in pixels of the text written, this does not include any padding.