Difference between revisions of "UI Editor/Components"
(Created page with "Components represent the various bits of UI that appear on windows (labels, buttons, menus, etc). They also have scripting interfaces for mod...") |
|||
Line 3: | Line 3: | ||
When selecting a Component or [[UI Editor/Window|Window]] in the [[UI Editor/Hierarchy|Hierarchy]] panel, its relevant properties are displayed in the [[UI Editor/Inspector|Inspector]] tab. | When selecting a Component or [[UI Editor/Window|Window]] in the [[UI Editor/Hierarchy|Hierarchy]] panel, its relevant properties are displayed in the [[UI Editor/Inspector|Inspector]] tab. | ||
− | == Label == | + | == Creating Components == |
+ | # Find the window or component you would like as the parent for the new component in the Hierarchy panel | ||
+ | # Right click the desired parent and expand the "Add" sub-menu | ||
+ | # Select the type of component from the sub-menu list | ||
+ | # The new component will be automatically selected when created | ||
+ | |||
+ | == Types of Components == | ||
+ | === Label === | ||
A label represents a static piece of text on the screen. Labels can be used by themselves or as a sub-component of more complex components like buttons. | A label represents a static piece of text on the screen. Labels can be used by themselves or as a sub-component of more complex components like buttons. | ||
− | == Imagebox == | + | === Imagebox === |
An image box provides a static image to display as part of a window. This is often used for icons, legend/key images, and non-interactive stylistic elements. | An image box provides a static image to display as part of a window. This is often used for icons, legend/key images, and non-interactive stylistic elements. | ||
− | == Button == | + | === Button === |
Buttons are one of the most ubiquitous UI components, providing click-handling functionality, a label, and optionally an icon. | Buttons are one of the most ubiquitous UI components, providing click-handling functionality, a label, and optionally an icon. | ||
− | == Menu == | + | === Menu === |
A menu allows the script to populate a set of items that can be clicked to activate a callback function. | A menu allows the script to populate a set of items that can be clicked to activate a callback function. |
Revision as of 16:40, 16 November 2017
Components represent the various bits of UI that appear on windows (labels, buttons, menus, etc). They also have scripting interfaces for modifying them from JavaScript.
When selecting a Component or Window in the Hierarchy panel, its relevant properties are displayed in the Inspector tab.
Creating Components
- Find the window or component you would like as the parent for the new component in the Hierarchy panel
- Right click the desired parent and expand the "Add" sub-menu
- Select the type of component from the sub-menu list
- The new component will be automatically selected when created
Types of Components
Label
A label represents a static piece of text on the screen. Labels can be used by themselves or as a sub-component of more complex components like buttons.
Imagebox
An image box provides a static image to display as part of a window. This is often used for icons, legend/key images, and non-interactive stylistic elements.
Button
Buttons are one of the most ubiquitous UI components, providing click-handling functionality, a label, and optionally an icon.
Menu
A menu allows the script to populate a set of items that can be clicked to activate a callback function.