4.6. Button widget class

The Button class inherits QPushButton Qt class.

Widget's input value

A string or any object that can be converted to a string. If the string starts with "+" or "-" character, the button can be checked. "+" sets the button's state to checked, "-" to unchecked. If the button is checkable the value can be True or False.

Widget's attributes

Button's icon.
This attribute holds whether the button border is raised. The default is False.
This attribute holds whether the button is checkable. By default, the button is not checkable.
This attribute holds whether auto repeat is enabled. If auto repeat is enabled, then signals are emitted at regular intervals when the button is down. Auto repeat is off by default.
The group that the button belong to. Only one button in a group can be checked at a time.

Widget's output value

If the button is checkable, the output value is a boolean indicating the checked state. If the button is not checkable, the output value corresponds to the button label.