Interface ITextLayout2
interface ITextLayout2
Extends ITextLayout
This interface extends ITextLayout with additional functionalities to retrieve data such as
line metrics, text lines and rects for a particular range.
Methods
getLineMetrics()
Returns the line metrics for a single line of text within a paragraph.ILineMetric*[]getLineMetrics()
Returns
ILineMetric*[]
A list of ILineMetric struct containing the metrics for the line of text.
getTextLines()
Returns a list ofITextLine*[]getTextLines()
ITextLine objects which includes the range
of characters from the source text that it contains.
Returns
ITextLine*[]
A list of ITextLine objects containing the range for each of the lines.
getRectsForRange()
Returns a list of bounding boxes that enclose all text between start and end of glyph indexes, including start and excluding end. If start >= end, the resultant array will be empty (size 0).Rect[]getRectsForRange(u32start,u32end)
Parameters
start
u32 — Required
index.
end
u32 — Required
index.
Returns
Rect[]
A list of Rect objects representing the bounding boxes for the specified range of glyphs.

