Struct TextMetrics
- Namespace
- PaintDotNet.DirectWrite
- Assembly
- PaintDotNet.Windows.dll
Contains the metrics associated with text after layout. All coordinates are in device independent pixels (DIPs).
public readonly struct TextMetrics : IEquatable<TextMetrics>
- Implements
- Inherited Members
Properties
- Height
The height of the formatted text. The height of an empty string is set to the same value as that of the default font.
- HeightIncludingTrailingWhitespace
The height of the formatted text taking into account the trailing whitespace at the end of each line. This is pertinent for vertical text.
- HeightMax
Gets the maximum value of Height and HeightIncludingTrailingWhitespace.
- LayoutHeight
Initial height given to the layout. Depending on the length of the text, it may be larger or smaller than the text content height.
- LayoutWidth
The initial width given to the layout. It can be either larger or smaller than the text content width, depending on whether the text was wrapped.
- Left
A value that indicates the left-most point of formatted text relative to the layout box, while excluding any glyph overhang.
- MaxBidiReorderingDepth
The maximum reordering count of any line of text, used to calculate the most number of hit-testing boxes needed. If the layout has no bidirectional text, or no text at all, the minimum level is 1.
- Top
A value that indicates the top-most point of formatted text relative to the layout box, while excluding any glyph overhang.
- Width
A value that indicates the width of the formatted text, while ignoring trailing whitespace at the end of each line.
- WidthIncludingTrailingWhitespace
The width of the formatted text, taking into account the trailing whitespace at the end of each line.
- WidthMax
Gets the maximum value of Width and WidthIncludingTrailingWhitespace.