[ Home ] [ Authors ] [ Index ] [ Abbreviations ] [ Bindings ]

Message Classes

The dialog procedures that post messages for the user are based on Itcl classes described below. These classes can also be invoked directly by the user, providing much more flexibility. They also serve as base classes for more elaborate dialogs.

Message Class

Many messages require an "OK" button that has the effect of dismissing the message. The Message class is derived from DialogWindow and adds this feature.

::tycho::Message .x -text {A simple message window}
wm deiconify .x
Of course, you can also add buttons to this using the addButton method:
.x addButton pushme -text {Push Me} -command {post thanks}

ErrorMessage Class

The class ErrorMessage is derived from Message and simply adds the "Stack Trace" button.

::tycho::ErrorMessage .xx -text {An error message}
wm deiconify .xx


Copyright © 1996, The Regents of the University of California. All rights reserved.
Last updated: 96/04/09, comments to: eal@eecs.berkeley.edu