VCheckButtonEvent
Name
VCheckButtonEvent - checks if an event occured in a Button Item.
Synopsis
VCheckButtonEvent(event)
XEvent *event;
Description
VCheckButtonEvent checks if an event occured in a Button Item, and
takes appropriate action according to the type of the event.
Please note that VCheckButtonEvent should not be used for panel buttons
(see VSelectPanelItem).
Return Value
0 - work successfully.
269 - no Button Item found.
Parameters
event - X-window event.
Side Effects
The "mode" (enabled, disabled) of a Button Item is changed
according to the type of event -
BUTTON: LEFT-BUTTON - Calls the "Notify Procedure" associated with
the button.
TOGGLE: LEFT-BUTTON - If mode is ON => change it to OFF.
LEFT-BUTTON - If mode is OFF => change it to ON.
Entry Conditions
VCreateColormap should be called earlier, else VCheckButtonEvent prints
an error message to the standard error stream, produces a core dump file
and exits from the current process.
Related Functions
VAddButton,
VSetButtonOn.