Table of Contents

Method GetGlyphRunWorldBounds

Namespace
PaintDotNet.Direct2D1
Assembly
PaintDotNet.Windows.dll

GetGlyphRunWorldBounds(Point2Float, in GlyphRun, TextMeasuringMode)

Gets the world-space bounds in DIPs of the glyph run using the device context DPI.

RectFloat GetGlyphRunWorldBounds(Point2Float baselineOrigin, in GlyphRun glyphRun, TextMeasuringMode measuringMode = TextMeasuringMode.Natural)

Parameters

baselineOrigin Point2Float

The origin of the baseline for the glyph run.

glyphRun GlyphRun

The glyph run to measure.

measuringMode TextMeasuringMode

The measuring mode that indicates how glyph metrics are used to measure text when it is formatted.

Returns

RectFloat

The bounds of the glyph run in DIPs and in world space.