Button¶
- class UI.Button¶
A text label. See
UI.Panel.add_button()
.- rect_transform: UI.RectTransform¶
The rect transform for the text.
- Attribute:
Read-only, cannot be set
- Return type:
- visible: boolean¶
Whether the UI object is visible.
- Attribute:
Can be read or written
- Return type:
boolean
- clicked: boolean¶
Whether the button has been clicked.
- Attribute:
Can be read or written
- Return type:
boolean
Note
This property is set to true when the user clicks the button. A client script should reset the property to false in order to detect subsequent button presses.
- remove()¶
Remove the UI object.