Annotation of researchv10dc/vol2/Ped/ped.ms, revision 1.1

1.1     ! root        1: .so ../ADM/mac
        !             2: .XX 12 195 "PED \(em A Picture Editor"
        !             3: .de fC
        !             4: .sp .3v
        !             5: .B "Figure \\$1."
        !             6: ..
        !             7: .TL
        !             8: PED \(em A Picture Editor
        !             9: .br
        !            10: A User Manual
        !            11: .AU
        !            12: Theo Pavlidis
        !            13: .AI
        !            14: .MH
        !            15: .SP 2
        !            16: .2C
        !            17: .NH
        !            18: Introduction
        !            19: .PP
        !            20: \fIPed\fP is a program for creating illustrations interactively
        !            21: using the DMD5620 (Blit) terminal and the mouse.
        !            22: (A version also exists for the Sun workstation.)
        !            23: It runs under
        !            24: .ft I
        !            25: mux (mpx, layers)
        !            26: .ft
        !            27: so that you can use one window for drawing while keeping in contact
        !            28: with the world through the other windows.
        !            29: You can create simple illustration without having to read
        !            30: more than a small part of this manual
        !            31: provided that you have already some familiarity with
        !            32: .US
        !            33: and the terminal itself.
        !            34: There is on-line documentation which you can access by pressing
        !            35: button 2 of the mouse over a menu item. An expanded copy of that documentation
        !            36: is given as Appendix A and you can consult it anytime you wish
        !            37: to find out the meaning of a particular menu selection.
        !            38: Section 3 describes how to produce
        !            39: hard copies from
        !            40: .I ped.
        !            41: Part of
        !            42: .I ped
        !            43: runs on the host machine and part on the terminal. Small drawings are
        !            44: handled only by the terminal part but large drawings are kept on the host
        !            45: and only parts of them are brought in the terminal for editing.
        !            46: Figure 1 should give you an idea of what you can draw with
        !            47: .I ped .
        !            48: .1C
        !            49: .KF bottom
        !            50: .BB
        !            51: .so dragon.so
        !            52: .fC 1
        !            53: An example of an illustration produced using \fIped\fP.
        !            54: (Drawn by Paul Pavlidis.)
        !            55: .KE
        !            56: .2C
        !            57: .PP
        !            58: \fIPed\fP is part of Research
        !            59: .UX
        !            60: but it is also
        !            61: available in many installations running System V or BSD
        !            62: .UX
        !            63: systems.
        !            64: While it is was written originally for terminals with 256K
        !            65: of memory its size has increased since then and there may
        !            66: be problems in running the current version on such terminals.
        !            67: .PP
        !            68: While you draw on the bitmap of the terminal with the mouse
        !            69: .I ped
        !            70: maintains the information not as a copy of the bitmap but as
        !            71: a list of points. This makes scaling easy so that
        !            72: drawings produced by
        !            73: .I ped
        !            74: can be displayed on devices of different resolution.
        !            75: (Thus while the image includes filled areas,
        !            76: lines, and curves, \fIped\fP knows only about points.
        !            77: As a matter of fact its name stands for \f(CWP\fPoint \f(CWED\fPitor.)
        !            78: \fIPed\fP files are in ASCII and therefore can be edited using
        !            79: text editors, although this is not a recommended procedure.
        !            80: Whenever
        !            81: \fIped\fP
        !            82: exits (or is asked to edit a new file), it checks whether the file
        !            83: has been modified since a previous save, and if it has it writes in
        !            84: .CW ped.save .
        !            85: Error messages (if any) are saved in a file called
        !            86: .CW .pederr
        !            87: in the user's current directory.
        !            88: .PP
        !            89: While 
        !            90: .I ped
        !            91: is a currently available program, I consider it only as a first step
        !            92: towards the development of a tool that would be as convenient to
        !            93: use as writing and drawing on paper.
        !            94: I would like to call such a facility
        !            95: .ft I
        !            96: electronic paper
        !            97: .ft
        !            98: and it is a concept that goes in the opposite direction from picture
        !            99: description languages (such as \fIpic\fP|reference(latest pic)) or constraint systems
        !           100: (such as \fIideal\fP|reference(latest ideal) or Xerox PARC's \fIjuno\fP).
        !           101: The hope is that future versions of
        !           102: .I ped
        !           103: will provide more options without increasing the size of the menu or
        !           104: the documentation.
        !           105: See Section 5 (Beautification) for more on this topic.
        !           106: .NH
        !           107: Organization of PED
        !           108: .NH 2
        !           109: Points, Objects, and Families
        !           110: .PP
        !           111: The basic unit or data structure
        !           112: .I ped
        !           113: is the
        !           114: ``object.''
        !           115: As a rule objects appear as connected polygonal lines,
        !           116: splines, circles, or blocks of text.
        !           117: (See Appendix B for a formal definition of objects.)
        !           118: Internally they consist (usually) of a set of points
        !           119: and a ``type'' flag which determines how
        !           120: the plotting routines will
        !           121: use the points to produced various shapes.
        !           122: .ft I
        !           123: An important consequence
        !           124: is that you must address objects on the screen
        !           125: by pointing at their points rather than at sides or the interior
        !           126: of polygons.
        !           127: .ft
        !           128: .PP
        !           129: We could have added code to
        !           130: .I ped
        !           131: that would relax the above requirement so that people could
        !           132: address polygons by pointing to
        !           133: their interior, etc. We did not do so for two reasons.
        !           134: One is that such code would increase the size of the program
        !           135: and the time of interaction in a nontrivial way. Since users
        !           136: adapted to the current mode quickly we felt that the slow
        !           137: down caused by the new code would not be justified.
        !           138: A second reason is that addressing the
        !           139: interior of polygons would not be a useful action in a cluttered drawing.
        !           140: .PP
        !           141: Objects can become
        !           142: associated in a ``family'' without changing their external
        !           143: appearance. We describe later the menu selections that can do that.
        !           144: When you touch a point
        !           145: .I ped
        !           146: also knows about the object that the points belongs to and,
        !           147: if appropriate, an action is applied to the whole object.
        !           148: If that object is a member of a family, then the action is applied
        !           149: to the whole family.
        !           150: .NH 2
        !           151: The Menus
        !           152: .PP
        !           153: .I Ped
        !           154: displays a menu on the left side of the window. That menu may be changed
        !           155: by selecting from a ``pop up'' menu with button 3 of the mouse. The following
        !           156: selections are possible.
        !           157: .IP "\f(CWbasic\fP: "
        !           158: This is the active menu in the beginning and includes commands for
        !           159: file manipulation, changing the type of display, etc.
        !           160: (See Figure 1.)
        !           161: .IP "\f(CWch size\fP: "
        !           162: Commands that change the size of what has been drawn.
        !           163: Also transformations such as rotation.
        !           164: .IP "\f(CWmove\fP: "
        !           165: Commands that delete, copy, do parallel translations
        !           166: (move) objects, etc. Also commands that break objects in parts or join
        !           167: objects to form new ones.
        !           168: .IP "\f(CWdraw\fP: "
        !           169: Set up a grid, draw lines, text labels, circles, boxes, etc.
        !           170: Also make a family out of a group of objects.
        !           171: .IP "\f(CWreshape\fP: "
        !           172: Convert a polygon into a spline, adjust the position of points, 
        !           173: dissolve a family of objects, or restore it, etc.
        !           174: (See Figure 2.)
        !           175: .IP "\f(CWrefine\fP: "
        !           176: Edit text, line form (dashed, solid, double, etc.), change point size, etc.
        !           177: .IP "\f(CWshade\fP: "
        !           178: Fill polygons or splines with texture or unfill them.
        !           179: .IP "\f(CWcolor\fP: "
        !           180: Assign a color to objects. This has no visible effect on the DMD 5620
        !           181: but the color label may be used by other devices.
        !           182: .IP "\f(CWremote\fP: "
        !           183: Commands to perform editing on the host.
        !           184: .1C
        !           185: .KF
        !           186: .BB
        !           187: .so mvpoint.so
        !           188: .fC 2
        !           189: The screen of the DMD 5620 when \fIreshape\fP has been
        !           190: selected from the pop up menu by button 3 of the mouse
        !           191: and then \fImv point\fP from the left side menu by button 1.
        !           192: .KE
        !           193: .2C
        !           194: .PP
        !           195: As a rule, the program remembers the last command given and will
        !           196: execute it repeatedly, as long as it is meaningful to do so
        !           197: or until the user makes another selection.
        !           198: Thus one can fill many polygons with the same texture without
        !           199: having to select it each time. In this case the mouse cursor
        !           200: has the form of the texture. In other menus
        !           201: the effective command is shown in reverse video.
        !           202: .NH 2
        !           203: The Mouse Buttons
        !           204: .PP
        !           205: Button 1 is the ``creative'' or ``start'' button. It is used to select
        !           206: actions from the menu displayed on the left hand side, to draw
        !           207: or edit objects, and, in general,
        !           208: pretty much as pencil could be used to draw or point
        !           209: to things.
        !           210: .PP
        !           211: Button 3 is the ``terminating'' button. When pressed it stops drawing
        !           212: or editing, or it may cancel some commands. It is also used to
        !           213: change the menu on the left.
        !           214: .PP
        !           215: Button 2 is the ``panic'' button. When pressed over a menu item,
        !           216: it causes the display of documentation. When pressed elsewhere,
        !           217: it cause the
        !           218: .I basic
        !           219: menu to be displayed on the left.
        !           220: .PP
        !           221: Typing text disables the mouse so
        !           222: that you cannot exit from that mode by pressing button 3.
        !           223: However, hitting RETURN twice will take you out.
        !           224: .NH 2
        !           225: Files
        !           226: .PP
        !           227: When a file is first read it is kept on the host.
        !           228: It requires user action to bring it to the terminal so that
        !           229: it can be edited (``bring in'' item on the ``basic'' menu).
        !           230: ``View host'' lets you display the complete picture
        !           231: that is the file and is now kept in the host; no data are kept in the terminal
        !           232: part and therefore you cannot edit the file (except by the ``remote''
        !           233: menu commands.)
        !           234: Since large figures will not usually fit in the terminal, you
        !           235: must display them (scaled down) first with the ``view host'' command and
        !           236: then select a part with a window controlled by button 1.
        !           237: After selecting ``bring in'' from
        !           238: a menu the black square cursor appears. Clicking button 1
        !           239: fixes the top left corner, clicking button 1 a second time fixes the
        !           240: bottom right corner of a rectangle.
        !           241: (Note that this is different from the way that windows are controlled
        !           242: under the multiplexing program
        !           243: with button 3.)
        !           244: Any objects found within that rectangle
        !           245: are brought in and displayed on the terminal,
        !           246: and at a bigger scale. Then they can be edited.
        !           247: .PP
        !           248: A unique feature of
        !           249: .I ped
        !           250: is that you may read a file into a particular part of
        !           251: the screen (``read'' command in the ``remote'' menu), or write a
        !           252: part of the screen into a file (``write'' command in the ``remote'' menu).
        !           253: .NH
        !           254: Hard Copy
        !           255: .PP
        !           256: There are two ways to make hard copy of the pictures you draw,
        !           257: either by copying bitmaps from the 5620 screen or by expanding
        !           258: the
        !           259: .I ped
        !           260: files by the
        !           261: .I troff
        !           262: preprocessor
        !           263: .I tped.
        !           264: .NH 2
        !           265: Bitmaps
        !           266: .PP
        !           267: You can get bitmaps by selecting ``blitblt'' from the basic menu (see Figure 1)
        !           268: and then sweeping a rectangular area from the screen.
        !           269: This action will
        !           270: create a file called BLITBLT which is a run length encoded
        !           271: copy of the bitmap. Of course, you can run the
        !           272: .US
        !           273: .I blitblt
        !           274: command from another window if you wish with the same result.
        !           275: If the rectangle has size zero (or nearly so) or button 3 is pressed,
        !           276: then a copy of the whole drawing are is made.
        !           277: The BLITBLT file can be printed on the Gnot
        !           278: printers with the \fIgbcan\fP command or included in \fItroff\fP
        !           279: files by using the \fImbits\fP macros.
        !           280: (This is how all the pictures of the ped screen in this document were made.)
        !           281: The action of the library macro BM depends on the number of its arguments.
        !           282: The
        !           283: .CW .bM
        !           284: macro defined below can be used either as
        !           285: .P1
        !           286: \&.bM fname
        !           287: .P2
        !           288: to print the bitmap of file \fIfname\fP with default setting of dot size (6)
        !           289: or as
        !           290: .P1
        !           291: \&.bM number fname
        !           292: .P2
        !           293: to print with dot size \fI number\fP.
        !           294: .P1
        !           295: \&.de bM
        !           296: \&.sp
        !           297: \&.ie \e\en(.$=1 .BM \e\e$1 6 dX dY
        !           298: \&.el .BM \e\e$2 \e\e$1 dX dY
        !           299: \&.br
        !           300: \&.ne \e\en(dYu
        !           301: \&.in (\e\en(.lu-\e\en(dXu)/2u
        !           302: \&.ie \e\en(.$=1 .BM \e\e$1 6
        !           303: \&.el .BM \e\e$2 \e\e$1
        !           304: \&.in
        !           305: \&.rs
        !           306: \&.sp \e\en(dYu
        !           307: \&..
        !           308: .P2
        !           309: .NH 2
        !           310: Tped
        !           311: .PP
        !           312: This program works like other
        !           313: \fItroff\fP preprocessors with the following specifications.
        !           314: It is run as
        !           315: .P1
        !           316: tped \fIfiles\fP ... | troff \fIoptions\fP
        !           317: .P2
        !           318: The various files can be \fIped\fP files without any modifications.
        !           319: Or they may be \fItroff\fP input files
        !           320: including \fIped\fP files in one of the following ways.
        !           321: .IP (a)
        !           322: The \fIped\fP file is embedded in the \fItroff\fP file
        !           323: between
        !           324: .P1
        !           325: \&.GS
        !           326: \&.....
        !           327: ped file contents
        !           328: \&.....
        !           329: \&.GE
        !           330: .P2
        !           331: .IP (b)
        !           332: The name of the \fIped\fP file is given as argument as in
        !           333: .P1
        !           334: \&.GS file_name
        !           335: .P2
        !           336: .PP
        !           337: .I tped
        !           338: recognizes the following flags:
        !           339: .IP \f(CW-b\fP 6n
        !           340: place a box around each illustration.
        !           341: .IP \f(CW-c\fP
        !           342: produce expanded output.
        !           343: .IP \f(CW-Ta\fP
        !           344: assume that final output will be done in
        !           345: the \fIaps\fP phototypesetter.
        !           346: .IP \f(CW-Td\fP
        !           347: assume final output on the Mergenthaler
        !           348: or the Gnot printers (default).
        !           349: .IP \f(CW-m\fP
        !           350: if used after a set of file names, it causes \fItped\fR
        !           351: to read from the standard input after reading the files.
        !           352: .IP \f(CW-s\fP
        !           353: scale the letter point size.
        !           354: .PP
        !           355: Two of these flags require special discussion.
        !           356: When
        !           357: .I tped
        !           358: expands the
        !           359: .I ped
        !           360: files it can do in one of two ways. It may produce a series of dots
        !           361: that form the lines, textured areas, etc. or it may simply pass on
        !           362: the object description with slight modifications only. Then the
        !           363: plotting is done by the
        !           364: .I troff
        !           365: postprocessor.
        !           366: Plots obtained in this way are of better quality than plots when
        !           367: the expansion is done before
        !           368: .I troff.
        !           369: However the postprocessors must know about
        !           370: .I ped
        !           371: so that version is less portable. (See Appendix C.)
        !           372: The
        !           373: .CW -c
        !           374: flag allows the user to select either option.
        !           375: .PP
        !           376: In addition to the above, it is possible to change parameters
        !           377: with arguments supplied with the
        !           378: .CW .GS
        !           379: line. The following options exist:
        !           380: .KS
        !           381: .TS
        !           382: center;
        !           383: cFCW l.
        !           384: h=\fInumber\fP Make drawing height \fInumber\fP inches.
        !           385: w=\fInumber\fP Make drawing width \fInumber\fP inches.
        !           386: -C     Center drawing on page (default).
        !           387: -L     Left adjust drawing.
        !           388: -R     Right adjust drawing.
        !           389: -s     Toggle scaling of text.
        !           390: .TE
        !           391: .KE
        !           392: The adjustment options can be used to print
        !           393: .I ped
        !           394: drawings side by side as the following example illustrates.
        !           395: .P1
        !           396: \&.sp
        !           397: \&.ne 4i
        !           398: \&.sp
        !           399: \&.mk
        !           400: \&.GS \-L left_part
        !           401: \&.sp
        !           402: \&.rt
        !           403: \&.GS \-R right_part
        !           404: \&.sp
        !           405: .P2
        !           406: The above arrangement assumes that both parts have the same dimensions.
        !           407: If not, similar heigh may be forced with the \f(CWh=number\fP option.
        !           408: .NH
        !           409: Special Features
        !           410: .PP
        !           411: All the features of
        !           412: .I ped
        !           413: are documented systematically in Appendix A. We review here only
        !           414: those that we felt they needed a more detailed explanation.
        !           415: .NH 2
        !           416: Markers
        !           417: .PP
        !           418: Sometimes it is not easy to identify the points of an object
        !           419: and for this reason \fIped\fP provides the ``markers'' selection
        !           420: in its ``basic'' menu. If you select that option, then various auxiliary lines
        !           421: and points appear on the screen. In particular, a ``bullet''
        !           422: is used to identify one point on each object,
        !           423: dotted lines connect objects belonging to the same family,
        !           424: and a simplified drawing is used for some
        !           425: of the fancier objects. 
        !           426: The use of markers is recommended during preparation
        !           427: of an illustration and you should turn them off only when
        !           428: you want to see how your finished product will look.
        !           429: For example, a text label can be addressed only by placing
        !           430: the mouse at the particular point associated with the label.
        !           431: That point is not visible unless the markers are on.
        !           432: .NH 2
        !           433: Text
        !           434: .PP
        !           435: Text can be included by selecting ``text''
        !           436: in the ``draw'' menu and then typing it. Text labels
        !           437: consisting of many lines. To terminate text entry type an
        !           438: empty line. When text is entered at first it appears as
        !           439: left adjusted. The ``refine'' menu has a command that lets you
        !           440: make text centered or right adjusted. In addition you can edit
        !           441: text by using the command ``edit text'' in the ``refine''
        !           442: menu. The selected text appears at the top area of the screen.
        !           443: Click button 1 over the spot you wish to change.
        !           444: Use back space to erase and type new characters to replace
        !           445: or insert. Hitting return
        !           446: completes the correction at the selected spot.
        !           447: You may make more corrections if you wish
        !           448: by selecting another spot on the label. Otherwise you hit button 3
        !           449: to indicate that text editing is over.
        !           450: .PP
        !           451: It is not possible to edit in
        !           452: .I ped
        !           453: labels that are too long to fit in the top area of the window
        !           454: (over 80 characters for windows that take the full width of the terminal).
        !           455: This is perhaps the only instance that a
        !           456: .I ped
        !           457: file must be edited with a text editor.
        !           458: .PP
        !           459: Text is normally entered in point size 10, but the ``psize''
        !           460: lets specify another size.
        !           461: All new text entered from then on will be in the selected point size.
        !           462: The commands ``expand'' and ``shrink'' of the ``ch size'' menu
        !           463: result in a change of the point size when applied to text.
        !           464: .NH 2
        !           465: Splines
        !           466: .PP
        !           467: The splines used in
        !           468: .I ped
        !           469: consist of parabolic arcs tangent to a polygon drawn by the user.
        !           470: They are the same splines that
        !           471: .I pic
        !           472: uses and they are discussed in detail in |reference(pavlidis image processing).
        !           473: .PP
        !           474: Splines pass through the vertex of the polygon only if that vertex
        !           475: is made a ``corner'' by the ``reshape'' menu selection.
        !           476: The first and last points of an open polygon are made by default into
        !           477: corners when it is converted into a spline.
        !           478: If you wish interpolating splines you must use the command ``isplin''
        !           479: in the ``refine'' menu. In order to let the user have access to the
        !           480: original points the type of the figure is not changed: it is a polygon
        !           481: but it is drawn as a spline.
        !           482: .NH 2
        !           483: Line Forms
        !           484: .PP
        !           485: Polygons or splines may be drawn either by solid or dashed lines
        !           486: in different thickness as specified by the line point size.
        !           487: In addition polygons may use double lines, heavy lines, and interpolating
        !           488: splines (see above). The last three forms require
        !           489: floating point arithmetic so they are not displayed in local
        !           490: mode but only when you do a ``view host.'' (In local mode the
        !           491: sides are marked with a symbol.) Such fleeting drawings forms may
        !           492: be fixed so that the objects appear in tha form even in local mode.
        !           493: However in this case the original points are lost. See Figure 3
        !           494: for an example.
        !           495: .1C
        !           496: .KF
        !           497: .GS h=2 fig1
        !           498: .fC 3
        !           499: The figure displays the original polygon,
        !           500: the interpolating spline, and the guiding polygon for the latter.
        !           501: The ``fix'' command replaces the original polygons by the guiding
        !           502: polygon.
        !           503: .KE
        !           504: .2C
        !           505: .NH 2
        !           506: Families and Links
        !           507: .PP
        !           508: Objects may be associated in a ``family''
        !           509: so that they can be moved around or scaled as a group.
        !           510: The ``draw'' menu has a command ``family/bx.'' When you select it
        !           511: a sweeping rectangle becomes available and any objects enclosed
        !           512: by it become members of the same family. If markers are on,
        !           513: .I ped
        !           514: places dotted lines connecting objects of the same family.
        !           515: .PP
        !           516: Families are groups of objects that have nothing in common
        !           517: except that
        !           518: .I ped
        !           519: thinks of them as a single object. They can have
        !           520: different types and a family may be
        !           521: a member of another family.
        !           522: On the other hand
        !           523: linked objects must be of the same kind: all open polygons,
        !           524: or all closed splines, etc.
        !           525: .PP
        !           526: When objects are linked
        !           527: the visual appearance of the sketch does not change.
        !           528: This is similar to a family but the
        !           529: link is far stronger and the ``dissolve'' command has no effect.
        !           530: On the other hand linked objects can be edited the same way
        !           531: as simple objects.
        !           532: .ft I
        !           533: Warning: \fRPed\fP provides no visible connection between linked objects.
        !           534: Link should be used only between objects that are obviously related.
        !           535: .ft
        !           536: Indeed, the command was introduced with the following two
        !           537: applications in mind. (a) To prepare filled
        !           538: polygons that have holes in them.
        !           539: (In this case ``link'' should be followed immediately by a shading command.)
        !           540: (b) To
        !           541: create a single object after the ``match'' instruction has been
        !           542: applied.
        !           543: In this way a T-shaped figure (or a tree) could become a single object.
        !           544: The ``break'' operation has special effects on linked objects.
        !           545: It simply removes the first link it encounters and breaks the polygon
        !           546: into two. At least one of them has no links at all.
        !           547: .I Ped
        !           548: actually refuses to link splines, but you can defeat that restriction by
        !           549: linking first, and then converting into a spline.
        !           550: Application of ``join'' to an open polygon with links converts all
        !           551: its contours into closed polygons.
        !           552: .PP
        !           553: Users should keep in mind that the ``remote'' menu allows operations
        !           554: on groups of objects so there is no need to make the whole drawing
        !           555: a family in order to apply an operation on all the objects.
        !           556: .NH 2
        !           557: Planning and Clutter
        !           558: .PP
        !           559: A major difference between drawing on paper and
        !           560: drawing by electronic means is that you do not have to worry about the
        !           561: composition until you are ready to do so.
        !           562: Components of the illustration can and should be drawn separatedly
        !           563: and pulled together only at the end. Large drawings may be in separate files
        !           564: and be composed through the ``read'' command of the ``remote''
        !           565: menu. The ``match'' and ``center'' commands of the ``move'' menu
        !           566: allow fine positioning adjustments.
        !           567: .PP
        !           568: Temporary moves are useful for reducing clutter.
        !           569: If you select ``mv obj'' and then press button 3 (or 2)
        !           570: the object is left in the chosen position only temporarily.
        !           571: Next time you return to the basic menu, all such objects
        !           572: resume their original positions.
        !           573: .NH 2
        !           574: Equations
        !           575: .PP
        !           576: Mathematical equations can be included in \fIped\fP drawings by
        !           577: typing
        !           578: .I eqn
        !           579: commands between delimiters (e.g.
        !           580: .CW $$ )
        !           581: as text
        !           582: and then piping the output of
        !           583: .I tped
        !           584: through
        !           585: .I eqn.
        !           586: Since the form of displayed labels is different than those
        !           587: of the final output some experimentation is needed to
        !           588: achieve the desired positioning.
        !           589: .NH
        !           590: Beautification
        !           591: .PP
        !           592: A good draftsman is able to take a rough sketch and convert it into
        !           593: a ``neat'' drawing. It is desirable to have similar facilities
        !           594: in the graphics editor.
        !           595: The menu selection
        !           596: ``formal'' (in the ``reshape'' and the ``remote'' menus) will
        !           597: transform an object or group of objects so that lines that are
        !           598: nearly parallel become parallel, lengths that are
        !           599: nearly equal become equal, etc.
        !           600: The algorithm used for the transformation is described in detail
        !           601: in |reference(pavlidis van wyk beautifier).
        !           602: .1C
        !           603: .KF bottom
        !           604: .BB
        !           605: .so nice.so
        !           606: .fC 4
        !           607: A drawing before and after beautification.
        !           608: .KE
        !           609: .2C
        !           610: .PP
        !           611: Beautification can reduce the need for long menus. Suppose we want
        !           612: to draw a line tangent to a circle. We could add a menu option
        !           613: that would draw a tangent from a point to a circle but we could also
        !           614: leave the problem to the beautifier. You would draw a circle
        !           615: and a line approximating the tangent and then pass these to
        !           616: objects to the beautifier. Nearly tangent can be detected by
        !           617: finding that the distance of the center of the circle from
        !           618: the line is nearly equal to the radius. Then a system of
        !           619: equations and inequalities
        !           620: can be solved to find new objects that are mutually tangent
        !           621: and close to the original objects. The same routines could
        !           622: be generalized to handle the problem of having a line (or lines)
        !           623: tangent to any number of circles, without having to add any more
        !           624: menu instructions.
        !           625: .PP
        !           626: .I Ped
        !           627: is still very far from replacing a good draftsman and it is highly
        !           628: unlikely that it ever will. But it is likely that more
        !           629: features will be added to the beautification transformation.
        !           630: .NH
        !           631: User Operations
        !           632: .PP
        !           633: There is a mechanism for executing
        !           634: .UX
        !           635: commands and incorporating their output in the drawing.
        !           636: A command may be typed in advance (while in the command typing mode) or
        !           637: it may be typed at the time of its invocation.
        !           638: There are two menus offering a ``user oper'' selection:
        !           639: ``draw'' and ``refine.'' In the former you need select only
        !           640: a point on the screen before applying the command.\(dg
        !           641: .FS
        !           642: \(dg The current implementation also expects typing of the command
        !           643: at that moment.
        !           644: .FE
        !           645: In the latter you must select an object as well.
        !           646: If there is no previously defined command you are prompted
        !           647: for it.
        !           648: The following rules are applicable.
        !           649: .PP
        !           650: If the object type is text, then the text is itself is supplied as
        !           651: input to the
        !           652: .UX
        !           653: command. the output is collected as text and replaces
        !           654: the original.
        !           655: .PP
        !           656: If the object type is polygon or spline the two coordinates of each point
        !           657: are supplied to the
        !           658: .UX
        !           659: program, one point per line.
        !           660: The string
        !           661: .CW 1e6
        !           662: is appended as end-of-file indicator.
        !           663: .PP
        !           664: If the object type is family, then the whole object is provided
        !           665: to the command using
        !           666: .I ped
        !           667: format.
        !           668: .PP
        !           669: Often the command is
        !           670: \f(CWa.out\fP,
        !           671: a program written by the user for transforming geometric figures.
        !           672: Text processing commands such as
        !           673: .DS
        !           674: .ft CW
        !           675: tr "[a-z]" "[A-Z]"
        !           676: .ft
        !           677: .DE
        !           678: are also common.
        !           679: Finally, the ``user oper'' command may used in order to include
        !           680: the output of commands such as
        !           681: .I date
        !           682: as part of illustrations prepared by
        !           683: .I ped.
        !           684: The inclusion of the output of programs that produce complex
        !           685: illustrations is best done by having them output
        !           686: their results in
        !           687: .I ped
        !           688: format. (See Appendix B.)
        !           689: .SH
        !           690: Acknowledgments
        !           691: .PP
        !           692: Many people provided considerable input for
        !           693: .I ped,
        !           694: especially its early users and those porting it to new machines.
        !           695: Early users include amongst others Paul Pavlidis, Mary Bittrich,
        !           696: Doug McIlroy, Bob Hutchison, John Cregar, and Sandy Fraser.
        !           697: Bob Hutchison and Jon Sauer contributed significantly
        !           698: to the porting of the program to
        !           699: .UX
        !           700: V and other
        !           701: output devices. Janet Lee wrote the online documentation
        !           702: and also contributed to the porting on 3B machines.
        !           703: .PP
        !           704: The following people either provided parts of the software
        !           705: or let me use their code as prototype:
        !           706: Ken Thompson (routines for creating the double lined objects),
        !           707: Tom Killian (``blitblt'' routines),
        !           708: Tom Szymanski (high level communications protocol),
        !           709: and Tom Cargill (menu design).
        !           710: George Wolberg helped with the implementation of many of the routines
        !           711: in an early version of the program.
        !           712: .PP
        !           713: Lorinda Cherry, Steve Mahaney, and Doug McIlroy made many useful comments on
        !           714: various versions of the documents describing the use and
        !           715: organization of
        !           716: .I ped.
        !           717: .SH
        !           718: References
        !           719: .LP
        !           720: |reference_placement
        !           721: .de hD
        !           722: .ft CW
        !           723: .sp 0.5
        !           724: .NE 1i
        !           725: ..
        !           726: .SH
        !           727: Appendix A: Command Actions
        !           728: .PP
        !           729: The following is a slightly expanded version of the online documentation
        !           730: which becomes available when you press button 2 over
        !           731: a menu selection. It is based on documentation written by Janet Lee.
        !           732: .hD
        !           733: basic
        !           734: .LP
        !           735: Collection of commands that manipulate files and/or groups
        !           736: of objects.
        !           737: .RS
        !           738: .hD
        !           739: type comm
        !           740: .LP
        !           741: Enable the keyboard for file manipulation and
        !           742: .UX
        !           743: commands.
        !           744: Commands are:
        !           745: .CW "w filename"
        !           746: (write to a file),
        !           747: .CW "r filename"
        !           748: (read
        !           749: from a file),
        !           750: .CW "e filename"
        !           751: (edit a file),
        !           752: .CW f
        !           753: (print current file),
        !           754: .CW "u string"
        !           755: (execute `string' as a
        !           756: .UX
        !           757: command when ``user oper'' is
        !           758: selected in the ``refine'' menu),
        !           759: .CW pwd
        !           760: and
        !           761: .CW cd
        !           762: (execute the
        !           763: .UX
        !           764: commands),
        !           765: .CW qq
        !           766: (exit PED) and
        !           767: .CW m
        !           768: (revive the mouse). The mouse is also revived
        !           769: by a newline, or pressing any button.
        !           770: .hD
        !           771: view host
        !           772: .LP
        !           773: Display the file stored on the host machine and make it available
        !           774: for remote editing. The display is made in STORE mode so you
        !           775: can see how the picture would look when printed by the tped|troff
        !           776: combination. Also filled splines, double lines, and other fancy
        !           777: features of PED are shown correctly.
        !           778: When selecting ``view host'' while there is already a display,
        !           779: you can specify the portion of the drawing to be viewed by drawing
        !           780: a rectangle using button one.
        !           781: Buttons two and three cancel the view host.
        !           782: .hD
        !           783: bring in
        !           784: .LP
        !           785: Bring the file into the DMD terminal for local editing.
        !           786: If there is no display the whole file is brought in. Otherwise
        !           787: a sweep rectangle is made available for selecting the portion
        !           788: to be brought in. If the sweep rectangle is too small, the
        !           789: entire file is brought in.
        !           790: .hD
        !           791: markers(t)
        !           792: .LP
        !           793: Mark with black ``bullets'' the first point of each object.
        !           794: Also display the control polygons of splines and show dashed
        !           795: lines
        !           796: connecting the members of each family. It is a good idea to
        !           797: have the markers on when working on a file.
        !           798: The command is a toggle; selecting ``markers'' again erases the
        !           799: markers.
        !           800: .hD
        !           801: HELP/plot
        !           802: .LP
        !           803: Display a summary documentation of PED and then redraw the
        !           804: display of objects.
        !           805: .hD
        !           806: zoom
        !           807: .LP
        !           808: Display a closeup of the image. The apparent size is
        !           809: increased by 1/8. The actual size of the picture is unchanged.
        !           810: .hD
        !           811: unzoom
        !           812: .LP
        !           813: The apparent size of the image is decreased by 1/8.
        !           814: The actual size of  picture is unchanged.
        !           815: .hD
        !           816: scroll
        !           817: .LP
        !           818: Scrolls the image on the screen.  A line is drawn from the center
        !           819: of the screen. Any button selects the terminating point of the
        !           820: line which becomes the new center of the screen. The entire
        !           821: drawing is shifted to accommodate the new center.
        !           822: .hD
        !           823: size?
        !           824: .LP
        !           825: A sweep rectangle becomes available. After sweeping an area of the
        !           826: screen PED prints the size of that area in inches when the drawing
        !           827: is printed by tped|troff.
        !           828: If the rectangle size is too small, it prints the
        !           829: size of the whole drawing area.
        !           830: .hD
        !           831: blitblt
        !           832: .LP
        !           833: Creates a bit map of the image in the file BLITBLT in your current
        !           834: directory. This can be printed on other devices by appropriate
        !           835: commands. For the Gnot printer the command is
        !           836: .I gbcan .
        !           837: .hD
        !           838: exit
        !           839: .LP
        !           840: Exit PED program. If your file has been modified since the
        !           841: last write it is saved in a file called
        !           842: .CW ped.save
        !           843: in the current
        !           844: directory. PED plays it safe so that if it is not sure
        !           845: whether a file has been modified it will save it anyway.
        !           846: Errors, if any are in
        !           847: .CW .pederr .
        !           848: .RE
        !           849: .hD
        !           850: ch size
        !           851: .LP
        !           852: Commands that scale or apply simple geometrical transformations
        !           853: to the drawing. Mot of them are executed on the host because of
        !           854: the need for floating point.
        !           855: .RS
        !           856: .hD
        !           857: expand
        !           858: .LP
        !           859: Increases the size of an object by a factor of 1.25.
        !           860: Click button one over the object to be expanded.
        !           861: .hD
        !           862: shrink
        !           863: .LP
        !           864: Reduces the size of an object by a factor of 0.8.
        !           865: Click button one over the object to be shrunk.
        !           866: .hD
        !           867: rotate
        !           868: .LP
        !           869: Select an object with button one. This produces a circle around
        !           870: the object and a line drawn from the circle.  Selecting a point
        !           871: on the circle with button one rotates the object to this point.
        !           872: Selecting a point on the axis that is not on the circle expands
        !           873: or shrinks the object with the rotation.
        !           874: If the point is selected on the center of the circle, then a 90
        !           875: degree rotation is made.
        !           876: Pressing button three terminates the command.
        !           877: .hD
        !           878: turn 45
        !           879: .LP
        !           880: Select an object with button one and the object rotates 45 degrees.
        !           881: .hD
        !           882: v-flip
        !           883: .LP
        !           884: Select an object with button one and the object is flipped
        !           885: vertically.
        !           886: .hD
        !           887: h-flip
        !           888: .LP
        !           889: Select an object with button one and the object is flipped
        !           890: horizontally.
        !           891: .hD
        !           892: v-elong
        !           893: .LP
        !           894: Select and object with button one and the object is elongated
        !           895: vertically.
        !           896: .hD
        !           897: h-elong
        !           898: .LP
        !           899: Select and object with button one and the object is elongated
        !           900: horizontally.
        !           901: .hD
        !           902: undorot
        !           903: .LP
        !           904: Select an object with button one to undo a previous rotation.
        !           905: Undorot must be used immediately after the rotation command
        !           906: and for the same object.
        !           907: .RE
        !           908: .br
        !           909: .ne 2i
        !           910: .hD
        !           911: move
        !           912: .LP
        !           913: Commands for manipulating and moving around objects
        !           914: .RS
        !           915: .hD
        !           916: del obj
        !           917: .LP
        !           918: Delete the object selected. Clicking button one over any object
        !           919: removes the object and replaces it with a skull and crossbones
        !           920: symbol. Pressing button three completes the delete, any other
        !           921: button cancels it.
        !           922: .hD
        !           923: copy obj
        !           924: .LP
        !           925: Copies the object selected.  Click button one over the
        !           926: object to be copied.  An image of the object appears.
        !           927: Move the image using the mouse to the desired location
        !           928: and press button one to complete the copy. Pressing button
        !           929: two or three cancels the copy.
        !           930: .hD
        !           931: mv obj
        !           932: .LP
        !           933: Move the selected object. Click button one over the object and
        !           934: an image of the object appears.  Move the image using the mouse
        !           935: and click button one to complete the move when the object appears
        !           936: in the desired location. Clicking button 2 or 3 cancels the move
        !           937: but it leaves the object in the new location until one returns
        !           938: to the basic menu. This operation is useful for unscrambling
        !           939: temporarily crowded areas of the drawing.
        !           940: .hD
        !           941: brk obj
        !           942: .LP
        !           943: Used to remove sides of polygons or destroy links.
        !           944: Click button one over the first point and then select the
        !           945: second point.  The line between them is removed.
        !           946: If the polygon is not connected then the first application
        !           947: of the command will make two objects out of the commands
        !           948: rather than remove any side.
        !           949: .hD
        !           950: attach
        !           951: .LP
        !           952: It merges two open polygons by moving the second so that
        !           953: the two selected points coincide. The command fails if either
        !           954: of the selected points is not an endpoint. The two points
        !           955: are selected with button one. Using any other button
        !           956: between the two point selections cancels the attachment.
        !           957: .hD
        !           958: join
        !           959: .LP
        !           960: It merges two open polygons by drawing a line between the
        !           961: two selected points without moving anything. The command fails
        !           962: if either of the selected points is not an endpoint.
        !           963: The two points are selected with button one.
        !           964: Using any other button between the two point selections
        !           965: cancels the attachment.
        !           966: .hD
        !           967: link obj
        !           968: .LP
        !           969: Select a polygon using button one.  Any polygon selected
        !           970: afterwards with button one is linked to the first polygon
        !           971: (i.e. the objects become one object).  You can link any number
        !           972: of polygons together.  Terminate the command by pressing button
        !           973: two or three. The polygons may be open or closed but all of
        !           974: them must be the same kind (open or closed). The main use
        !           975: of the command is to prepare contours for filled objects
        !           976: with holes.
        !           977: .hD
        !           978: match
        !           979: .LP
        !           980: Select an object with button one.  Then select any number of 
        !           981: objects with button one and the touched points will coincide.
        !           982: Pressing any button other than button one terminates the command.
        !           983: The objects remain separate.
        !           984: .hD
        !           985: center
        !           986: .LP
        !           987: Select an object with button one. Then select any number of
        !           988: objects with button one.  The objects are moved so their
        !           989: centers coincide (the first object selected dictates which
        !           990: object to center on). Pressing button two or three terminates 
        !           991: the command.
        !           992: .hD
        !           993: family/pt
        !           994: .LP
        !           995: Define a family by selecting points of different objects
        !           996: with button one.  The family connections can be viewed
        !           997: using the  markers option (basic menu). When families are
        !           998: formed in this way, their objects are plotted in the order
        !           999: by which they were placed in the family. Therefore one can
        !          1000: determine sequence of plotting which may be important for
        !          1001: filled objects.
        !          1002: Using button two or three terminates the command.
        !          1003: .RE
        !          1004: .hD
        !          1005: draw
        !          1006: .LP
        !          1007: Used for drawing objects.  Must be used to begin a drawing.
        !          1008: .RS
        !          1009: .hD
        !          1010: no grid
        !          1011: .LP
        !          1012: Removes the grid from the screen
        !          1013: .hD
        !          1014: grid:FMC
        !          1015: .LP
        !          1016: Create a grid on the screen either Fine, Medium, or
        !          1017: Coarse (FMC) depending on the number of times the
        !          1018: option is selected.
        !          1019: .hD
        !          1020: lines
        !          1021: .LP
        !          1022: Draws lines.  Button one is used to select the starting
        !          1023: and terminating points of a line.
        !          1024: Buttons two and three terminate the command.
        !          1025: .hD
        !          1026: text
        !          1027: .LP
        !          1028: Select a point for the text using button one and type from the
        !          1029: keyboard.  Two returns terminates input.
        !          1030: .hD
        !          1031: circle
        !          1032: .LP
        !          1033: Draws circles.  Click button one over the center of the circle.
        !          1034: Draw the circle outward and click button one again to define the
        !          1035: radius.
        !          1036: .hD
        !          1037: box
        !          1038: .LP
        !          1039: Draws boxes. Click button one over the upper left (right) corner
        !          1040: of the box and move the mouse right (left) and define the lower
        !          1041: right (left) corner of the box by clicking button one again.
        !          1042: .hD
        !          1043: oval
        !          1044: .LP
        !          1045: Draws ovals. Click button one over the upper left (right) corner
        !          1046: of the oval and move the mouse right (left) and define the lower
        !          1047: right (left) corner of the oval by clicking button one again.
        !          1048: .hD
        !          1049: family/bx
        !          1050: .LP
        !          1051: Define a family by surrounding family elements in a box.
        !          1052: The upper and lower corners of the box are defined with
        !          1053: button one.  Any objects whose first point lies within the box
        !          1054: become members of the family and are connected with dashed
        !          1055: lines if the ``markers'' option is on (basic menu). A family
        !          1056: is manipulated as a unit.
        !          1057: .hD
        !          1058: user oper
        !          1059: .LP
        !          1060: Used to incorporate output from a
        !          1061: .UX
        !          1062: command on the screen.
        !          1063: There is no way to provide standard input but arguments
        !          1064: are passed.
        !          1065: Click button one over the area where the output should appear.
        !          1066: Type the command and hit two returns to terminate the input. 
        !          1067: The output from the command is printed on the screen.
        !          1068: Typical use is for commands like ``date'', ``who'', etc.
        !          1069: If PED thinks that incorporation of the command output into
        !          1070: a PED file may cause problems (memory overflow for example)
        !          1071: it will cancel the operation.
        !          1072: .hD
        !          1073: fixsz(t)
        !          1074: .LP
        !          1075: Prevents scaling of characters with the drawing. Scaling may be
        !          1076: restored by executing the command a second time. When used
        !          1077: it saves terminal memory since only one font is stored. It is
        !          1078: also desirable in its own right since many users do not like
        !          1079: scaling of text.
        !          1080: .RE
        !          1081: .hD
        !          1082: reshape
        !          1083: .LP
        !          1084: Reshape allows you to change the shape of objects.
        !          1085: .RS
        !          1086: .hD
        !          1087: formal
        !          1088: .LP
        !          1089: Clicking button one over any object will
        !          1090: straighten all lines of the object that are almost completely
        !          1091: vertical or horizontal as
        !          1092: described in section 5.
        !          1093: .hD
        !          1094: spline(t)
        !          1095: .LP
        !          1096: Convert a polygon into a spline controlled by the polygon or
        !          1097: convert a spline into its controlling polygon.
        !          1098: .hD
        !          1099: arrow(t)
        !          1100: .LP
        !          1101: Clicking button one over the end point of
        !          1102: an object will add an arrow.  Arrows cannot be added to circles
        !          1103: All arrows must be at an end point of a line (i.e you cannot
        !          1104: add an arrow to the middle of the side of a box. However, for
        !          1105: ovals, the arrow is placed along one side of the oval).
        !          1106: .hD
        !          1107: corner(t)
        !          1108: .LP
        !          1109: Make a spline have a corner by pointing to one of the vertices
        !          1110: of its controlling polygon. If there is already a corner there
        !          1111: make the spline smooth.
        !          1112: .hD
        !          1113: mv point
        !          1114: .LP
        !          1115: Clicking button one over any point on a object (except circles)
        !          1116: moves the point to a location specified by a second click of
        !          1117: button one.  This is useful in reshaping splines and creating
        !          1118: distorted boxes and ovals.
        !          1119: .hD
        !          1120: del pnt
        !          1121: .LP
        !          1122: Clicking button one over any point removes the point and reshapes
        !          1123: the object accordingly (i.e a rectangle becomes a triangle).
        !          1124: Circles cannot be used.
        !          1125: .hD
        !          1126: insrt pnt
        !          1127: .LP
        !          1128: This command inserts a point between two points of an object
        !          1129: (except circles). Click button one over any point on a object.
        !          1130: Then select a point where the inserted point will lie. 
        !          1131: Finally, select the terminating point of any line drawn from
        !          1132: the first point.  The line on the object is removed and two new
        !          1133: lines are created joining the three points selected.
        !          1134: .hD
        !          1135: close
        !          1136: .LP
        !          1137: Click button one over any open point of a spline or polygon
        !          1138: and the shortest possible line is drawn to the other open
        !          1139: end of the object. When you close a spline the first and
        !          1140: last points are corners.
        !          1141: .hD
        !          1142: dis fam
        !          1143: .LP
        !          1144: Click button one over any member of a family and the family
        !          1145: will dissolve.
        !          1146: .hD
        !          1147: rest fam
        !          1148: .LP
        !          1149: Click button one over any previous family and it will be
        !          1150: restored.  CAUTION: Some operations on family members after
        !          1151: dissolving may make it impossible to restore it by this
        !          1152: command so you will have to use the make family command
        !          1153: again.
        !          1154: .hD
        !          1155: undo
        !          1156: .LP
        !          1157: Click button one over an object to undo the last command
        !          1158: performed on the object.  You MUST select undo immediately
        !          1159: after executing the command you wish to undo.
        !          1160: .RE
        !          1161: .hD
        !          1162: refine
        !          1163: .LP
        !          1164: Assorted commands for changing the form of objects. (They would
        !          1165: not fit all in the reshape menu.)
        !          1166: .RS
        !          1167: .hD
        !          1168: edit text
        !          1169: .LP
        !          1170: Edit a text object selected by button one. A copy of the text
        !          1171: is displayed on the top of the screen.
        !          1172: Newlines are represented by three horizontal lines or whatever
        !          1173: other symbol your DMD uses for control characters.
        !          1174: If the object has more characters than what can be fitted in the
        !          1175: top line of the screen the command is canceled. (It is
        !          1176: suggested that you use a text editor to edit large blocks of
        !          1177: text. PED files are ASCII and can be edited by any text editor such as
        !          1178: .I ed
        !          1179: or
        !          1180: .I sam .)
        !          1181: Button one is used to select a position within the text. 
        !          1182: A cursor appears in the selected position.
        !          1183: Insert by typing or delete with backspaces.  End an
        !          1184: insert or delete with a return. Press button two or three to
        !          1185: terminate the command.
        !          1186: .hD
        !          1187: adjt(CRL)
        !          1188: .LP
        !          1189: Allows adjustment of text either left, center or right.
        !          1190: Text is initially left adjusted.  Click button one over the
        !          1191: object and it will center.  A second click will right adjust.
        !          1192: Successive clicks continue the pattern Left, Center, Right.
        !          1193: After such an operation all new text is entered in the
        !          1194: selected mode.
        !          1195: .hD
        !          1196: psize
        !          1197: .LP
        !          1198: Set point size for text. Select a text object with button one. A
        !          1199: cursor appears on the top of the screen.  Type a point size and
        !          1200: return and the text will be adjusted to the selected point size.
        !          1201: All successive text uses that point size. Cancel the command
        !          1202: by hitting return.
        !          1203: .hD
        !          1204: what size
        !          1205: .LP
        !          1206: It prints the pointsize for the selected object.
        !          1207: .hD
        !          1208: dashed(t)
        !          1209: .LP
        !          1210: Select an object with button one and the object is
        !          1211: composed of dashed lines.  Circles cannot be made dashed.
        !          1212: .hD
        !          1213: double(t)
        !          1214: .LP
        !          1215: Select an object with button one and the object is composed
        !          1216: of double lines.  Circles, ovals and splines cannot be made
        !          1217: double.  The double lines WILL NOT appear in the local mode
        !          1218: (i.e. ``bring in'') but only on ``view host.''
        !          1219: .hD
        !          1220: heavy(t)
        !          1221: .LP
        !          1222: Select an object with button one and the object is composed
        !          1223: of heavy lines.  Circles, ovals and splines cannot be made
        !          1224: heavy.  The heavy lines WILL NOT appear in the local mode
        !          1225: (i.e. ``bring in'') but only on ``view host.''
        !          1226: .hD
        !          1227: isplin(t)
        !          1228: .LP
        !          1229: Plot the points of a polygon using an interpolating spline.
        !          1230: The interpolant WILL NOT appear in the local mode
        !          1231: (i.e. ``bring in'') but only on ``view host.''
        !          1232: .hD
        !          1233: fix
        !          1234: .LP
        !          1235: Select (with button one) an object with double or heavy lines
        !          1236: or an interpolating spline (isplin). The object display will
        !          1237: become effective not only under the `view host' mode,
        !          1238: but also under the `local' mode.
        !          1239: However the original object description will be lost.
        !          1240: .hD
        !          1241: user oper
        !          1242: .LP
        !          1243: Allows execution of a host
        !          1244: .UX
        !          1245: command defined using the ``type
        !          1246: comm'' option ``u'' or a command defined now. You must select an
        !          1247: object with button 1. If a command has been defined it will
        !          1248: be executed using the object as input. Otherwise you will be
        !          1249: prompted for the name. The object is used as input for the
        !          1250: command if it expects one. See the user's manual for more
        !          1251: details.
        !          1252: .hD
        !          1253: undo
        !          1254: .LP
        !          1255: Undoes the previous command if you point to the object where
        !          1256: that command was applied.
        !          1257: .RE
        !          1258: .hD
        !          1259: remote
        !          1260: .LP
        !          1261: Commands to perform editing on the host.  All commands
        !          1262: request that you enclose the desired area to be edited 
        !          1263: within a rectangle.
        !          1264: .RS
        !          1265: .hD
        !          1266: delete
        !          1267: .LP
        !          1268: Using button one, draw a rectangle around the objects to be
        !          1269: deleted. Confirm by pressing button 3.
        !          1270: .hD
        !          1271: copy
        !          1272: .LP
        !          1273: Using button one, draw a rectangle around the objects to be
        !          1274: copied.  Use button one to select the location of the copied
        !          1275: object.
        !          1276: .hD
        !          1277: move
        !          1278: .LP
        !          1279: Using button one, draw a rectangle around the objects to be
        !          1280: moved.  Use button one to select the location of the moved
        !          1281: object.
        !          1282: .hD
        !          1283: read
        !          1284: .LP
        !          1285: Using button one, draw a rectangle indicating the region where
        !          1286: the read in file will reside.  Once the rectangle is defined,
        !          1287: type in the file name and hit return. The file will be scaled
        !          1288: to fit in the rectangle
        !          1289: .hD
        !          1290: write
        !          1291: .LP
        !          1292: Using button one, draw a rectangle around the objects to be
        !          1293: written to the file.  Once the rectangle is define, type a
        !          1294: file name and hit return.  All objects within the rectangle
        !          1295: are written to the file.
        !          1296: .hD
        !          1297: formal
        !          1298: .LP
        !          1299: Using button one, draw a rectangle around the objects to be
        !          1300: formalized (beautified).  Click button one again to initiate
        !          1301: the procedure. See the user's manual for details about the
        !          1302: formalization procedure.
        !          1303: .hD
        !          1304: xpand
        !          1305: .LP
        !          1306: Using button one, draw a rectangle around the objects to be
        !          1307: expanded.  Click button one to initiate the expansion. Objects
        !          1308: expand by a factor of 1.25.
        !          1309: .hD
        !          1310: shrink
        !          1311: .LP
        !          1312: Using button one, draw a rectangle around the objects to be
        !          1313: shrunk.  Click button one to initiate the shrink command. Objects
        !          1314: shrink by a factor of 0.8.
        !          1315: .hD
        !          1316: v-flip
        !          1317: .LP
        !          1318: Using button one, draw a rectangle around the objects to be
        !          1319: vertically flipped.  Click button one to initiate the vertical
        !          1320: flip.
        !          1321: .hD
        !          1322: h-flip
        !          1323: .LP
        !          1324: Using button one, draw a rectangle around the objects to be
        !          1325: horizontally flipped.  Click button one to initiate the
        !          1326: horizontal flip.
        !          1327: .RE
        !          1328: .hD
        !          1329: shade
        !          1330: .LP
        !          1331: This menu is used to shade objects.  Select a shade with
        !          1332: button one.  Your mouse will become a box that resembles
        !          1333: the selected shade.  Click button one over any object that
        !          1334: you want filled in with that shade.  To remove a shade,
        !          1335: point to `unfill' and then to an object with shading.
        !          1336: .hD
        !          1337: color
        !          1338: .LP
        !          1339: Assign this color to the object selected. There is no visible
        !          1340: effect on the DMD terminal, unless you have set the markers option.
        !          1341: Then the color name appears next to the object (except for the
        !          1342: color black). The assignment of color becomes meaningful when
        !          1343: you display a PED file on a color device.
        !          1344: .EQ
        !          1345: delim !!
        !          1346: .EN
        !          1347: .ds aA \s+2\(->\s-2
        !          1348: .SH
        !          1349: Appendix B: PED File Format
        !          1350: .PP
        !          1351: The following is a specification of the format of
        !          1352: .I ped
        !          1353: files. This information is useful for writing programs to perform
        !          1354: one of the following functions:
        !          1355: (a) display
        !          1356: .I ped
        !          1357: files on new devices;
        !          1358: (b) create illustrations that can be edited by
        !          1359: .I ped
        !          1360: and included in
        !          1361: .I troff
        !          1362: documents by
        !          1363: .I tped.
        !          1364: .PP
        !          1365: It is also a formal definition of
        !          1366: .I ped
        !          1367: objects.
        !          1368: The specification is given as a production system.
        !          1369: Semantics are given in
        !          1370: .I italics .
        !          1371: Nonterminals start with
        !          1372: .CW $ ,
        !          1373: .CW % ,
        !          1374: .CW & ,
        !          1375: or
        !          1376: .CW .
        !          1377: and the following
        !          1378: conventions are observed:
        !          1379: .TS
        !          1380: center;
        !          1381: cfI cfI
        !          1382: lFCW l.
        !          1383: Prefix Interpretation
        !          1384: %      number (integer or floating point),
        !          1385: &      character string
        !          1386: \&.    single character
        !          1387: .TE
        !          1388: All other symbols are terminals.
        !          1389: .SH
        !          1390: Initial Action
        !          1391: .TS
        !          1392: delim(!!);
        !          1393: lFCW lFCW.
        !          1394: File \*(aA     o 8i  \fIopen version\fP
        !          1395: \^     r %N %N %N %N  !x sub "min"! !y sub "min"! !x sub "max"! !y sub "max"!
        !          1396: \^     $$      \fIobject list\fP
        !          1397: \^     e
        !          1398: .TE
        !          1399: .SH
        !          1400: Creation of Object List
        !          1401: .TS
        !          1402: lFCW lFCW.
        !          1403: $$ \*(aA       $Q $$
        !          1404: \^     $Q
        !          1405: .TE
        !          1406: .SH
        !          1407: Creation of Objects
        !          1408: .TS
        !          1409: lFCW lFCW.
        !          1410: $Q \*(aA       [ $HF $$ ]  \fIfamily\fP
        !          1411: \^     [ $H $P ]  \fIpolygon\fP
        !          1412: \^     [ $H $U ]  \fIfilled polygon\fP
        !          1413: \^     [ $H $S ]  \fIspline\fP
        !          1414: \^     [ $HT $T ]  \fItext\fP
        !          1415: \^     [ $H $C ]  \fIcircle\fP
        !          1416: .TE
        !          1417: .SH
        !          1418: Object Headers
        !          1419: .TS
        !          1420: lFCW lFCW.
        !          1421: $H \*(aA       j %N  \fIcolor\fP
        !          1422: \^     h %N  \fIpoint size\fP
        !          1423: \^     i .N   \fIfilled objects: drawing mode\fP
        !          1424: \^     i T.N  \fIfilled objects: texture\fP
        !          1425: \^     k.A .N  \fIdrawing mode\fP
        !          1426: _
        !          1427: $HF \*(aA      j %N  \fIignored\fP
        !          1428: \^     h %N  \fIignored\fP
        !          1429: \^     f %N %N  \fIundefined point\fP
        !          1430: _
        !          1431: $HT \*(aA      j %N  \fIcolor\fP
        !          1432: \^     h %N  \fIpoint size\fP
        !          1433: \^     i P%N  \fIpoint size (obsolete)\fP
        !          1434: \^     i F&N  \fIfont\fP
        !          1435: _
        !          1436: \&.A \*(aA     a  \fIarrow on first point\fP
        !          1437: \^     b  \fIarrow on last point\fP
        !          1438: \^     c  \fIarrow on both points\fP
        !          1439: \^     NULL  \fIno arrow\fP
        !          1440: .TE
        !          1441: .SH
        !          1442: Start of Outlines
        !          1443: .TS
        !          1444: lFCW lFCW.
        !          1445: $P \*(aA       p %N %N
        !          1446: \^     p %N %N $R
        !          1447: \^     P %N %N $R
        !          1448: _
        !          1449: $S \*(aA       s %N %N $R
        !          1450: \^     S %N %N $R
        !          1451: _
        !          1452: $U \*(aA       Q %N %N $R
        !          1453: .TE
        !          1454: .SH
        !          1455: Continuation of Outline
        !          1456: .TS
        !          1457: lFCW lFCW.
        !          1458: $R \*(aA       .V %N %N
        !          1459: \^     .V %N %N $R
        !          1460: _
        !          1461: \&.V \*(aA     v  \fIconnected vertex\fP
        !          1462: \^     w
        !          1463: \^     x  \fIunconnected vertex\fP
        !          1464: \^     X  \fIsame as\fP w \fIand\fP x
        !          1465: .TE
        !          1466: .LP
        !          1467: .CW v
        !          1468: stands for a simple vertex connected to the previous one.
        !          1469: .CW w
        !          1470: is the same as
        !          1471: .CW v
        !          1472: but in the case of splines is
        !          1473: counted as multiple and creates a corner in the curve.
        !          1474: \f(CWx\fP is a simple vertex NOT connected to the previous one.
        !          1475: (The result of a
        !          1476: .I link
        !          1477: operation.)
        !          1478: .SH
        !          1479: Circle
        !          1480: .TS
        !          1481: lFCW lFCW.
        !          1482: $C \*(aA       c %xc %yc %rad
        !          1483: .TE
        !          1484: .SH
        !          1485: Text
        !          1486: .TS
        !          1487: lFCW lFCW.
        !          1488: $T \*(aA       m %N %N $TT
        !          1489: $TT \*(aA      u .M&T $TR
        !          1490: _
        !          1491: $TR \*(aA      u &T $TR
        !          1492: \^     t &T
        !          1493: _
        !          1494: \&.M \*(aA     L  \fIleft adjusted text\fP
        !          1495: \^     C  \fIcentered text\fP
        !          1496: \^     R  \fIright adjusted text\fP
        !          1497: .TE
        !          1498: .LP
        !          1499: Valid numbers for color are 0 to 7. Valid characters for texture
        !          1500: filling are E through P. Valid characters for drawing mode are
        !          1501: .TS
        !          1502: center;
        !          1503: lFCW l.
        !          1504: s      solid
        !          1505: d      dashed
        !          1506: t      double
        !          1507: h      heavy
        !          1508: i      interpolating spline
        !          1509: .TE
        !          1510: .PP
        !          1511: The specification is rather awkward at points for historical reason.
        !          1512: Originally, we had hoped that the
        !          1513: .I ped
        !          1514: file format would be the same as that for the PLOT(5) metafile.
        !          1515: This goal was eventually abandoned but by that time there were too many
        !          1516: .I ped
        !          1517: files around to allow a drastic redesign of the format.
        !          1518: .SH
        !          1519: Appendix C: Extensions of TROFF and TROFF postprocessors
        !          1520: needed for expanding the compact output of TPED
        !          1521: .PP
        !          1522: .I Troff
        !          1523: has two primitives for drawing graphics:
        !          1524: .CW \eD
        !          1525: and
        !          1526: .CW \eX .
        !          1527: In both cases, the next letter specifies an action.
        !          1528: If
        !          1529: .I troff
        !          1530: does not understand this letter, it simply passes the whole construct through
        !          1531: to its output so that a post-processor can deal with it.
        !          1532: This Appendix details the constructs
        !          1533: needed to interpret the compact output of
        !          1534: .I tped.
        !          1535: .LP
        !          1536: .CW
        !          1537: \eD'p dx dy ...'
        !          1538: .R
        !          1539: a polygonal line.
        !          1540: .LP
        !          1541: .CW
        !          1542: \eD'q dx dy ...'
        !          1543: .R
        !          1544: a spline
        !          1545: .PP
        !          1546: In either case closure of the curve must be made explicit by repeating the
        !          1547: first point for a polygon and the first two for a spline. Multiplicity
        !          1548: of a spline point is achieved by adding a pair 0 0 after the point. Thus
        !          1549: the current
        !          1550: .P1
        !          1551: \eD'~ dx dy ...'
        !          1552: .P2
        !          1553: is equivalent to
        !          1554: .P1
        !          1555: \eD'q 0 0 dx dy ... 0 0'
        !          1556: .P2
        !          1557: .LP
        !          1558: .CW \eX\'P\fIoption\fP'
        !          1559: is used to supply information about the way a curve
        !          1560: will be plotted. Currently the following options are recognized
        !          1561: .de XX
        !          1562: .IP \f(CW\\$1\f1 10
        !          1563: ..
        !          1564: .XX \eX'Pd'
        !          1565: dashed line (or spline)
        !          1566: .XX \eX'Pd'
        !          1567: dashed line
        !          1568: .XX \eX'Ps'
        !          1569: solid line
        !          1570: .XX \eX'Pf'
        !          1571: do not plot the contours but collect them to create a region
        !          1572: with interior filled by texture.
        !          1573: .XX \eX'Pg'
        !          1574: same as previous but the contour of the regions will also be plotted.
        !          1575: .XX \eX'Pe\fIS\fP'
        !          1576: do the actual scan conversion of collected contours using a texture
        !          1577: specified by the character S. (The textures of \fIped\fP
        !          1578: are described in order by the characters E to P.)

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.