DIRECTORY CD, Rope; CDUtil: CEDAR DEFINITIONS = BEGIN Direction: TYPE = {right, up, left, down, none}; InstRec: TYPE = RECORD [ ob: CD.Object, name: Rope.ROPE _ NIL, --instance Name orient: CD.Orientation _ original, dX: CD.Number_0, dY: CD.Number_0, properties: CD.PropList_NIL --for the instance ]; CreateSimpleCell: PROC [ design: CD.Design, contents: LIST OF InstRec, cellName: Rope.ROPE _ NIL, direction: Direction _ right, alignHigh: BOOL _ FALSE] RETURNS [CD.Object]; PartialCopy: PROC [ob: CD.Object, design: CD.Design, instances: LIST OF Rope.ROPE_NIL, remove: BOOL_TRUE, prop: ATOM _ $InstanceName, name: Rope.ROPE_NIL] RETURNS [CD.Object]; InstPredicate: TYPE = PROC [inst: CD.Instance] RETURNS [BOOL]; Flatten: PROC [ob: CD.Object, design: CD.Design, flattenInst: InstPredicate_NIL] RETURNS [new: CD.Object]; END. „CDUtil.mesa Copyright c 1985, 1986 by Xerox Corporation. All rights reserved. Created by Christian Jacobi, June 7, 1985 5:16:21 pm PDT Last edited by: Christian Jacobi, November 17, 1986 11:38:57 am PST Handy procedures for creating designs from programs. --Creates a cell by basically abutting the instances (interest rects) --design: cell is included into design; all instances must be in design too --contents: list of descriptions of instances -- the first is placed at an origin, -- all others are placed abutting their predecessor in direction "direction" -- (if direction is none: dX, dY is absolute) --cellName: name given to cell --direction: direction of abutting --alignHigh: -- FALSE: put the edges with smaller coordinate values into a line -- TRUE: put the edges with larger coordinate values into a line -- dX, dY: the instance is displaced by this amount before including; -- not defaulting this causes to create not really abutting instances --Copy the object; creates a cell --remove TRUE: -- all the instances with property prop are and a value in instances are removed --remove FALSE: -- only the instances with property prop are and a value in instances are copied --interest rect: -- if explicit, it will be copied, -- if defaulted, a new one will be defaulted --the origin will be inherited --Flattens the content of an object. Works all the way down (not just the top level). --For each instance checks whether this instance should be flattened by calling InstPredicate. --The default flattenInst flattens only subobjects in the directory and stops flattening --subobjects with a non-nil $DontFlatten property. Κƒ˜codešœ ™ Kšœ Οmœ7™BKšœ8™8K™C—K˜šΟk ˜ Kšžœ˜ —K˜KšΟnœžœž œ˜Kšžœ˜K˜K™4K˜Kšœ žœ!˜0K˜šœ žœžœ˜Kšœžœ˜Kšœ žœžœΟc˜&Kšœžœ˜#Kšœžœ ˜Kšœžœ ˜Kšœ žœ žœ ˜/K˜K˜—šŸœžœ˜Kšœžœ ˜Kšœ žœžœ ˜Kšœžœžœ˜Kšœ˜Kšœ žœžœ˜Kšžœžœ ˜K™EKšœK™KKšœ.™.Kšœ&™&KšœM™MKšœ.™.Kšœ™Kšœ"™"Kšœ ™ K™CK™AK™K™E™FK™——šŸ œžœžœžœžœžœžœžœ žœžœžœžœžœžœžœ ˜―Kšœ"™"Kšœ™KšœR™RKšœ™KšœP™PKšœ™Kšœ#™#Kšœ/™/Kšœ!™!—K˜Kš œžœžœžœ žœžœ˜>K˜šŸœžœžœžœ$žœžœžœ ˜jKš V™VKšœ^™^KšœY™YKšœ2™2—K˜Kšžœ˜K˜—…—P W