-
Notifications
You must be signed in to change notification settings - Fork 0
3.7 Text
Jonas de Luna Skulberg edited this page Oct 14, 2023
·
1 revision
-
text?: string
Text string to display.
-
position?: InputPosition
Position of the text. -
color?: string
Color of the text. -
fontSize?: number
Text font-size. -
anchorY?: "top" | "middle" | "bottom"
Text y-anchor point. -
anchorX?: "left" | "center" | "right"
Text x-anchor point. -
weight?: fontWeight
Text font-weight.
position: [0, 0] as [number, number],
color: "black",
fontSize: 30,
anchorX: "left",
anchorY: "bottom",
weight: "regular" as fontWeight,
collidesWith(other: Object3D): boolean
distanceTo(other: Object3D<Event>): number
-
setPosition(position: InputPosition): void
Set the component position. -
setText(text: string): void
Set the text content.