Skip to content

buildTextOptions

buildTextOptions(text, style, bitmap, resolution): object

Defined in: renderer/src/internal/textConstruction.ts:17

Internal

Build the shared Text / BitmapText constructor options and pick the Pixi class for both TextComponent and UIText. bitmap selects BitmapText; the object form folds the font name / size into the style. resolution is forwarded only to canvas TextBitmapText resolution is fixed at font-bake time (Pixi v8 warns if you set it per-instance), so use installBitmapFont({ resolution }).

Centralised so the two text classes can’t drift on the Pixi-v8 resolution-gating rule.

string

TextStyleOptions | undefined

BitmapTextOption | undefined

number | undefined

object

bitmap: boolean

options: TextOptions