Table of Contents

Class PdfGlyph

Namespace
PdfEngine.Vector
Assembly
PdfEngine.Abstractions.dll

Individual positioned glyph in a glyph run.

public sealed record PdfGlyph : IEquatable<PdfGlyph>
Inheritance
PdfGlyph
Implements
Inherited Members

Constructors

PdfGlyph(ushort, double, double, double, double, string?, int, double)

Individual positioned glyph in a glyph run.

public PdfGlyph(ushort GlyphId, double AdvanceX, double AdvanceY, double OffsetX = 0, double OffsetY = 0, string? Unicode = null, int CharCode = -1, double Width = -1)

Parameters

GlyphId ushort

Glyph index inside the run's font program when Face carries one; otherwise the character code / CID (kept for diagnostics).

AdvanceX double

Horizontal displacement in text space (font size, Tc, Tw and Tz applied).

AdvanceY double
OffsetX double

Glyph origin relative to the run origin, in text space.

OffsetY double
Unicode string

Semantic text for selection/search/copy. Never used to lay out glyphs (ADR-006).

CharCode int

Original PDF character code (or CID for composite fonts); -1 when unknown.

Width double

The glyph's width from the font's metrics (/Widths), in em; -1 when not known.

Properties

AdvanceX

Horizontal displacement in text space (font size, Tc, Tw and Tz applied).

public double AdvanceX { get; init; }

Property Value

double

AdvanceY

public double AdvanceY { get; init; }

Property Value

double

CharCode

Original PDF character code (or CID for composite fonts); -1 when unknown.

public int CharCode { get; init; }

Property Value

int

GlyphId

Glyph index inside the run's font program when Face carries one; otherwise the character code / CID (kept for diagnostics).

public ushort GlyphId { get; init; }

Property Value

ushort

OffsetX

Glyph origin relative to the run origin, in text space.

public double OffsetX { get; init; }

Property Value

double

OffsetY

public double OffsetY { get; init; }

Property Value

double

Unicode

Semantic text for selection/search/copy. Never used to lay out glyphs (ADR-006).

public string? Unicode { get; init; }

Property Value

string

Width

The glyph's width from the font's metrics (/Widths), in em; -1 when not known.

public double Width { get; init; }

Property Value

double