UINineSlice
Defined in: ui/src/UINineSlice.ts:24
Displays a nine-slice texture as a UI element. Requires explicit width/height from layout.
Extends
Section titled “Extends”Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new UINineSlice(
props):UINineSlice
Defined in: ui/src/UINineSlice.ts:38
Parameters
Section titled “Parameters”Returns
Section titled “Returns”UINineSlice
Overrides
Section titled “Overrides”Properties
Section titled “Properties”_transform
Section titled “_transform”
readonly_transform:ElementTransform
Defined in: ui/src/UIElementBase.ts:20
Internal
Inherited from
Section titled “Inherited from”container
Section titled “container”
readonlycontainer:NineSliceSprite
Defined in: ui/src/UINineSlice.ts:25
yogaNode
Section titled “yogaNode”
readonlyyogaNode:Node
Defined in: ui/src/UINineSlice.ts:26
Overrides
Section titled “Overrides”Accessors
Section titled “Accessors”displayObject
Section titled “displayObject”Get Signature
Section titled “Get Signature”get displayObject():
DisplayContainer
Defined in: ui/src/UINineSlice.ts:28
Returns
Section titled “Returns”DisplayContainer
Overrides
Section titled “Overrides”rotation
Section titled “rotation”Get Signature
Section titled “Get Signature”get rotation():
number
Defined in: ui/src/UIElementBase.ts:50
See LayoutProps.rotation.
Returns
Section titled “Returns”number
Set Signature
Section titled “Set Signature”set rotation(
value):void
Defined in: ui/src/UIElementBase.ts:54
Parameters
Section titled “Parameters”number
Returns
Section titled “Returns”void
Inherited from
Section titled “Inherited from”Get Signature
Section titled “Get Signature”get scale():
Readonly<{x:number;y:number; }>
Defined in: ui/src/UIElementBase.ts:41
See LayoutProps.scale.
Returns
Section titled “Returns”Readonly<{ x: number; y: number; }>
Set Signature
Section titled “Set Signature”set scale(
value):void
Defined in: ui/src/UIElementBase.ts:45
Parameters
Section titled “Parameters”number | { x: number; y: number; }
Returns
Section titled “Returns”void
Inherited from
Section titled “Inherited from”transformOrigin
Section titled “transformOrigin”Get Signature
Section titled “Get Signature”get transformOrigin():
Readonly<{x:number;y:number; }>
Defined in: ui/src/UIElementBase.ts:32
See LayoutProps.transformOrigin.
Returns
Section titled “Returns”Readonly<{ x: number; y: number; }>
Set Signature
Section titled “Set Signature”set transformOrigin(
value):void
Defined in: ui/src/UIElementBase.ts:36
Parameters
Section titled “Parameters”number | { x: number; y: number; }
Returns
Section titled “Returns”void
Inherited from
Section titled “Inherited from”visible
Section titled “visible”Get Signature
Section titled “Get Signature”get visible():
boolean
Defined in: ui/src/UINineSlice.ts:109
Returns
Section titled “Returns”boolean
Set Signature
Section titled “Set Signature”set visible(
v):void
Defined in: ui/src/UINineSlice.ts:113
Parameters
Section titled “Parameters”boolean
Returns
Section titled “Returns”void
Overrides
Section titled “Overrides”zIndex
Section titled “zIndex”Get Signature
Section titled “Get Signature”get zIndex():
number
Defined in: ui/src/UIElementBase.ts:59
See LayoutProps.zIndex.
Returns
Section titled “Returns”number
Set Signature
Section titled “Set Signature”set zIndex(
value):void
Defined in: ui/src/UIElementBase.ts:63
Parameters
Section titled “Parameters”number
Returns
Section titled “Returns”void
Inherited from
Section titled “Inherited from”Methods
Section titled “Methods”_inspectState()
Section titled “_inspectState()”_inspectState():
object
Defined in: ui/src/UINineSlice.ts:157
Internal
What the Inspector reports for this nine-slice: whether it takes part in focus navigation, which is off unless the game asked for it, and whether it holds focus right now. A test reads this instead of a screenshot.
Returns
Section titled “Returns”object
focusable
Section titled “focusable”focusable:
boolean
focused
Section titled “focused”focused:
boolean
applyLayout()
Section titled “applyLayout()”applyLayout():
void
Defined in: ui/src/UINineSlice.ts:100
Set sprite dimensions to match Yoga computed size.
Returns
Section titled “Returns”void
applyTransformProps()
Section titled “applyTransformProps()”
protectedapplyTransformProps(props):void
Defined in: ui/src/UIElementBase.ts:27
Apply the four transform props present in props. A present key holding
undefined resets that prop to its default. Throws before writing
anything if a value is not finite.
Parameters
Section titled “Parameters”Returns
Section titled “Returns”void
Inherited from
Section titled “Inherited from”UIElementBase.applyTransformProps
destroy()
Section titled “destroy()”destroy():
void
Defined in: ui/src/UINineSlice.ts:162
Idempotent — a second call is a no-op.
Returns
Section titled “Returns”void
Overrides
Section titled “Overrides”update()
Section titled “update()”update(
p):void
Defined in: ui/src/UINineSlice.ts:118
Parameters
Section titled “Parameters”Partial<UINineSliceProps>
Returns
Section titled “Returns”void
Overrides
Section titled “Overrides”Coding agents: fetch https://yage.dev/llms.txt first and prefer the Markdown references it links over these HTML pages. This page's Markdown counterpart is /llms/packages/ui.md.