Abutters.Mesa
Last Edited by: Spreitzer, April 13, 1985 3:56:17 pm PST
DIRECTORY ViewerClasses;
Abutters: CEDAR DEFINITIONS = {
Viewer: TYPE = ViewerClasses.Viewer;
Abutter: TYPE = REF AbutterRep;
Like a Container, only able to do more comprehensive alignment of children.
CoordSys = top.
AbutterRep: TYPE;
Create: PROC [info: ViewerClasses.ViewerRec ← [], paint: BOOLTRUE] RETURNS [abutter: Abutter];
QuaViewer: PROC [Abutter] RETURNS [Viewer];
QuaAbutter: PROC [Viewer] RETURNS [Abutter];
ViewerIsAbutter: PROC [Viewer] RETURNS [BOOL];
IsAbutter: PROC [REF ANY] RETURNS [BOOL];
Narrow: PROC [REF ANY] RETURNS [Abutter];
ScrollOffset: PROC [Abutter] RETURNS [offTop: INTEGER];
Returns the amount of the abutter scrolled off the top.
Edge: TYPE = {left, right, top, bottom};
SeriesElement: TYPE = RECORD [viewer: Viewer, spaceBefore: INTEGER ← 0];
Parallel: TYPE = LIST OF Series;
Series: TYPE = RECORD [
rigid: LIST OF SeriesElement,
end: SELECT kind: * FROM
none => [],
parallel => [p: Parallel],
stretch => [se: SeriesElement],
ENDCASE
];
Rules: TYPE = ARRAY Edge OF Series;
SetLayout: PROC [a: Abutter, rules: Rules, paint: BOOLTRUE];
Abut: PROC [a: Abutter, child1, child2: Viewer, edge: Edge, space: INTEGER ← 0, stretch: BOOLFALSE, paint: BOOLTRUE];
}.