Table of Contents

Method GetDeviceMetrics

Namespace
DocWright.Fonts
Assembly
DocWright.Fonts.dll

GetDeviceMetrics(int)

Gets the face's metrics in whole device pixels at a size, as the Windows text engine (GDI) reports them: the ascent and descent from the face's VDMX record for the size where it has one, and from its Windows ascent and descent rounded otherwise.

public DeviceFontMetrics GetDeviceMetrics(int pixelsPerEm)

Parameters

pixelsPerEm int

The size in pixels per em, 1 to MaxDevicePixelsPerEm: a font of p points on a device of d dots per inch is round(p * d / 72).

Returns

DeviceFontMetrics

The metrics.

Exceptions

ArgumentOutOfRangeException

pixelsPerEm is outside 1 to MaxDevicePixelsPerEm.