Table of Contents

Class GlyphOrientationGeometry

Namespace
DocWright.Core.Rendering
Assembly
DocWright.Core.dll

The layout-space geometry of a GlyphOrientation.

public static class GlyphOrientationGeometry
Inheritance
GlyphOrientationGeometry
Inherited Members

Remarks

Both directions are unit vectors in layout space — x to the right, y down the page — because that is the space LayoutDocument is expressed in. A renderer working in a y-up device space negates the y component of each. This is public because Orientation is: an ILayoutRenderer implemented outside this library must be able to interpret a turned run without re-deriving the convention.

Methods

GetBaselineDirection(GlyphOrientation, out int, out int)

Gets the direction the baseline advances in, as a layout-space unit vector.

GetUpDirection(GlyphOrientation, out int, out int)

Gets the direction "up" points in for the glyphs themselves — the direction an ascender rises in — as a layout-space unit vector.

IsQuarterTurn(GlyphOrientation)

Gets whether the orientation is a quarter turn, so that the baseline runs vertically and the run's extent is measured down or up the page rather than across it.