GUIDO Events and Callbacks
Overview
The Guido processing engine allows for certain events to be caught, and registered callback procedures to be invoked when an event occurs while the form is displayed. Coding of callback procedures requires knowledge of Tcl procedures and is intended for advanced users only.
There are three types of Guido callbacks that can be registered. They are:
Action callbacks in Guido are used to modify the form at runtime in some manner. This may be to change a value in a field, to change the value list of a combo box, to add a row to a table, or any other action that physically changes the form. There are a number of events that can occur on a form that can cause an action callback to be invoked. These are discussed in detail in the Action Callbacks section.
A dependency callback is used to make a Guido widget or container dependent upon the value entered into another Guido widget on the form. When the dependency condition is false the Guido Widget is greyed out and is visible when the condition is true. In the case of Guido containers such as panels, the container will become invisible when a dependency condition is false and is visible otherwise.
A validation callback allows you define your own set of validation rules outside of the standard Guido validation switches like -format, -low_bound, etc. A procedure to handle the validation must be created in the form definition. The procedure must return a true value (1) or a false value (0) depending upon the outcome of the validation test. Validation callbacks are invoked as part of the validation sequence once the form has been applied.
An integral part of coding callback procedures using Guido Object Methods to access and control behaviours of the widgets and containers. Each Guido object (command) that you define on the form has an associated set of methods that you can call from your callback procedures. The full set of object methods can be found here.
See Also
Guido
Dependency
Callbacks
Action Callbacks
Validation
Callbacks
Common guido switches