Struct TtfPoint
A single point in a TrueType glyph outline contour. Coordinates are in font design units (integers).
Inherited Members
Namespace: DRIT.Drawing.Font.Ttf.Glyphs
Assembly: DRIT.Drawing.dll
Syntax
public readonly struct TtfPoint
Constructors
TtfPoint(short, short, bool, bool)
Initializes a new TtfPoint with the specified coordinates and flags.
Declaration
public TtfPoint(short x, short y, bool onCurve, bool isEndPoint)
Parameters
| Type | Name | Description |
|---|---|---|
| short | x | The X coordinate in design units. |
| short | y | The Y coordinate in design units. |
| bool | onCurve | True if this point lies on the curve; false if it is an off-curve control point. |
| bool | isEndPoint | True if this point is the last point of its contour. |
Properties
IsEndPoint
True if this point is the last point of its contour
(i.e. its index appears in endPtsOfContours).
Declaration
public bool IsEndPoint { get; }
Property Value
| Type | Description |
|---|---|
| bool |
OnCurve
True if this point lies on the curve (explicit line segment endpoint or spline endpoint). False if this is an off-curve quadratic Bézier control point.
Declaration
public bool OnCurve { get; }
Property Value
| Type | Description |
|---|---|
| bool |
X
X coordinate in design units.
Declaration
public short X { get; }
Property Value
| Type | Description |
|---|---|
| short |
Y
Y coordinate in design units.
Declaration
public short Y { get; }
Property Value
| Type | Description |
|---|---|
| short |
Methods
ToString()
Returns a string representation of this TtfPoint.
Declaration
public override string ToString()
Returns
| Type | Description |
|---|---|
| string | A string in the format "(x, y) on/off end". |