-- GEditClasses.mesa; Edited by McGregor on December 10, 1982 1:19 pm
DIRECTORY
Graphics USING [Context],
OtherNode USING [CopyInfoProc, ReadSpecsProc, WriteSpecsProc],
TextNode USING [RefOtherNode],
ViewerClasses USING [Viewer];
GEditClasses: DEFINITIONS = BEGIN
ClassID: TYPE = ATOM ;
Class: TYPE = REF ClassRec ;
ClassRec: TYPE = RECORD [
flavor: ClassID ← NIL,
newProc: NewProc ← NIL,
deleteProc: DeleteProc ← NIL,
moveProc: MoveProc ← NIL,
selectProc: SelectHighlightProc ← NIL,
paintProc: PaintProc,
resolveProc: ResolveProc ← NIL,
nextProc: NextProc ← NIL,
inputProc: InputProc ← NIL,
readProc: ReadProc ← NIL,
writeProc: WriteProc ← NIL,
copyProc: CopyProc ← NIL
] ;
Object: TYPE = TextNode.RefOtherNode ;
SelectionGrain: TYPE = {point, object} ← point;
ControlPoint: TYPE = INTEGER ← 0;
NewProc: TYPE = PROC [self: Object, x, y: INTEGER, parent: ViewerClasses.Viewer] ;
DeleteProc: TYPE = PROC [self: Object] ;
MoveProc: TYPE = PROC [self: Object, parent: ViewerClasses.Viewer, controlPoint: ControlPoint, grain: SelectionGrain, dx, dy: INTEGER] ;
SelectHighlightProc: TYPE = PROC [self: Object, context: Graphics.Context, controlPoint: ControlPoint, grain: SelectionGrain] ;
ResolveProc: TYPE = PROC [self: Object, x, y: INTEGER] RETURNS [affinity: INTEGER, controlPoint: ControlPoint, tx, ty: INTEGER] ;
PaintProc: TYPE = PROC [self: Object, context: Graphics.Context] ;
NextProc: TYPE = PROC [self: Object, current: ControlPoint, backwards: BOOL] RETURNS [next: ControlPoint] ;
InputProc: TYPE = PROC [self: Object, input: REF ANY] RETURNS [paintAll, paintMe: BOOL] ;
ReadProc: TYPE = OtherNode.ReadSpecsProc ;
WriteProc: TYPE = OtherNode.WriteSpecsProc ;
CopyProc: TYPE = OtherNode.CopyInfoProc ;
END.