ImagerViewer.mesa
Copyright © 1985 by Xerox Corporation. All rights reserved.
Michael Plass, April 30, 1985 11:42:28 am PDT
Tim Diebert: July 23, 1985 2:46:39 pm PDT
DIRECTORY
Imager USING [Context],
Rope USING [ROPE],
ViewerClasses USING [DestroyProc, NotifyProc, Viewer, ViewerRec];
ImagerViewer:
CEDAR
DEFINITIONS ~
BEGIN
OPEN Imager, ViewerClasses;
Units:
TYPE ~ {pixels, meters};
Create:
PROC [info: ViewerRec, units: Units, v: Viewer ←
NIL, clientData:
REF
ANY←
NIL]
RETURNS [Context];
Makes a context aimed at a viewer. Defaults to the "right" thing for any NILs.
FancyCreate:
PROC [info: ViewerRec, units: Units, v: Viewer ←
NIL,
notify: NotifyProc←
NIL, tipTable: Rope.
ROPE←
NIL, destroy: DestroyProc←
NIL, clientData:
REF
ANY←
NIL]
RETURNS [Context];
Makes a context aimed at a viewer. Defaults to the "right" thing for any NILs.
ClientDataFromViewer:
PROC [viewer: Viewer]
RETURNS [clientData:
REF
ANY←
NIL];
Returns the client data. Must be called to get it back. It is not the viewer.data.
Clear:
PROC [context: Context];
Clears the viewer and resets the state of the imager variables.
Erase:
PROC [context: Context];
Erases the viewer without changing the imager variables.
Reset:
PROC [context: Context];
Resets the state of the imager variables without changing the screen.
GetViewer:
PROC [context: Context]
RETURNS [Viewer];
END.