Button

Introduction

Button is a standard clickable object with states for enabled (default), hover, pressed, and disabled.

Layout Requirements

The Button control has no requirements – an empty container is sufficient.

TextInstance

The Button control can optionally include a Text instance named TextInstance. Setting the Button control’s Text property changes the TextInstance’s displayed string.

Code Example

Buttons provide events for Click and Push events. The following code shows how to handle these events on a button obtained from a gum runtime object named ButtonInstance:

Code Example – Code-Only Creation