Table of Contents
The GOkCancelButtons widget provides a script writer with the ability to quickly insert the standard OK and cancel button idiom into their dialogs.
The following example posts a window with an OK and cancel button on it. When the user clicks the OK button, the script will print out "OK" and close. Likewise, when the user clicks the cancel button, the script will print out "cancel" and close. Normally you would do your dialog validation on when the OK button is closed, and then go ahead and process your instructions.
The above script will create a window that appears as follows,
Example of the GOkCancelButtons widget.
Defines a standard ok and cancel dialog button set.