As you explore the demos, you will frequently encounter dialog boxes and control panels. For example, the run command opens a control panel like the one shown above that, among other things, allows you to specify how long the simulation should run. Most of the control panels that you will encounter have been designed using an X window toolkit called Tk, and every effort has been made to follow the Motif design style. Hopefully, this will look familiar to most people.
Most of the items in a control panel are self-explanatory. Consider the run control panel shown on
page 2-20. The button with the double relief (the GO button) is the default button. Hitting the return key has the same effect at clicking the mouse on this button. A different type of button is the "check button", labeled "Debug". Clicking on this button expands the control panel, as shown below, giving the user options that are sometimes useful in debugging a complex application.
The "Animation" buttons show (textually or graphically) which blocks are running at any given time. Graphical animation will dramatically slow down a simulation, so it is not advised except for occasional use. It is often useful in combination with the "STEP" button, which will fire stars one a time. The "ABORT" button differs from the "STOP" button in that the "wrapup" methods of the stars are not invoked. Thus, for example, signal plots that normally appear at the end of a simulation will not appear. Clicking on the "Debug" button a second time will reduce the control panel to its previous form. In addition, using the mouse, you can position the cursor anywhere in the text to begin editing by clicking the left button. For example, to enter a new number for "when to stop", position the cursor in the number box and type control-k followed by the new number. You can then push the GO button (or type return) to run the application the specified number of iterations.
Many control panels have text widgets. In the control panel above, for example, the box labeled "When to stop" is a text widget. To change the number, you must use Emacs-like editing control characters. These are summarized in table
Many control panels have more than one text widget. The current field is the one with the cursor, and anything you type will go into it. To change the current field to a different one, move the mouse or use the "Tab" key to move to the next one.
Although we have been working hard to eliminate them, a few old-style dialog boxes based on the Athena widgets from MIT still survive in the system. You will recognize these immediately because they are much uglier and more difficult to work with than the Tk-based widgets. Here is an example:
The text widgets in these dialog boxes also use Emacs-style commands. However, do not type return; this adds a second line to the dialog entry, which for most commands is confusing at best. If you accidentally type return, you can backspace sufficiently to get back to one line. Meta-return is the standard way to invoke the "OK" button in these widgets.
Copyright © 1990-1997, University of California. All rights