HTMLText
Renders text with support for styling via HTML tags. The rendering can vary across browsers and platforms.
Usage
API
Props
Name | Description |
---|---|
anchor | PointLike The anchor sets the origin point of the text. |
blendMode | The blend mode to be applied to the sprite. Apply a value of PIXI.BLEND_MODES.NORMAL to reset the blend mode. |
instance | PIXI.HTMLText The PIXI.Text instance. Can be set or bound to. |
pluginName | string Plugin that is responsible for rendering this element. |
roundPixels | boolean If true PixiJS will Math.floor() x/y values when rendering, stopping pixel interpolation. Advantages can include sharper image quality (like text) and faster rendering on canvas. The main disadvantage is movement of objects may appear less smooth. |
style | PIXI.HTMLTextStyle Sets the style of the text |
text | string The text to display |
Additional props are passed on to Container
Slots
Name | Props | Fallback |
---|---|---|
default | {} |
Events
Name | Type | Detail |
---|---|---|
added | forwarded | |
click | forwarded | |
create | forwarded | |
globalmousemove | forwarded | |
globalpointermove | forwarded | |
globaltouchmove | forwarded | |
mousedown | forwarded | |
mousemove | forwarded | |
mouseout | forwarded | |
mouseover | forwarded | |
mouseup | forwarded | |
mouseupoutside | forwarded | |
pointercancel | forwarded | |
pointerdown | forwarded | |
pointermove | forwarded | |
pointerout | forwarded | |
pointerover | forwarded | |
pointertap | forwarded | |
pointerup | forwarded | |
pointerupoutside | forwarded | |
removed | forwarded | |
removedFrom | forwarded | |
rightclick | forwarded | |
rightdown | forwarded | |
rightup | forwarded | |
rightupoutside | forwarded | |
tap | forwarded | |
touchcancel | forwarded | |
touchend | forwarded | |
touchendoutside | forwarded | |
touchmove | forwarded | |
touchstart | forwarded |