API reference

Every public class, method, and event in @codexo/exojs. Generated from source.

I

interfaceTextLineMetrics

@codexo/exojs / rendering / stable

One laid-out line, in the same local space as GlyphPlacement.

7
props
0
methods
0
events
Import
import { TextLineMetrics } from '@codexo/exojs'

One laid-out line, in the same local space as GlyphPlacement.

Properties7
count: number
How many glyphs this line placed. Zero for an empty line.
sourceEnd: number
UTF-16 offset one past this line's content. Whitespace a wrap dropped and characters an ellipsis replaced lie outside the range.
sourceStart: number
UTF-16 offset in the laid-out string where this line's content starts. The index space is the string handed to layoutText, before whitespace preprocessing and wrapping. This is what maps a caret or a selection onto a line, and it is the only thing that can: a soft wrap splits one string into several lines with no character to mark the break.
start: number
Index of this line's first glyph in placements.
width: number
Advance width of the line, with no trailing letter spacing. For a justified line this is the width AFTER justification (equal to the paragraph's widest line), not the line's natural pre-justify width.
x: number
Pen origin of the line's first glyph, so the alignment offset is included.
y: number
Top of this line's box.
Source