12.07.2015 Views

Athena Widget Set - C Language Interface - X Consortium ... - X.Org

Athena Widget Set - C Language Interface - X Consortium ... - X.Org

Athena Widget Set - C Language Interface - X Consortium ... - X.Org

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Simple <strong>Widget</strong>s• Processing application callbacks with notify• Switching the internal border between highlighted and unhighlighted states withhighlight and unhighlightThe following are the default translation bindings used by the Command widget:: highlight(\|): reset(\|): set(\|): notify(\|) unset(\|)The full list of actions supported by Command is:highlight(condition)unhighlight(\|)set(\|)unset(\|)reset(\|)notify(\|)Displays the internal highlight border in the color(foreground or background ) that contrasts with theinterior color of the Command widget. The conditionsWhenUnset and Always are understood by this actionprocedure. If no argument is passed, WhenUnset isassumed.Displays the internal highlight border in the color(foreground or background ) that matches the interiorcolor of the Command widget.Enters the set state, in which notify is possible. Thisaction causes the button to display its interior in theforeground color. The label or bitmap is displayed inthe background color.Cancels the set state and displays the interior of thebutton in the background color. The label or bitmapis displayed in the foreground color.Cancels any set or highlight and displays the interiorof the button in the background color, with the labelor bitmap displayed in the foreground color.When the button is in the set state this action calls allfunctions in the callback list named by the callbackresource. The value of the call_data argument passedto these functions is undefined.A very common alternative to registering callbacks is to augment a Command'stranslations with an action performing the desired function. This often takes theform of:*Myapp*save.translations: #augment ,: Save()24

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!