lineOfIndex
import { lineOfIndex } from 'pixi-silk/text';
function lineOfIndex(
layout: TextLayout,
index: number,
upstream?: boolean
): number;
The line a caret at index is on. At a wrap, upstream picks the end of the first line over the start of the next.
Parameters#
| Parameter | Type | Default value |
|---|---|---|
layout | TextLayout | undefined |
index | number | undefined |
upstream | boolean | false |
Returns#
number