Pmw.RadioSelect() - a set of buttons, some of which may be selected
This class creates a manager widget for containing buttons. In single selection mode, only one button may be selected at any one time. In multiple selection mode, several buttons may be selected. Selected buttons are displayed sunken. The buttons may be laid out either horizontally or vertically.
invoke()
.
If selectmode is 'single', then the function is called with a single argument, which is the name of the button which was invoked.
If selectmode is 'multiple', then the function is called with the first argument being the name of the button which was invoked and the second argument being either 0 or 1 depending on whether the button is currently selected. The default is None.
If None, a label component is not created. The default is None.
add()
method. If
there is no label component, then no frame component is
created and the hull component acts as the container. By default, this component is a Tkinter.Frame.
Button components are created dynamically by the add()
method. By default, the buttons are of type Tkinter.Button
and are created with a component group of Button.
If selectmode is 'multiple', return a list of the names of the currently selected buttons.
If selectmode is 'multiple' and the button has been selected, then the name of the button is appended to the current selection, the button is displayed sunken and the function specified by the command option is called with the name of the button as the first argument and 1 as the second argument.
If selectmode is 'multiple' and the button has been deselected, then the name of the button is removed from the current selection, the button is displayed raised and the function specified by the command option is called with the name of the button as the first argument and 0 as the second argument.
See the index()
method for the format of index.
Home. Pmw 0.7 Maintainer gregm@iname.com. 2 Jun 1998