Layout.getLineReadonly

pango.layout_line.LayoutLine getLineReadonly(int line)

Retrieves a particular line from a [pango.layout.Layout].

This is a faster alternative to [pango.layout.Layout.getLine], but the user is not expected to modify the contents of the line (glyphs, glyph widths, etc.).

Parameters

linethe index of a line, which must be between 0 and pango_layout_get_line_count(layout) - 1, inclusive.

Returns

the requested [pango.layout_line.LayoutLine],

or null if the index is out of range. This layout line can be ref'ed and retained, but will become invalid if changes are made to the [pango.layout.Layout]. No changes should be made to the line.