mirror of
https://github.com/godotengine/godot.git
synced 2024-12-03 09:52:18 +08:00
46 lines
2.8 KiB
XML
46 lines
2.8 KiB
XML
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<class name="CheckButton" inherits="Button" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
|
|
<brief_description>
|
|
A button that represents a binary choice.
|
|
</brief_description>
|
|
<description>
|
|
[CheckButton] is a toggle button displayed as a check field. It's similar to [CheckBox] in functionality, but it has a different appearance. To follow established UX patterns, it's recommended to use [CheckButton] when toggling it has an [b]immediate[/b] effect on something. For example, it can be used when pressing it shows or hides advanced settings, without asking the user to confirm this action.
|
|
See also [BaseButton] which contains common properties and methods associated with this node.
|
|
</description>
|
|
<tutorials>
|
|
</tutorials>
|
|
<members>
|
|
<member name="alignment" type="int" setter="set_text_alignment" getter="get_text_alignment" overrides="Button" enum="HorizontalAlignment" default="0" />
|
|
<member name="toggle_mode" type="bool" setter="set_toggle_mode" getter="is_toggle_mode" overrides="BaseButton" default="true" />
|
|
</members>
|
|
<theme_items>
|
|
<theme_item name="check_v_offset" data_type="constant" type="int" default="0">
|
|
The vertical offset used when rendering the toggle icons (in pixels).
|
|
</theme_item>
|
|
<theme_item name="checked" data_type="icon" type="Texture2D">
|
|
The icon to display when the [CheckButton] is checked (for left-to-right layouts).
|
|
</theme_item>
|
|
<theme_item name="checked_disabled" data_type="icon" type="Texture2D">
|
|
The icon to display when the [CheckButton] is checked and disabled (for left-to-right layouts).
|
|
</theme_item>
|
|
<theme_item name="checked_disabled_mirrored" data_type="icon" type="Texture2D">
|
|
The icon to display when the [CheckButton] is checked and disabled (for right-to-left layouts).
|
|
</theme_item>
|
|
<theme_item name="checked_mirrored" data_type="icon" type="Texture2D">
|
|
The icon to display when the [CheckButton] is checked (for right-to-left layouts).
|
|
</theme_item>
|
|
<theme_item name="unchecked" data_type="icon" type="Texture2D">
|
|
The icon to display when the [CheckButton] is unchecked (for left-to-right layouts).
|
|
</theme_item>
|
|
<theme_item name="unchecked_disabled" data_type="icon" type="Texture2D">
|
|
The icon to display when the [CheckButton] is unchecked and disabled (for left-to-right layouts).
|
|
</theme_item>
|
|
<theme_item name="unchecked_disabled_mirrored" data_type="icon" type="Texture2D">
|
|
The icon to display when the [CheckButton] is unchecked and disabled (for right-to-left layouts).
|
|
</theme_item>
|
|
<theme_item name="unchecked_mirrored" data_type="icon" type="Texture2D">
|
|
The icon to display when the [CheckButton] is unchecked (for right-to-left layouts).
|
|
</theme_item>
|
|
</theme_items>
|
|
</class>
|