DIRECTORY Rope USING [ROPE], CD USING [Instance, Design, Object, ObjectClass, Rect, Position, Orientation], CDDirectory USING [ReplaceList]; CDCells: CEDAR DEFINITIONS = BEGIN IsCell: PROC [ob: CD.Object] RETURNS [BOOL] = INLINE { RETURN [ ob.class = cellClass ] }; cellClass: PRIVATE READONLY CD.ObjectClass; CreateEmptyCell: PROC [] RETURNS [CD.Object]; CoordSystem: TYPE = {cdCoords, interrestCoords, originCoords}; IncludeMode: TYPE = {doit, dontReposition, dontPropagate, dontInclude}; IncludeOb: PROC [design: CD.Design_NIL, cell: CD.Object_NIL, ob: CD.Object, position: CD.Position_[0, 0], --evaluated before an eventual repositioning orientation: CD.Orientation_0, cellCSystem: CoordSystem_originCoords, obCSystem: CoordSystem_originCoords, mode: IncludeMode_doit] RETURNS [newInst: CD.Instance, rep: BOOL]; RemoveInstance: PROC [design: CD.Design_NIL, cell: CD.Object_NIL, inst: CD.Instance, mode: IncludeMode_doit] RETURNS [removed: BOOL, rep: BOOL]; ReplaceDirectChildForDummyCells: PRIVATE PROC [cellOb: CD.Object, replace: CDDirectory.ReplaceList] RETURNS [needReposition: BOOL]; RepositionCell: PROC [cellOb: CD.Object, design: CD.Design] RETURNS [didReposition: BOOL]; SetInterestRect: PROC [cellOb: CD.Object, r: CD.Rect _ [0, 0, -1, -1]]; IsPushedIn: PROC [design: CD.Design] RETURNS [yes: BOOL]; SetSimplificationTreshhold: PROC [cell: CD.Object, val: REAL, inPixels: BOOL_TRUE]; SetBorder: PROC [cell: CD.Object, border: BOOL]; CreateCellSelected: PROC [design: CD.Design, name: Rope.ROPE_NIL] RETURNS [done: BOOL, cellOb: CD.Object]; PushInCellInstance: PROC [design: CD.Design, inst: CD.Instance] RETURNS [done: BOOL]; PopFromCell: PROC [design: CD.Design, m: Method_interactive, name: Rope.ROPE_NIL] RETURNS [done: BOOL]; Method: TYPE = {flush, newcell, replace, interactive}; PushedCellName: PROC [design: CD.Design] RETURNS [Rope.ROPE]; END. ˆCDCells.mesa (a ChipNDale module) Copyright c 1983, 1985 by Xerox Corporation. All rights reserved. by Christian Jacobi, 23-Aug-83 last edited Christian Jacobi, March 25, 1986 1:35:33 pm PST --Does not includes the cell into any design or celldirectory. --Does not name the cell. --Use CDDirectory.Include to include this cell to a design's directory. --Use CDCells.IncludeOb to include objects into this cell. --procedures for creating designs by programs... -- cdCoords: chipndales internal and native coordinate system used in Instances -- interrestCoords: base of interest-rects. -- originCoords: invariant fake origin which for cells never changes, but might be far off... --design (NIL: allowed, if cell really is not yet part of a design) --cell (NIL: include into design; assumes the designs origin at [0, 0]) -- (design&cell NIL: simply create an application) --ob: object to include in cell --position: ... --orientation: of ob inside cell --cellCSystem: tells reference point in cell (for designs: [0, 0] anyway) --obCSystem: reference point of object --mode: -- doit: normal case everything is done -- dontReposition: speed up hack -- Caution: makes temporary a wrong coordinate system! cell is -- not legal until repositioning is called to clean up. -- Has no effect if cell is NIL. -- Does not cause redrawing of the design. -- dontPropagate: speed up hack. -- does neither reposition nor propagate the changed event; cell gets -- an illegal state until repositioning and change-propagation occurs. -- dontInclude: hack to create instances; cell is not changed at all. --newInst: the new created application --rep: Reposition was done or should be done, depending of mode --design (NIL: allowed, if cell really is not yet part of a design) --cell (NIL: remove from design) -- (design&cell NIL: Error) --ob: object to include in cell --position: ... --orientation: of ob inside cell --cellCSystem: tells reference point in cell (for designs: [0, 0] anyway) --obCSystem: reference point of object --mode: -- doit: normal case everything is done -- dontReposition: speed up hack -- Caution: makes temporary a wrong coordinate system! cell is -- not legal until repositioning is called to clean up. -- Has no effect if cell is NIL. -- Does not cause redrawing of the design. -- dontPropagate: speed up hack. -- does neither reposition nor propagate the changed event; cell gets -- an illegal state until repositioning and change-propagation occurs. -- dontInclude: hack to create instances; cell is not changed at all. --rep: Reposition was done or should be done, depending of mode --is like a real ReplaceDChildsProc, but does not start a recursive repositioning --save --defaulting r means to use a reasonable default for the interest rect --does not propagate the change; caller must cause correct propagation separately --procedures for the interactive edit --name=NIL: interactive read for name. --name#NIL: hint for name; may be modified. --If done: cell is included in directory of design. --inst must be an instance of the currently toplevel pushed in cell of design --message of problem if not done --message of problem if not done Κ˜codešœ#™#Kšœ Οmœ7™BKšœ™Kšœ;™;K˜—šΟk ˜ Kšœžœžœ˜KšžœžœF˜NKšœ žœ˜ —K˜KšΠlnœžœž œ˜Kšž˜K˜š Οnœžœžœ žœžœžœ˜6Kšžœ˜K˜K˜—Kšœ žœž œ ˜+K˜š œžœžœžœ ˜-Kšœ>™>KšΟc™K™GK™:K™—K™K™0K˜šœ žœ-˜>KšœO™OKšœ+™+Kšœ]™]K˜—šœ žœ6˜GK˜—š  œžœ žœžœžœžœžœ ˜LKšœ žœ‘,˜KKšœ žœ˜Kšœ(˜(Kšœ%˜%šœ˜Kšžœ žœžœ˜*—KšœC™CKšœG™GKšœ3™3Kšœ#™#Kšœ™Kšœ!™!KšœI™IKšœ&™&Kšœ™Kšœ(™(Kšœ!™!Kšœ‘œ6™AKšœ8™8Kšœ!™!Kšœ+™+Kšœ!™!KšœG™GKšœH™HKšœF™FKšœ&™&Kšœ@™@K˜—š œžœ žœžœžœžœžœ ˜UKšœžœ žœžœ˜;KšœC™CKšœ ™ Kšœ™Kšœ#™#Kšœ™Kšœ!™!KšœI™IKšœ&™&Kšœ™Kšœ(™(Kšœ!™!Kšœ‘œ6™AKšœ8™8Kšœ!™!Kšœ+™+Kšœ!™!KšœG™GKšœH™HKšœF™FKšœ@™@K˜K˜—š Πbnœžœžœ žœ+žœžœ˜ƒKšœQ™QK˜—š  œžœ žœžœ žœžœ˜[Kšœ™K™—š œžœ žœ žœ˜GKšœF™FK™QK˜—š   œžœ žœ žœžœ˜9K™—Kš  œžœžœžœ žœžœ˜SK˜Kš  œžœžœžœ˜0K™K™%K˜š œžœ žœžœžœžœžœ žœ ˜jKšœ&™&Kšœ+™+Kšœ3™3K˜—š  œžœ žœžœžœ˜UKšœM™MKšœ ™ K˜—š  œžœ žœ+žœžœžœžœ˜gKšœ ™ Kšœžœ*˜6—K˜š  œžœ žœ žœžœ˜=K˜—Kšžœ˜K˜—…—h