SLD [ Intro | Pubs | RunInfo | Workbook | Software | SLACVX | Search ]

The SLD Event Display Additions Manual

Adding Menu Buttons

The heart of the SLD interactive one event display is its menu system. This system has been set up in a such a way that it is easy to add new buttons to an existing menu or to add whole new menus. You simply create a constant file containing DSPUMNU banks and then link these banks into the rest of the menu via a DSP USERDATA command (a certain subclass of items can even be added to the menus on-the-fly during the interactive session; see details later).

You define a number of different attributes for each menu button. The menu button can call a prepmort routine, issue an IDA command, call an IDA command file, redraw part of the picture, or define what happens later when one picks on a piece of physics data.

Some menu buttons do simple things. For example, the "X View" button in the main menu just rotates the current picture so that the view is along the X axis. Other buttons do more complicated things. For example, the "Cluster Pick Gets Kal Closeup" button in the KAL menu sets things up so that if one later picks on a KAL cluster, the cluster is redrawn in more detail, the current view parameters are saved, and the drawing is then rotated and zoomed to home in on the cluster.

DSPMENU and DSPUMNU

The basic menu banks are defined by DSPMENU banks in DSPMENU CONSTANT. You define additional menu banks by writing DSPUMNU (for User Menu) banks, which the display system then merges into its dspmenu banks. To do the merge, you issue the IDA command DSP USERDATA followed by the filename of the constant file that contains the dspumnu banks.

In writing your new dspumnu banks, study the existing dspumnu banks in KALUDSP, DBUDSP, CRDUDSP, and GEAUDSP CONSTANT (and the basic dspmenu banks in DSPMENU CONSTANT).

The Contents of DSPUMNU

Pick Buttons

Certain $TOGGLE buttons can control what happens when the user picks on a piece of data (a track, hit, cluster or so forth). These toggles are distinguished by having a PICKTYPE.

HISTROUT, HISTIDAC, RECATYPE and REDRAW mentioned above have slightly different functions when the toggle has a PICKTYPE.

More on Histogram Buttons

If your button has HISTROUT or HISTIDAC set true, the display will do the work necessary to make your histogram appear as an overlay on top of the display. The histogram must be a single plot; you cannot use QUAD, HEX and so forth.

Adding Menu Buttons On-The-FLY

On-the-fly, during the interactive session, you can add a menu button to the current menu. Just hit PF 10 on the interactive device keyboard.

The power of such buttons is limited. There is no way to add whole new menus on-the-fly. You get to specify only the LINENAME, IDACOM (or PICKIDAC for a pick button), whether the button is to lay a histogram onto the display, and PICKTYPE. Still, since the idacom can be any IDA command and can execute any IDA exec, these buttons can be quite powerful.


Joseph Perl
25 September 1997