ExpanderButton (hwx.gui)#

class ExpanderButton(content=None, checkbox=None, radiobutton=None, **kwds)#

Bases: ButtonBase

Button used to control the visibility of another widget.

It can be constructed with an associated checkbox or radiobutton which will sync with the state of the controlled widget.

Attribute Table#

Name

Type

content

property

expanded

property

Example

from hwx import gui

# This is ExpanderButton. Click to see/hide the label
button = gui.ExpanderButton(content=gui.Label("Hello"))

show(button)
property content#

The Widget to control.

property expanded#

The visibility state of the content widget.