Pmw.OptionMenu() - single item selection widget
This class creates an option menu which consists of a menu button and an associated menu which pops up when the button is pressed. The text displayed in the menu button is updated whenever an item is selected in the menu. The currently selected value can be retrieved from the megawidget.
invoke()
method is called. The function is called with the
currently selected value as its single argument. The default is None.
setitems()
method. The default is None.
If None, a label component is not created. The default is None.
index()
method.
index()
method.
If index is None and the textvariable option of the menubutton component is the empty string, set the selected value to the first value in items. If items is empty set the selected value to the empty string.
If index is None and the textvariable option of the menubutton component is not the empty string, then do not set the selected value. This assumes that the variable is already (or will be) set to the desired value.
Home.
Pmw 0.8.1
Maintainer
gregm@iname.com.
11 Jun 1999
Manual page last reviewed: 23 October 1998