Toggle Button

The Toggle Button allows users to switch between two states.

To define a Toggle Button, set the togglable property of the button to true. The Toggle Button supports the same configuration options as the standard Button.

Clicking a Toggle Button triggers the toggle event but does not trigger the click event.

The following example demonstrates how to define a Toggle Button in the ToolBar widget.

<div id="toolbar"></div>

        items: [
                type: "button",
                togglable: true,
                text: "My Toggle Button",
                spriteCssClass: "myIcon",
                showIcon: "toolbar",
                selected: true

See Also

In this article
Not finding the help you need? Improve this article