layoutMessage
import { layoutMessage } from 'pixi-silk/i18n';
function layoutMessage(
bundle: SilkBundle,
variant: number,
options: MessageLayoutOptions
): MessageLayout;
Lays out one variant of a message from baked data (brief sec. 6.2): greedy line filling over the
baked advances, breaking only where the compiler marked a break opportunity, then visual
reordering of every line from the baked bidi levels. No shaping and no Unicode tables. Number
slots map their characters through the digit tables. Text slots and inline objects are boxes.
A layout the compiler baked for exactly these options is returned as is (baked: true).
Parameters#
| Parameter | Type |
|---|---|
bundle | SilkBundle |
variant | number |
options | MessageLayoutOptions |