3 The EPAR Parameter Editor

For PyRAF we have written a task parameter editor that is similar to the IRAF epar function but that uses a graphical user interface (GUI) rather than a terminal-based interface. PyRAF's EPAR has some features not available in the IRAF CL, including a file browser for selecting filename parameters and a pop-up window with help on the task. Upon being invoked in the usual manner in IRAF CL emulation mode, an EPAR window for the named task appears on the screen:

--> epar imcalc

An EPAR window consists of a menu bar, current package and task information, action buttons, the parameter editing panel, and a status box. If there are more parameters than can fit in the displayed window, they will appear in a scrolling region.

3.1 Action Buttons

The EPAR action buttons are:

Execute the task with parameter values currently displayed in the EPAR windows. (Several windows may be open at once if the task has PSET parameters - see below.) If parameter values were changed and not saved (via the Save button), these new values are automatically verified and saved before the execution of the task. The EPAR window (and any child windows) is closed, and the EPAR session ends.

This button saves the parameter values associated with the current EPAR window. If the window is a child, the child EPAR window closes. If the window is the parent, the window closes and the EPAR session ends. The task is not executed.

This button resets all parameters in the current EPAR window to their system default values.

This button exits the current EPAR session without saving any modified parameter values. Parameters revert to the values they had before EPAR was started; the exception is that PSET changes are retained if PSETs were editted and explicitly saved.

Task Help
This button displays the IRAF help information for a task.

3.2 Menu Bar

The EPAR menu bar consists of File, Options, and Help menus. All of the File menu choices map directly to the action button functionality. The Options menu allows the user to choose the way help pages are displayed; the information can be directed to the user's web browser or to a pop-up window (the default). The Help menu gives access to both the IRAF task help and information on the operation of EPAR itself.

3.3 Parameter Editing Panel

Different means are used to set different parameter types. Numeric and string parameters use ordinary entry boxes. Parameters with an enumerated list of allowed values use choice lists. Booleans are selected using radio buttons. PSETs are represented by a button that when clicked brings up a new EPAR window. PSET windows and the parent parameter windows can be edited concurrently (you do not have to close the child window to make further changes in the parent window).

Parameters may be editted using the usual mouse operations (select choices from pop-up menus, click to type in entry boxes, and so on.) It is also possible to edit parameter without the mouse at all, using only the keyboard. When the editor starts, the first parameter is selected. To select another parameter, use the Tab or Return key (Shift-Tab or Shift-Return to go backwards) to move the focus from item to item. The Up and Down arrow keys also move between fields. Use the space bar to ``push'' buttons, activate pop-up menus, and toggle boolean values.

The toolbar buttons are also accessible from the keyboard using the Tab and Shift-Tab keys. They are located in sequence before the first parameter and after the last parameter (since the item order wraps around at the end.) If the first parameter is selected, Shift-Tab backs up to the ``Task Help'' button, and if the last parameter is selected then Tab wraps around and selects the ``Execute'' button. See the Help->Epar Help menu item for more information on keyboard shortcuts.

Parameters entered using entry boxes (strings and numbers) are checked for correctness when the focus shifts to another parameter (either via the Tab key or the mouse.) The parameter values are also checked when either the Save or Execute button is clicked. Any resulting errors are either displayed in the status area at the bottom (upon validation after return or tab) or in a pop-up window (for Save/Execute validation).

For parameters other than PSETs, the user can click the right-most mouse button within the entry box or choice list to generate a pop-up menu. The menu includes options to invoke a file browser, clear the entry box, or unlearn the specific parameter value. ``Clear'' removes the current value in the entry, making the parameter undefined. ``Unlearn'' restores the system default value for this specific parameter only. The file browser pops up an independent window that allows the user to examine the directory structure and to choose a filename for the entry. Some items on the right-click pop-up menu may be disabled depending on the parameter type (e.g., the file browser cannot be used for numeric parameters.)

3.4 Status Line

Finally, the bottom portion of the EPAR GUI is a status line that displays help information for the action buttons and error messages generated when the parameter values are checked for validity.

Questions or comments? Contact
Documented updated on 2004 Jun 1