DIRECTORY CD, Rope; CDSymbolicObjects: CEDAR DEFINITIONS = BEGIN CreateMark: PROC [dummySize: CD.Number_0] RETURNS [CD.Object]; CreateSegment: PROC [length: CD.Number, dummyWidth: CD.Number_0] RETURNS [CD.Object]; CreatePin: PROC [size: CD.Position] RETURNS [CD.Object]; Kind: TYPE = {notSymbolic, mark, segment, pin}; SymbolicKind: PROC [ob: CD.Object] RETURNS [Kind]; IsSymbolicOb: PROC [ob: CD.Object] RETURNS [BOOL]; IsMark: PROC [ob: CD.Object] RETURNS [BOOL]; IsSegment: PROC [ob: CD.Object] RETURNS [BOOL]; IsPin: PROC [ob: CD.Object] RETURNS [BOOL]; SetOwner: PROC [symInst: CD.Instance, owner: ATOM_NIL]; GetOwner: PROC [symInst: CD.Instance] RETURNS [ATOM]; SetName: PROC [symInst: CD.Instance, name: Rope.ROPE]; GetName: PROC [symInst: CD.Instance] RETURNS [Rope.ROPE]; SetLayer: PROC [symInst: CD.Instance, layer: CD.Layer]; GetLayer: PROC [symInst: CD.Instance] RETURNS [CD.Layer]; Denotes: PROC [symInst: CD.Instance] RETURNS [CD.Rect]; DirectionOrNone: TYPE = {west, south, east, north, none}; Direction: TYPE = DirectionOrNone[west..north]; DirectionFromOrient: PROC [o: CD.Orientation] RETURNS [dir: Direction]; OrientFromDirection: PROC [dir: Direction] RETURNS [o: CD.Orientation]; CreateSymInst: PROC [name: Rope.ROPE_NIL, denotes: CD.Rect, dummySize: CD.Number _ 0, layer: CD.Layer _ CD.undefLayer, owner: ATOM _ NIL, approachFrom: Direction _ west] RETURNS [CD.Instance]; InstEnumerator: TYPE = PROC [inst: CD.Instance] RETURNS [quit: BOOL_FALSE]; EnumerateSymbolicObs: PROC [cellOb: CD.Object_NIL, eachInst: InstEnumerator] RETURNS [quit: BOOL]; FindSymbolicObs: PROC [cellOb: CD.Object_NIL, name: Rope.ROPE] RETURNS [CD.InstanceList]; pinClass: PRIVATE READONLY CD.ObjectClass; segmentClass: PRIVATE READONLY CD.ObjectClass; markClass: PRIVATE READONLY CD.ObjectClass; pinLayer: PRIVATE READONLY CD.Layer; segmentLayer: PRIVATE READONLY CD.Layer; END. >CDSymbolicObjects.mesa (part of ChipNDale) Copyright c 1984, 1985 by Xerox Corporation. All rights reserved. Created by Christian Jacobi, August 8, 1984 12:41:50 pm PDT Last edited by: Christian Jacobi, September 19, 1986 11:18:34 am PDT Symbolic objects denote points, vertical and horizontal line segments and rectangles. These objects can be used to define interfaces. Marks denote points: The object relative point [0, 0]. (The lower left point) Segments denote line segments: The object relative segment from [0, 0] to [0, size.y]. (The left border) Pins denote rectangles: The object relative rectangle [0, 0, size.x, size.y]. (All the area) The interrest rect is equal to [0, 0, size.x, size.y]; the Client origin is at [0, 0]. The unused dimensions are of no consequence for Points or Segments. Point and Segment instances therefor must map the orientation of the object to get the denoting position(s). It is perfectly ok to create instances of symbolic objects with any means, this module does not include any hidden features on these objects. It is common to have several symbolic object instances with the same name. The actual properties like name, layer, property-list and their semantics are bound to the Instance, not the object. The semantics of a symbolic object with NIL owner is not known, and no restrictions are required [or allowed!] from ChipNDale. Certain applications may demand restrictions, but can not rely on them. The owner field can be used to specify for what application an instance of a symbolic object is thought of; the owner field defines the semantics. --Create procedures --All create procedures may create objects of different genre if the parameters suggests. Symbolic objects may be shared by different instances or different designs. The dummy-dimension may be used to make the object larger than the denoting position(s); however, it is used as hint only. --Recognizing symbolic objects --Properties of instances of symbolic objects --If owner is not NIL it must be registered with CDProperties --I layer=CD.undefLayer means: not yet determined, -- or either: object has more complex functionality --It depends from the application whether the layer is meaningfull or not --The denoted area; a rect for pins, a degenerated rect for segments and marks --Direction and creation of directed instances --It depends from the application whether Direction has any meaning... --View point for directions is the cell, not the channel: Consider the left border of a cell --to be west. --returns direction where the west side of an oriented object faces --returns an orientation such that the west side of an oriented object faces dir --Creates an instance of a symbolic object. --Lines will allways be approached from a direction perpendicular to their length. --Special procedures for finding or enumerating symbolic objects in cells or (loaded) imports --Random order; changes on cellOb while the enumeration may or may not be seen --or may even cause other symbolic to be visited a different number than once. --The instances are the real instances inside cellOb; modifycations would change cellOb --Returns all symbolic objects with name "name" --The instances are the real instances inside cellOb; modifycations would change cellOb --implementors stuff --abstract layers to allow using stretch and split commands Κ9˜codešœ+™+Kšœ Οmœ7™BKšœ=™=K™DK˜—šΟk ˜ Kšžœ˜ —K˜KšΟnœžœž œ˜)šž˜K˜—šœ†™†K™—KšœM™MKšœh™hšœ]™]K™Kšœ‰™‰KšœΩ™ΩKšœu™uKšœά™άK™—K™™Kšœ’™’K˜—Kš Ÿ œžœ žœ žœžœ ˜>Kš Ÿ œžœ žœžœ žœžœ ˜Uš Ÿ œžœžœ žœžœ ˜8K˜—K™™K˜—Kšœžœ%˜/KšŸ œžœžœ žœ˜2Kš Ÿ œžœžœ žœžœ˜2Kš Ÿœžœžœ žœžœ˜,Kš Ÿ œžœžœ žœžœ˜/š Ÿœžœžœ žœžœ˜+K˜—K™™-K˜—Kš Ÿœžœ žœžœžœ˜7š Ÿœžœ žœ žœžœ˜5Kšœ=™=K˜—KšŸœžœ žœžœ˜6š Ÿœžœ žœ žœžœ˜9K˜—KšŸœžœ žœžœ˜7š Ÿœžœ žœ žœžœ˜9Kšœ3™3Kšœ4™4K™IK˜—š Ÿœžœ žœ žœžœ˜7K™NK™—K™™.K™FK™\K™ K˜—Kšœžœ$˜9šœ žœ ˜/K™—šŸœžœžœžœ˜GK™CK˜—šŸœžœžœžœ˜GK™QK˜K˜—šŸ œžœ žœžœ žœžœžœ žœžœžœ"žœžœ ˜ΐK™+K™RK˜—K™™]K˜—š œžœžœžœ žœžœžœ˜KK˜—š Ÿœžœ žœžœžœžœ˜bKšœN™NKšœO™OKšœW™WK˜—šŸœžœ žœžœ žœžœžœ˜YKšœ/™/KšœW™WK™—K˜™K˜Kšœ žœž œ ˜*Kšœžœž œ ˜.Kšœ žœž œ ˜+K˜Kšœ žœžœ˜$šœžœžœ˜(K™;—K˜—Kšžœ˜K˜—…—rι