DIRECTORY
ViewerClasses USING [Viewer],
MathDisplayExpr USING [DisplayExpr];
Selection Operations
GetSelection:
PROC[flavor:
ATOM]
RETURNS[Viewer, DisplayExpr];
effects: Returns the viewer and display expression associated with
currently active selection of type flavor.
SIGNALS noSelection if no such selection exists.
Active:
PROC[flavor:
ATOM]
RETURNS[
BOOL];
effects: Returns TRUE if selection of type flavor is currently active.
Otherwise returns FALSE.
Select:
PROC[flavor:
ATOM, viewer: Viewer, expr: DisplayExpr];
effects: Sets selection flavor to expr in viewer and repaints viewer.
If a previous selection existed, its associated viewer is repainted.
If expr is unselectable, primary selection is cleared (and viewer repainted).
UnSelect:
PROC[flavor:
ATOM];
effects: UnSelects current selection of type flavor.
Repaints associated viewer if selection was active.
UnSelectViewer:
PROC[v: Viewer];
effects: UnSelects all selections associated with viewer v.
END.