1681-engine / ui / RichTextOptions
Interface: RichTextOptions ​
Defined in: src/ui/rich/RichText.ts:8
Extends ​
Properties ​
align? ​
optional align?: RichAlign;Defined in: src/ui/rich/richLayout.ts:28
Inherited from ​
colors? ​
optional colors?: Readonly<Record<string, string>>;Defined in: src/ui/rich/richMarkup.ts:45
Colour names the markup may use besides hex ([color=gold]).
Inherited from ​
font ​
font: RichFont;Defined in: src/ui/rich/RichText.ts:10
What the runs are drawn with: CanvasRichFont, BitmapRichFont, or a game's own.
iconScale? ​
optional iconScale?: number | "line";Defined in: src/ui/rich/richLayout.ts:35
'line' (default): an icon is as tall as its style's line — on a pixel-perfect layout the largest whole multiple of its frame that fits, never below 1×, so its texels stay square. A number: that scale, whatever the line.
Inherited from ​
lineSpacing? ​
optional lineSpacing?: number;Defined in: src/ui/rich/richLayout.ts:30
Extra pixels between lines.
Inherited from ​
pixelPerfect? ​
optional pixelPerfect?: boolean;Defined in: src/ui/rich/richLayout.ts:37
Whole-pixel positions and icon scales (a pixel-art game).
Inherited from ​
RichLayoutOptions.pixelPerfect
textures? ​
optional textures?: TextureRegistry;Defined in: src/ui/rich/RichText.ts:12
Where [icon=…] keys are looked up; without it icons take no room and draw nothing.
wrapWidth? ​
optional wrapWidth?: number;Defined in: src/ui/rich/richLayout.ts:27
Wrap lines to this width; unset, lines break only at \n.