DIRECTORY GGModelTypes, ImagerTransformation; GGBoxCluster: CEDAR DEFINITIONS = BEGIN Cluster: TYPE = GGModelTypes.Cluster; ClusterDescriptor: TYPE = GGModelTypes.ClusterDescriptor; ClusterClass: TYPE = GGModelTypes.ClusterClass; BoundBox: TYPE = GGModelTypes.BoundBox; Corner: TYPE = {none, ll, lr, ul, ur}; -- lower left, lower right, upper left, upper right Edge: TYPE = {none, left, right, top, bottom}; MakeBoxCluster: PROC [box: BoundBox, corner: Corner, transform: ImagerTransformation.Transformation] RETURNS [clusD: ClusterDescriptor]; BuildBoxClusterClass: PROC [] RETURNS [class: ClusterClass]; GetBox: PROC [cluster: Cluster] RETURNS [box: BoundBox]; SetBox: PROC [cluster: Cluster, box: BoundBox]; END.  GGBoxCluster.mesa Copyright c 1986 by Xerox Corporation. All rights reserved. Last edited by Pier on April 29, 1986 3:41:51 pm PDT Contents: Implements the box cluster class in Gargoyle. Bier, May 1, 1986 2:45:54 pm PDT A box is a cluster which maintains its rectilinear properties. It is possible to select/drag one of four corners, one of four edges, or the entire box. When a corner is dragged, box is rubberbanded to keep its box shape. When an edge is dragged, only the perpendicular component of the drag vector is used to move the edge, thus maintaining box shape. When the entire box is selected (traj or topLevel), it can be translated and rotated. April 29, 1986 3:29:28 pm PDT: translation/rotation not implemented yet. transform defaults to the identity. Ê'˜codešœ™Kšœ Ïmœ1™