Page Numbers: Yes First Page: 3 X: 527 Y: 10.5"
Odd Heading: Not-on-first-page
User Interface
Even Heading:
User Interface
Section 2: User Interface
The Mesa debugger uses the Tools Environment window/menu/selection package (Wisk). For more complete documentation on the philosophy behind this interface, see the Tools Environment: Guide for Tools Users and the Tajo Functional Specification. For more information on the window package see the Vista Functional Specification.
Standard window configuration
The debugger is created with two windows: a debug window (Debug.log) and an empty source file window. The same selection scheme, scrolling commands, and standard window commands apply to both windows. See below for functions specific to each window. Note: these functions are best understood by trying them as you read this document.
Typein
Typein goes to the window containing the cursor, regardless of whether that window is on top. Typein is directed to the Debugger if the cursor is not in any window. Source windows will accept input until a file is loaded; they then direct typein to the Debugger (unless they are editable; see below). Type ahead of mouse clicks and keystrokes is permitted. The following function keys are implemented (see the section on editing for an explanation of the functions):
FunctionADL KeyboardMicroswitch KeyboardKeysetControl Key
CutDELDELKeyset5↑C
PasteLFLFKeyset1↑F
NextFL3(none)Keyset3↑N
ReplaceFL4(none)Keyset4↑R
SwatFR1Spare3(none)(none)
StuffFR4Spare2Keyset2↑S
Back WordBWSpare1(none)↑W
Replace/NextFR5(none)(none)↑K
Selections
There is only one selection at any time (not one per window). Clicking RED once selects a character, clicking twice selects a word, three times a line, etc. The selection can be extended to the left or right with BLUE; a character selection is extended by characters, a word selection by words, and so on. The first and last characters of the selection are always extended by characters, regardless of the current mode of selection. The current selection is video reversed.
Scrollbars
Scrollbars do not occupy a dedicated part of the window, but instead appear on top of the left edge; you can "see through" them. To obtain a scroll bar, move left just past the edge of the window, then move right slightly, back into the window. Scrolling commands are initiated by moving into the scroll bar and clicking a mouse button; scrolling is activated when the mouse button is released. Moving out of the scroll bar before releasing the button returns you to text selection mode without repositioning the file. The thermometer in the scroll bar shows the current position of the window in the file. The positioning commands are as follows:
scrolling up [RED button]
moves the line next to the cursor to the top of the window.
relative scrolling [YELLOW button]
moves to the position in the file corresponding to the relative position of the cursor in the scroll bar (also called "thumbing").
scrolling down [BLUE button]
causes the line at the top of the window to be moved next to the cursor.
Menu commands
When the YELLOW mouse button is pressed in the text area of a window, an array of menus appears and the cursor changes to a left arrow. Select a menu by pointing at its header (causing it to video reverse) and releasing the mouse button (or alternatively, you may click RED over the title of the desired menu while continuing to hold the YELLOW button down). Similarly, select a menu command by pointing at it (causing it to video reverse) and releasing the mouse button. After seeing the menu, if you do not wish to execute a menu command, move the cursor away from the menu and release the YELLOW mouse button. Except where otherwise noted below, clicking the RED mouse button over a menu command causes the command to be executed. Whenever a menu command requires the user to click RED for confirmation, the user may click BLUE instead to abort the command.
When Wisk is working on a command, the cursor is changed to an hourglass. When it is done with the current task, the cursor returns to its normal shape. If for some reason it cannot complete the current task, the display is blinked.
Standard Menus
The standard Window Manager menu commands are as follows:
Move
repositions the corner of the window closest to the cursor in any direction. Clicking RED positions that corner of the window to the cursor location. Note that this command does not change its actual size.
Grow
pulls a corner of the window in any direction, growing or shrinking the window along either dimension (width or height). Clicking RED fixes the size of the window (subject to a minimum size restriction).
Size
shrinks the window to a small box at the top of the display (or wherever you move it), showing just the window name. This is a toggle command; alternate invocations restore and shrink the window size. It is suggested you do this to windows not currently in use, since this may free up much of the space associated with the window. Sizing the Debug.log closes and truncates the file.
Top
causes the window to be displayed on top of all other windows.
Bottom
causes the window to be displayed underneath all other windows.
Zoom
causes the window to grow to take up all of the available bitmap space. Alternate invocations of this command restore and Zoom the window.
Deactivate
deactivates the selected window; it will no longer appear on the screen and in most cases it will free the resources being used by that window. The window’s name is added to a menu of deactivated windows; this menu is available outside all windows. The window may be made active again by selecting its menu item.
A Text Ops menu is supplied with the Debug.log and source windows in addition to the window manager menu. It contains the following commands:
Find
finds the next occurence of the current selection in this window. The search begins at the first character visible in the window unless the current selection is in this window, in which case the search begins at the end of the current selection. If the search is successful, the text becomes the new selection; if it is not visible, it is scrolled to the top of the window; otherwise, the selection remains the same and the display blinks.
Position
takes the current selection as a decimal character index and positions the file in the subwindow where the menu was invoked.
Split
divides in two the subwindow where the menu was invoked. Feedback is similar to that in Laurel: the split line can be picked up at the small box on the right using RED and moved vertically. The subwindow is destroyed by moving the split line off the top or bottom of the subwindow.
Normalize Insertion
scrolls a (sub)window containing an insert point (e.g., Debug.log and editable source windows), so that the line containing the type-in point is at the top.
Normalize Selection
scrolls the (sub)window so that the line containing the leftmost position of the current selection is at the top.
Wrap
The source window is created with line wrap-around turned off. Executing the Wrap command reverses the current state.
Name Stripe / Tiny Windows
The name stripe and the top half of tiny windows function as accelerators for the window manager menu commands (Move, Grow, Size, Top, Bottom, and Zoom); they both video reverse when the cursor is in the sections that activate the window manager commands. These window operations may be invoked by positioning the cursor in the left, middle, or right region of the name stripe and clicking one of the mouse buttons; the top half of a tiny window works the same. The functions are as described above with these two exceptions:
Top/Bottom: if the window is not on top, move it to the top; if it is already on top, move it to the bottom.
Grow: does not apply to tiny windows.
The header commands are as follows:
Mouse ButtonLeft RegionMiddle RegionRight Region
REDTop/BottomZoomTop/Bottom
YELLOWGrow (corner)Grow (edge)Grow (corner)
BLUEMoveSizeMove
Debug window
The debug window is used for user/debugger communication (i.e., invoking commands, reporting uncaught signals). There is a blinking vertical bar at the place that is currently expecting input.
Source windows
A source window is used to view a text file, edit a text file, and set breakpoints. The debugger is initially created with one source window that it uses (i.e., for loading the source of the current module on the Display Stack subcommands). However, you may create as many source windows as you like. Note that Bravo formatting is ignored when displaying the file.
In addition to the standard menus, the source window has two additional menus. The Source Ops menu contains the following commands:
Create
creates a new source window at the place selected by clicking RED.
Destroy
destroys this source window after you confirm by clicking RED. Note that windows belonging to the debugger cannot be destroyed.
Attach
tells the debugger to ignore the time stamp in the source file when setting breaks. Timestamps are discussed in Section 4.
Set Break
uses the current selection to set a breakpoint (breakpoints are discussed in Section 4). If you select the word "PROCEDURE" or "PROC", a breakpoint is set on the entry to the procedure; if you select the word "RETURN", a breakpoint is set on the exit of the procedure; otherwise a breakpoint is set at the closest statement enclosing the selection. Note that if the module was compiled with cross jumping, breaks may be set in unpredictable places. Confirmation is given by moving the selection to the place at which the breakpoint is actually set. The window must contain the source file for a module in the current configuration. If there are multiple instances of a module, the current context must match the source file.
Set Trace
sets a tracepoint at a location specified as in Set Break above. Confirmation is given by moving the selection to the place at which the tracepoint is actually set.
Clear Break
clears the breakpoint or tracepoint at the location specified as above.
The breakpoint commands and Attach are available in the Source Ops menu only if a file has been loaded into the window.
The File Ops menu includes the following commands:
Load
loads a file into this source window, using the current selection as a filename (appending ".mesa" if no extension is specified).
Store
creates a file whose name is the current selection and stores the contents of the window in it. If the file already exists, overwriting it requires confirmation. After the Store command completes, the file is no longer editable.
Save
stores the contents of the window in its current file (this always requires confirmation). A Bravo style "$" file is created that is a copy of the unedited version. After the Save command completes, the file is no longer editable.
Edit
enables editing of the currently loaded read-only file (see below). Empty windows are always editable, but because they have no backing store (until they are Stored or Saved on a file), the amount of information in the window should be kept small.
Reset
discards all edits that have been made to the window (during this session). If the file was editable, the file is no longer editable, otherwise the window is made empty.
Time
replaces the current selection with the current date and time.
The Edit command is available only if a file has been associated with the window (by a previous Load, Store, Save, or if it is empty); Reset, Store, and Save apply only if the window has been edited.
Editing
The standard source window facilities provide a simple cut and paste style editor. Editing is modeless and is accomplished by simply moving the insert point and typing the desired text. (Note that unlike Bravo, the insert point is independent of the location of the selection.) Backspace and backword functions (BS and BW) are always available. The following functions are also provided:
↑REDMoves the insert point to the cursor position.
DEL (Keyset5)↑CCut deletes the current selection and puts the deleted text in the TrashBin (see LF).
LF (Keyset1)↑FPaste inserts the TrashBin at the insert point (see DEL).
FL4 (Keyset4)↑RReplace does a cut and moves the insert point to the place where the text was deleted.
FR4 (Spare2)↑SStuff inserts the current selection at the insert point.
Caution: The editing facilities are designed not to alter the original file until it is Saved or Stored, much like Bravo. This is, however, a new facility and should be used with caution; it is intended to support a small number of localized changes, not program creation or massive changes.