Skip to content
pixi-silk
GitHub repository
Entry point

pixi-silk/ui/pill

ValuePill: a small rounded label for live readouts (angles, sizes, distances).

import { ValuePill } from 'pixi-silk/ui/pill';

Classes#

ClassDescription
ValuePillA small rounded label for live readouts: angles while rotating, sizes while resizing, distances between snapped objects. Centred on its position. It has no ticker: call ValuePill.update each frame, or show and hide change nothing on screen. It ignores pointer events.

Interfaces#

InterfaceDescription
TextLabelA text display object a widget can own: PixiJS Text, SilkText, or anything with these members.
ValuePillOptionsOptions of ValuePill.

Type Aliases#

Type AliasDescription
LabelFactoryBuilds the label of a widget from the style the widget asks for. Widgets that show text take one as their label option, so they never import a text renderer you do not use. Pass silkLabel() from pixi-silk/text for distance-field labels, which a zooming camera scales without re-rasterising.