william@CS.UCLA.EDU (William Cheng) (02/13/91)
Submitted-by: william@CS.UCLA.EDU (William Cheng) Posting-number: Volume 11, Issue 69 Archive-name: tgif/patch7 Submitted-by: William Cheng <william@cs.ucla.edu> Patch-To: tgif: Volume 7, Issue 56-76 (original: tgif-1.2) Patch-To: tgif: Volume 8, Issue 46-48 (Patch1: tgif-1.2 => tgif-1.9) Patch-To: tgif: Volume 8, Issue 58-60 (Patch2: tgif-1.9 => tgif-1.12) Patch-To: tgif: Volume 8, Issue 87-89 (Patch3: tgif-1.12 => tgif-1.13) Patch-To: tgif: Volume 8, Issue 94 (Patch4: tgif-1.13 => tgif-1.14) Patch-To: tgif: Volume 8, Issue 95 (Patch5: tgif-1.14 => tgif-1.15) Patch-To: tgif: Volume 10, Issue 64-66 (Patch6: tgif-1.15 => tgif-1.16) [moderator's note: WARNING! I just posted 6 parts of the patch #6 a few moments ago and yet I have just seen that a patch #6 already existed! I have no idea what I was doing with a *second* patch #6, and I don't know if it's wrong (the author will undoubtedly contact me :-), but I also don't know if it's right. Anyway, this is patch #7 so I wouldn't apply either patch #6 or #7 till further notice -- something's going to fail. I will post a followup soon informing you to either patch your sources with that extra patch #6, or to dump them. Either way, hold on to this anyway --you'll need it after we get the patch #6 thing straightend out. Sorry for the confusion. --dan ] Patch7 of tgif takes tgif-1.16 to tgif-1.19. Below is a list of added features/bug fixes, followed by the actual patch. tgif-1.16 => tgif-1.17 1) Fix bugs to use getwd() to get current working directory. Thanks to Peter Mutsaers (muts@fysaj.fys.ruu.nl) for pointing it out. 2) Add color attributes in color PostScript files. (Default for printing is still non-color. Type ^#K to switch to color PostScript output.) 3) Add dash patterns and change tgif file version to 9. 4) Add 4 more buttons in the panel (choice window). Now all secondary pop-up menus can be poped-up from the panel (except for the edit menu). 5) Add the ``UpdateSymbols()'' feature. Selected icons can be ``brought up-to-date'' with the current representations found in the symbol path. Each new icon is placed so that it is lined up at the upper-left corner with the old icon. This feature is accessible by typing ^#U. 6) If one of the font can not be found, a font with a different dots-per-inch is automatically chosen. If both can not be found, tgif exits. (Apparently some machines only support 100dpi fonts by default.) tgif-1.17 => tgif-1.18 1) Fix rotated text. On some servers it doesn't work. (Should use ZPixmap instead of XYPixmap when calling XGetImage ().) 2) There was this problem that after a new symbol file is saved and one tries to save it again (with ^s), tgif thinks the file name is /symbolfilename. This bug is fixed. 3) If fonts of certain dots-per-inch can not be found and an alternative fonts with different dots-per-inch can be found, the file status should be set to 'MODIFIED'. 4) If the symbol path contains a ".", then whenever a directory is changed, the symbol name cache should be updated. tgif-1.18 => tgif-1.19 1) Fix a bug in names.c which cause segmentation faults on some machines. 2) If certain color can not be found, skip it, don't leave it blank. 3) Add explanations in tgif.man about how the alignments work. The following is the patch to take tgif from version 1.16 to 1.19. ---------------------------------> cut here <--------------------------------- *** box.c.orig Mon Jan 7 13:00:50 1991 --- box.c Mon Jan 7 13:00:52 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/box.c,v 1.8 90/10/27 15:09:43 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/box.c,v 1.11 90/11/10 13:50:41 william Exp $"; #endif *************** *** 70,75 **** struct ObjRec * ObjPtr; { ! register int ltx, lty, rbx, rby; ! int fill, width, pen; ltx = ObjPtr->obbox.ltx; --- 70,75 ---- struct ObjRec * ObjPtr; { ! register int ltx, lty, rbx, rby, i; ! int fill, width, pen, dash, color_index; ltx = ObjPtr->obbox.ltx; *************** *** 81,87 **** --- 81,97 ---- pen = ObjPtr->detail.b->pen; width = ObjPtr->detail.b->width; + dash = ObjPtr->detail.b->dash; if (fill == NONEPAT && pen == NONEPAT) return; + if (colorDump) + { + color_index = ObjPtr->color; + fprintf (FP, "%.3f %.3f %.3f setrgbcolor\n", + ((float)tgifColors[color_index].red/maxRGB), + ((float)tgifColors[color_index].green/maxRGB), + ((float)tgifColors[color_index].blue/maxRGB)); + } + switch (fill) { *************** *** 117,120 **** --- 127,138 ---- fprintf (FP, "%1d setlinewidth\n", widthOfLine[width]); + if (dash != 0) + { + fprintf (FP, "["); + for (i = 0; i < dashListLength[dash]-1; i++) + fprintf (FP, "%1d ", (int)(dashList[dash][i])); + fprintf (FP, "%1d] 0 setdash\n", + (int)(dashList[dash][dashListLength[dash]-1])); + } switch (pen) *************** *** 149,152 **** --- 167,171 ---- break; } + if (dash != 0) fprintf (FP, "[] 0 setdash\n"); fprintf (FP, "1 setlinewidth\n\n"); } *************** *** 157,161 **** { struct BoxRec * box_ptr = ObjPtr->detail.b; ! int fill, pen, pixel, func, ltx, lty, rbx, rby, width; int real_x_off, real_y_off; char s[80]; --- 176,180 ---- { struct BoxRec * box_ptr = ObjPtr->detail.b; ! int fill, pen, pixel, func, ltx, lty, rbx, rby, width, dash; int real_x_off, real_y_off; char s[80]; *************** *** 165,168 **** --- 184,188 ---- fill = ObjPtr->detail.b->fill; width = ObjPtr->detail.b->width; + dash = ObjPtr->detail.b->dash; pixel = colorPixels[ObjPtr->color]; *************** *** 193,199 **** values.stipple = patPixmap[pen]; values.line_width = widthOfLine[width] >> zoomScale; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth, ! &values); XDrawRectangle (mainDisplay, win, drawGC, ltx, lty, rbx-ltx, rby-lty); } --- 213,227 ---- values.stipple = patPixmap[pen]; values.line_width = widthOfLine[width] >> zoomScale; + if (dash != 0) + { + XSetDashes (mainDisplay, drawGC, 0, dashList[dash], + dashListLength[dash]); + values.line_style = LineOnOffDash; + } + else + values.line_style = LineSolid; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth | ! GCLineStyle, &values); XDrawRectangle (mainDisplay, win, drawGC, ltx, lty, rbx-ltx, rby-lty); } *************** *** 212,215 **** --- 240,244 ---- box_ptr->width = lineWidth; box_ptr->pen = penPat; + box_ptr->dash = curDash; obj_ptr = (struct ObjRec *) calloc (1, sizeof(struct ObjRec)); *************** *** 273,279 **** values.fill_style = FillSolid; values.line_width = 0; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCLineWidth, &values); saved_x = grid_x = OrigX; --- 302,310 ---- values.fill_style = FillSolid; values.line_width = 0; + values.line_style = LineSolid; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCLineWidth | GCLineStyle, ! &values); saved_x = grid_x = OrigX; *************** *** 341,349 **** struct ObjRec * ObjPtr; { ! fprintf (FP, "box(%s,", colorMenuItems[ObjPtr->color]); ! fprintf (FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,", ObjPtr->obbox.ltx, ObjPtr->obbox.lty, ObjPtr->obbox.rbx, ObjPtr->obbox.rby, ObjPtr->detail.b->fill, ObjPtr->detail.b->width, ! ObjPtr->detail.b->pen, ObjPtr->id); SaveAttrs (FP, ObjPtr->lattr); fprintf (FP, ")"); --- 372,380 ---- struct ObjRec * ObjPtr; { ! fprintf (FP, "box('%s',", colorMenuItems[ObjPtr->color]); ! fprintf (FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,", ObjPtr->obbox.ltx, ObjPtr->obbox.lty, ObjPtr->obbox.rbx, ObjPtr->obbox.rby, ObjPtr->detail.b->fill, ObjPtr->detail.b->width, ! ObjPtr->detail.b->pen, ObjPtr->id, ObjPtr->detail.b->dash); SaveAttrs (FP, ObjPtr->lattr); fprintf (FP, ")"); *************** *** 356,360 **** struct BoxRec * box_ptr; char color_str[20], * s; ! int ltx, lty, rbx, rby, fill, width, pen, w; *ObjPtr = (struct ObjRec *) calloc (1, sizeof(struct ObjRec)); --- 387,391 ---- struct BoxRec * box_ptr; char color_str[20], * s; ! int ltx, lty, rbx, rby, fill, width, pen, dash, w; *ObjPtr = (struct ObjRec *) calloc (1, sizeof(struct ObjRec)); *************** *** 373,376 **** --- 404,408 ---- } (*ObjPtr)->id = objId++; + dash = 0; } else if (fileVersion <= 7) *************** *** 379,384 **** <x, <y, &rbx, &rby, &fill, &width, &pen); (*ObjPtr)->id = objId++; } ! else { sscanf (s, "%d , %d , %d , %d , %d , %d , %d , %d", --- 411,417 ---- <x, <y, &rbx, &rby, &fill, &width, &pen); (*ObjPtr)->id = objId++; + dash = 0; } ! else if (fileVersion <= 8) { sscanf (s, "%d , %d , %d , %d , %d , %d , %d , %d", *************** *** 385,389 **** --- 418,430 ---- <x, <y, &rbx, &rby, &fill, &width, &pen, &((*ObjPtr)->id)); if ((*ObjPtr)->id >= objId) objId = (*ObjPtr)->id + 1; + dash = 0; } + else + { + sscanf (s, "%d , %d , %d , %d , %d , %d , %d , %d , %d", + <x, <y, &rbx, &rby, &fill, &width, &pen, &((*ObjPtr)->id), + &dash); + if ((*ObjPtr)->id >= objId) objId = (*ObjPtr)->id + 1; + } box_ptr->fill = fill; *************** *** 390,393 **** --- 431,435 ---- box_ptr->width = width; box_ptr->pen = pen; + box_ptr->dash = dash; (*ObjPtr)->x = ltx; (*ObjPtr)->y = lty; *** choice.c.orig Mon Jan 7 13:00:59 1991 --- choice.c Mon Jan 7 13:01:01 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/choice.c,v 1.9 90/10/27 15:12:25 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/choice.c,v 1.10 90/11/01 08:41:44 william Exp $"; #endif *************** *** 62,67 **** } ! void ShowColor () { XGCValues values; --- 62,79 ---- } ! void ShowWhereToPrint () { + if (colorDump) + XSetForeground (mainDisplay, rasterGC, colorPixels[colorIndex]); + XSetStipple (mainDisplay, rasterGC, whereToPrintPixmap[whereToPrint]); + XFillRectangle (mainDisplay, choiceWindow, rasterGC, 6*choiceImageW, 0, + choiceImageW, choiceImageH); + if (colorDump) + XSetForeground (mainDisplay, rasterGC, myFgPixel); + } + + void ShowColor (PropagateWhereToPrint) + int PropagateWhereToPrint; + { XGCValues values; *************** *** 78,81 **** --- 90,94 ---- 0, choiceImageH, choiceImageW, choiceImageH); } + if (PropagateWhereToPrint) ShowWhereToPrint (); } *************** *** 117,155 **** h = canvasFontHeight; ! switch (curRotate) ! { ! case ROTATE0: ! x = (w > choiceImageW) ? ! 2*choiceImageW - (w-choiceImageW)/2 : ! 2*choiceImageW + (choiceImageW-w)/2; ! y = (h > choiceImageH) ? ! choiceImageH + (canvasFontAsc-(h-choiceImageH)/2) : ! choiceImageH + (canvasFontAsc+(choiceImageH-h)/2); ! break; ! case ROTATE90: ! x = (h > choiceImageW) ? ! 2*choiceImageW + h - (h-choiceImageW)/2 : ! 2*choiceImageW + h + (choiceImageW-h)/2; ! y = (w > choiceImageH) ? ! choiceImageH - (w-choiceImageH)/2 : ! choiceImageH + (choiceImageH-w)/2; ! break; ! case ROTATE180: ! x = (w > choiceImageW) ? ! 2*choiceImageW + w - (w-choiceImageW)/2 : ! 2*choiceImageW + w + (choiceImageW-w)/2; ! y = (h > choiceImageH) ? ! 2*choiceImageH + (h-choiceImageH)/2 : ! 2*choiceImageH - (choiceImageH-h)/2; ! break; ! case ROTATE270: ! x = (h > choiceImageW) ? ! 2*choiceImageW - (h-choiceImageW)/2 : ! 2*choiceImageW + (choiceImageW-h)/2; ! y = (w > choiceImageH) ? ! 2*choiceImageH + (w-choiceImageH)/2 : ! 2*choiceImageH - (choiceImageH-w)/2; ! break; ! } XClearArea (mainDisplay, choiceWindow, 2*choiceImageW, choiceImageH, --- 130,139 ---- h = canvasFontHeight; ! x = (w > choiceImageW) ? ! 2*choiceImageW - (w-choiceImageW)/2 : ! 2*choiceImageW + (choiceImageW-w)/2; ! y = (h > choiceImageH) ? ! choiceImageH + (canvasFontAsc-(h-choiceImageH)/2) : ! choiceImageH + (canvasFontAsc+(choiceImageH-h)/2); XClearArea (mainDisplay, choiceWindow, 2*choiceImageW, choiceImageH, *************** *** 157,215 **** XSetFont (mainDisplay, choiceGC, canvasFontPtr->fid); ! if (curRotate == 0) ! { ! XSetClipRectangles (mainDisplay, choiceGC, 0, 0, recs, 1, YXBanded); ! values.foreground = myFgPixel; ! values.background = myBgPixel; ! XChangeGC (mainDisplay, choiceGC, GCForeground | GCBackground, &values); ! XDrawString (mainDisplay, choiceWindow, choiceGC, x, y, "W", 1); ! values.foreground = 1; ! values.background = 0; ! XChangeGC (mainDisplay, choiceGC, GCForeground | GCBackground, &values); ! } ! else ! { ! XSetForeground (mainDisplay, choiceGC, 0); ! XFillRectangle (mainDisplay, choiceBackingPixmap, choiceGC, 0, 0, ! choiceWindowW, choiceWindowH); ! XSetForeground (mainDisplay, choiceGC, 1); - XDrawImageString (mainDisplay, choiceBackingPixmap, choiceGC, 0, - canvasFontAsc, "W", 1); - image = XGetImage (mainDisplay, choiceBackingPixmap, 0, 0, w, h, 1, - XYPixmap); - XSetClipRectangles (mainDisplay, choiceGC, 0, 0, recs, 1, YXBanded); - - values.foreground = myFgPixel; - values.background = myBgPixel; - XChangeGC (mainDisplay, choiceGC, GCForeground | GCBackground, &values); - - saved_x = x; - saved_y = y; - for (i = 0; i < w; i++) - for (j = 0; j < h; j++) - if (XGetPixel (image, i, j) == 1) - { - switch (curRotate) - { - case ROTATE90: x = saved_x-j; y = saved_y+i; break; - case ROTATE180: x = saved_x-i; y = saved_y-j; break; - case ROTATE270: x = saved_x+j; y = saved_y-i; break; - } - #ifdef sun - XDrawPoint (mainDisplay, choiceWindow, defaultGC, x, y); - #else - XDrawLine (mainDisplay,choiceWindow,defaultGC,x,y,x,y); - #endif - } - - values.foreground = 1; - values.background = 0; - XChangeGC (mainDisplay, choiceGC, GCForeground | GCBackground, &values); - } - recs[0].x = 0; recs[0].y = 0; --- 141,156 ---- XSetFont (mainDisplay, choiceGC, canvasFontPtr->fid); ! XSetClipRectangles (mainDisplay, choiceGC, 0, 0, recs, 1, YXBanded); ! values.foreground = myFgPixel; ! values.background = myBgPixel; ! XChangeGC (mainDisplay, choiceGC, GCForeground | GCBackground, &values); ! XDrawString (mainDisplay, choiceWindow, choiceGC, x, y, "W", 1); ! values.foreground = 1; ! values.background = 0; ! XChangeGC (mainDisplay, choiceGC, GCForeground | GCBackground, &values); recs[0].x = 0; recs[0].y = 0; *************** *** 219,245 **** } ! void ShowLineWidth () { ! XSetStipple (mainDisplay, rasterGC, shortLineWidthPixmap[lineWidth]); XFillRectangle (mainDisplay, choiceWindow, rasterGC, 3*choiceImageW, 0, choiceImageW, choiceImageH); - - /* XGCValues values; - - XClearArea (mainDisplay, choiceWindow, 3*choiceImageW, 0, - choiceImageW, choiceImageH, FALSE); - if (curDash != 0) - XSetDashes (mainDisplay, rasterGC, 0, dashList[curDash], - dashListLength[curDash]); - values.line_width = widthOfLine[lineWidth]; - XChangeGC (mainDisplay, rasterGC, GCLineWidth, &values); - XDrawLine (mainDisplay, choiceWindow, rasterGC, - 3*choiceImageW+3, (int)(choiceImageH/2), 4*choiceImageW-3, - (int)(choiceImageH/2)); */ } ! void ShowLineStyle () { ! XSetStipple (mainDisplay, rasterGC, shortLineStylePixmap[lineStyle]); XFillRectangle (mainDisplay, choiceWindow, rasterGC, 3*choiceImageW, choiceImageH, choiceImageW, choiceImageH); --- 160,173 ---- } ! void ShowRotate () { ! XSetStipple (mainDisplay, rasterGC, rotatePixmap[curRotate]); XFillRectangle (mainDisplay, choiceWindow, rasterGC, 3*choiceImageW, 0, choiceImageW, choiceImageH); } ! void ShowSpecial () { ! XSetStipple (mainDisplay, rasterGC, specialPixmap); XFillRectangle (mainDisplay, choiceWindow, rasterGC, 3*choiceImageW, choiceImageH, choiceImageW, choiceImageH); *************** *** 246,252 **** } ! void ShowWhereToPrint () { ! XSetStipple (mainDisplay, rasterGC, whereToPrintPixmap[whereToPrint]); XFillRectangle (mainDisplay, choiceWindow, rasterGC, 4*choiceImageW, 0, choiceImageW, choiceImageH); --- 174,180 ---- } ! void ShowLineWidth () { ! XSetStipple (mainDisplay, rasterGC, shortLineWidthPixmap[lineWidth]); XFillRectangle (mainDisplay, choiceWindow, rasterGC, 4*choiceImageW, 0, choiceImageW, choiceImageH); *************** *** 253,263 **** } void ShowLineType () { XSetStipple (mainDisplay, rasterGC, shortLineTypePixmap[curSpline]); ! XFillRectangle (mainDisplay, choiceWindow, rasterGC, 4*choiceImageW, choiceImageH, choiceImageW, choiceImageH); } void ShowFill () { --- 181,212 ---- } + void ShowLineStyle () + { + XSetStipple (mainDisplay, rasterGC, shortLineStylePixmap[lineStyle]); + XFillRectangle (mainDisplay, choiceWindow, rasterGC, 4*choiceImageW, + choiceImageH, choiceImageW, choiceImageH); + } + void ShowLineType () { XSetStipple (mainDisplay, rasterGC, shortLineTypePixmap[curSpline]); ! XFillRectangle (mainDisplay, choiceWindow, rasterGC, 5*choiceImageW, 0, ! choiceImageW, choiceImageH); ! } ! ! void ShowDash () ! { ! XSetStipple (mainDisplay, rasterGC, shortDashPixmap[curDash]); ! XFillRectangle (mainDisplay, choiceWindow, rasterGC, 5*choiceImageW, choiceImageH, choiceImageW, choiceImageH); } + void ShowFile () + { + XSetStipple (mainDisplay, rasterGC, filePixmap); + XFillRectangle (mainDisplay, choiceWindow, rasterGC, 6*choiceImageW, + choiceImageH, choiceImageW, choiceImageH); + } + void ShowFill () { *************** *** 274,278 **** XFillRectangle (mainDisplay, choiceWindow, patGC, ! 5*choiceImageW, 0, choiceImageW, choiceImageH); } --- 223,227 ---- XFillRectangle (mainDisplay, choiceWindow, patGC, ! 7*choiceImageW, 0, choiceImageW, choiceImageH); } *************** *** 291,295 **** XFillRectangle (mainDisplay, choiceWindow, patGC, ! 5*choiceImageW, choiceImageH, choiceImageW, choiceImageH); } --- 240,244 ---- XFillRectangle (mainDisplay, choiceWindow, patGC, ! 7*choiceImageW, choiceImageH, choiceImageW, choiceImageH); } *************** *** 398,402 **** if (curChoice != NOTHING) SetCurChoice (NOTHING); colorIndex = (colorIndex+maxColors+delta) % maxColors; ! ShowColor (); if (topSel != NULL) ChangeAllSelColor (colorIndex); } --- 347,351 ---- if (curChoice != NOTHING) SetCurChoice (NOTHING); colorIndex = (colorIndex+maxColors+delta) % maxColors; ! ShowColor (TRUE); if (topSel != NULL) ChangeAllSelColor (colorIndex); } *************** *** 406,410 **** if (yindex == 0) { ! if (delta != 0) { horiAlign = (horiAlign+MAXALIGNS+delta) % MAXALIGNS; --- 355,361 ---- if (yindex == 0) { ! if (delta == 0) ! SizeMenu (x, y); ! else { horiAlign = (horiAlign+MAXALIGNS+delta) % MAXALIGNS; *************** *** 414,418 **** else { ! if (delta != 0) { vertAlign = (vertAlign+MAXALIGNS+delta) % MAXALIGNS; --- 365,371 ---- else { ! if (delta == 0) ! FontDPIMenu (x, y); ! else { vertAlign = (vertAlign+MAXALIGNS+delta) % MAXALIGNS; *************** *** 441,446 **** { if (curChoice != NOTHING) SetCurChoice (NOTHING); ! curRotate = (curRotate+4+delta) % 4; ShowCurFont (); if (topSel != NULL) { --- 394,414 ---- { if (curChoice != NOTHING) SetCurChoice (NOTHING); ! curFont = (curFont+MAXFONTS+delta) % MAXFONTS; ! SetCanvasFont (); ShowCurFont (); + if (topSel != NULL) ChangeFont (curFont); + } + } + break; + case 3: + if (yindex == 0) + { + if (delta == 0) + ArrangeMenu (x, y); + else + { + if (curChoice != NOTHING) SetCurChoice (NOTHING); + curRotate = (curRotate+4+delta) % 4; + ShowRotate (); if (topSel != NULL) { *************** *** 452,457 **** } } break; ! case 3: if (yindex == 0) { --- 420,430 ---- } } + else + { + if (delta == 0) + SpecialMenu (x, y); + } break; ! case 4: if (yindex == 0) { *************** *** 479,495 **** } break; ! case 4: if (yindex == 0) { if (delta == 0) ! LayoutMenu (x, y); else { ! whereToPrint = !whereToPrint; ! ShowWhereToPrint (); ! if (whereToPrint == PRINTER) ! Msg ("Print device set to printer."); ! else ! Msg ("Print device set to LaTeX-Figure file."); } } --- 452,466 ---- } break; ! case 5: if (yindex == 0) { if (delta == 0) ! LineStyleMenu (x, y); else { ! if (curChoice != NOTHING) SetCurChoice (NOTHING); ! curSpline = (curSpline+MAXLINETYPES+delta) % MAXLINETYPES; ! ShowLineType (); ! if (topSel != NULL) ChangeAllSelLineType (curSpline); } } *************** *** 501,511 **** { if (curChoice != NOTHING) SetCurChoice (NOTHING); ! curSpline = (curSpline+MAXLINETYPES+delta) % MAXLINETYPES; ! ShowLineType (); ! if (topSel != NULL) ChangeAllSelLineType (curSpline); } } break; ! case 5: if (yindex == 0) { --- 472,496 ---- { if (curChoice != NOTHING) SetCurChoice (NOTHING); ! curDash = (curDash+MAXDASHES+delta) % MAXDASHES; ! ShowDash (); ! if (topSel != NULL) ChangeAllSelDashes (curDash); } } break; ! case 6: ! if (yindex == 0) ! { ! if (delta == 0) ! LayoutMenu (x, y); ! else ! ToggleWhereToPrint (); ! } ! else ! { ! if (delta == 0) ! FileMenu (x, y); ! } ! break; ! case 7: if (yindex == 0) { *** color.c.orig Mon Jan 7 13:01:08 1991 --- color.c Mon Jan 7 13:01:09 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/color.c,v 1.14 90/10/27 16:29:54 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/color.c,v 1.16 90/11/10 13:47:29 william Exp $"; #endif *************** *** 22,25 **** --- 22,27 ---- #include "text.e" + #define COLORSTRLEN 80 + int maxColors = MAXCOLORS; int defaultColorIndex = 4; *************** *** 32,35 **** --- 34,39 ---- int colorDump = FALSE; + static int allocatedMaxColors = MAXCOLORS; + static char * defaultColorMenuItems[MAXCOLORS] = { *************** *** 75,79 **** void InitColor () { ! register int i; XColor color, exact_def; char buf[80], * c_ptr, fg_color[80], bg_color[80], brdr_color[80]; --- 79,83 ---- void InitColor () { ! register int i, index; XColor color, exact_def; char buf[80], * c_ptr, fg_color[80], bg_color[80], brdr_color[80]; *************** *** 154,157 **** --- 158,165 ---- tgifColors = (XColor *) calloc (maxColors, sizeof (XColor)); + allocatedMaxColors = maxColors; + for (i = 0; i < allocatedMaxColors; i++) + colorMenuItems[i] = (char *) calloc (COLORSTRLEN, sizeof(char)); + if (color_in_x_default) { *************** *** 160,167 **** sprintf (buf, "Color%1d", i); if ((c_ptr = XGetDefault (mainDisplay, TOOL_NAME, buf)) != NULL) - { - colorMenuItems[i] = (char *) calloc (strlen(c_ptr),sizeof(char)); strcpy (colorMenuItems[i], c_ptr); - } else { --- 168,172 ---- *************** *** 177,189 **** if (colorDisplay) { for (i = 0; i < maxColors; i++) { ! XAllocNamedColor(mainDisplay, mainColormap, colorMenuItems[i], &color, ! &exact_def); ! colorPixels[i] = color.pixel; ! tgifColors[i].red = color.red; ! tgifColors[i].green = color.green; ! tgifColors[i].blue = color.blue; if (strcmp (colorMenuItems[i], fg_color) == 0) --- 182,199 ---- if (colorDisplay) { + index = 0; for (i = 0; i < maxColors; i++) { ! if (!XAllocNamedColor(mainDisplay, mainColormap, colorMenuItems[i], ! &color, &exact_def)) ! continue; ! if (i != index) strcpy (colorMenuItems[index], colorMenuItems[i]); ! ! colorPixels[index] = color.pixel; ! ! tgifColors[index].red = color.red; ! tgifColors[index].green = color.green; ! tgifColors[index].blue = color.blue; if (strcmp (colorMenuItems[i], fg_color) == 0) *************** *** 210,215 **** --- 220,228 ---- brdr_allocated = TRUE; } + index++; } + maxColors = index; + if (!fg_allocated) { *************** *** 314,318 **** text_obj_created = TieLooseEnds (); colorIndex = ColorIndex; ! ShowColor (); if (!text_obj_created && curChoice == DRAWTEXT && text_cursor_shown) { --- 327,331 ---- text_obj_created = TieLooseEnds (); colorIndex = ColorIndex; ! ShowColor (TRUE); if (!text_obj_created && curChoice == DRAWTEXT && text_cursor_shown) { *************** *** 381,386 **** else w = (int)(maxColors / 10) + 1; ! index = PxMpMenuLoop (X, Y, choiceImageW, choiceImageH, 10, w, ! maxColors, fore_colors, pixmap, MULTICOLOR); if (index != INVALID) ChangeAllSelColor (index); --- 394,403 ---- else w = (int)(maxColors / 10) + 1; ! if (maxColors <= 10) ! index = PxMpMenuLoop (X, Y, choiceImageW, choiceImageH, maxColors, w, ! maxColors, fore_colors, pixmap, MULTICOLOR); ! else ! index = PxMpMenuLoop (X, Y, choiceImageW, choiceImageH, 10, w, ! maxColors, fore_colors, pixmap, MULTICOLOR); if (index != INVALID) ChangeAllSelColor (index); *************** *** 394,398 **** cfree (colorPixels); cfree (xorColorPixels); ! if (colorDisplay) for (i = 0; i < maxColors; i++) cfree (colorMenuItems[i]); cfree (colorMenuItems); --- 411,415 ---- cfree (colorPixels); cfree (xorColorPixels); ! for (i = 0; i < allocatedMaxColors; i++) cfree (colorMenuItems[i]); cfree (colorMenuItems); *** drawing.c.orig Mon Jan 7 13:01:21 1991 --- drawing.c Mon Jan 7 13:01:23 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/drawing.c,v 1.11 90/08/16 09:34:54 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/drawing.c,v 1.13 90/11/01 18:06:41 william Exp $"; #endif *************** *** 549,553 **** case '\011': /*^#I*/ MakeIconic (); break; case '\012': /*^#J*/ UnMakeIconic (); break; ! case '\013': /*^#K*/ break; case '\014': /*^#L*/ ChangeFontJust (JUST_L); break; case '\015': /*^#M*/ MakeSymbolic (); break; --- 549,553 ---- case '\011': /*^#I*/ MakeIconic (); break; case '\012': /*^#J*/ UnMakeIconic (); break; ! case '\013': /*^#K*/ ToggleColorPostScript (); break; case '\014': /*^#L*/ ChangeFontJust (JUST_L); break; case '\015': /*^#M*/ MakeSymbolic (); break; *************** *** 559,566 **** case '\023': /*^#S*/ SaveNewFile (); break; case '\024': /*^#T*/ ChangeFontStyle (STYLE_NI); break; ! case '\025': /*^#U*/ break; case '\026': /*^#V*/ SetCurChoice (DRAWCIRCLE); break; case '\027': /*^#W*/ ToggleAllSelLineType (); break; ! case '\030': /*^#X*/ break; case '\031': /*^#Y*/ PasteFromCutBuffer (); break; case '\032': /*^#Z*/ break; --- 559,566 ---- case '\023': /*^#S*/ SaveNewFile (); break; case '\024': /*^#T*/ ChangeFontStyle (STYLE_NI); break; ! case '\025': /*^#U*/ UpdateSymbols (); break; case '\026': /*^#V*/ SetCurChoice (DRAWCIRCLE); break; case '\027': /*^#W*/ ToggleAllSelLineType (); break; ! case '\030': /*^#X*/ ToggleWhereToPrint (); break; case '\031': /*^#Y*/ PasteFromCutBuffer (); break; case '\032': /*^#Z*/ break; *** dup.c.orig Mon Jan 7 13:01:29 1991 --- dup.c Mon Jan 7 13:01:30 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/dup.c,v 1.6 90/08/16 09:35:11 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/dup.c,v 1.7 90/10/30 16:57:29 william Exp $"; #endif *************** *** 77,80 **** --- 77,81 ---- poly_ptr->svlist = v; } + poly_ptr->dash = PolyPtr->dash; ObjPtr->detail.p = poly_ptr; *************** *** 113,116 **** --- 114,118 ---- polygon_ptr->svlist = v; } + polygon_ptr->dash = PolygonPtr->dash; ObjPtr->detail.g = polygon_ptr; *************** *** 128,131 **** --- 130,134 ---- oval_ptr->width = OvalPtr->width; oval_ptr->pen = OvalPtr->pen; + oval_ptr->dash = OvalPtr->dash; ObjPtr->detail.o = oval_ptr; *************** *** 143,146 **** --- 146,150 ---- box_ptr->width = BoxPtr->width; box_ptr->pen = BoxPtr->pen; + box_ptr->dash = BoxPtr->dash; ObjPtr->detail.b = box_ptr; *** edit.c.orig Mon Jan 7 13:01:50 1991 --- edit.c Mon Jan 7 13:01:52 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/edit.c,v 1.13 90/08/21 16:03:43 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/edit.c,v 1.14 90/11/01 18:21:29 william Exp $"; #endif *************** *** 29,32 **** --- 29,33 ---- #include "select.e" #include "setup.e" + #include "special.e" #include "spline.e" #include "stretch.e" *************** *** 739,741 **** --- 740,837 ---- case ROTATE_COUNTER: RotateCounter (); break; } + } + + static struct ObjRec * tmpTopObj, * tmpBotObj; + static struct SelRec * tmpTopSel, * tmpBotSel; + + static + void PushTmpSel (ObjPtr) + struct ObjRec * ObjPtr; + { + struct SelRec * sel_ptr; + + ObjPtr->next = tmpTopObj; + ObjPtr->prev = NULL; + + sel_ptr = (struct SelRec *) calloc (1, sizeof (struct SelRec)); + sel_ptr->next = tmpTopSel; + sel_ptr->prev = NULL; + sel_ptr->obj = ObjPtr; + + if (tmpTopObj == NULL) + { + tmpBotObj = ObjPtr; + tmpBotSel = sel_ptr; + } + else + { + tmpTopObj->prev = ObjPtr; + tmpTopSel->prev = sel_ptr; + } + tmpTopObj = ObjPtr; + tmpTopSel = sel_ptr; + } + + void UpdateSymbols () + { + int dx, dy, changed = FALSE; + char path_name[MAXPATHLENGTH], sym_name[MAXPATHLENGTH]; + struct ObjRec * obj_ptr, * new_obj_ptr; + struct SelRec * sel_ptr; + + if (topSel == NULL) return; + + tmpTopObj = tmpBotObj = NULL; + tmpTopSel = tmpBotSel = NULL; + + for (sel_ptr = botSel; sel_ptr != NULL; sel_ptr = sel_ptr->prev) + { + obj_ptr = sel_ptr->obj; + if (obj_ptr->type != OBJ_ICON) continue; + + strcpy (sym_name, obj_ptr->detail.r->s); + if (GetSymbolPath (obj_ptr->detail.r->s, path_name)) + { + if ((new_obj_ptr = GetObjRepresentation (path_name, sym_name)) != NULL) + { + dx = obj_ptr->obbox.ltx - new_obj_ptr->obbox.ltx; + dy = obj_ptr->obbox.lty - new_obj_ptr->obbox.lty; + MoveObj (new_obj_ptr, dx, dy); + + if (new_obj_ptr->bbox.ltx < selLtX) selLtX = new_obj_ptr->bbox.ltx; + if (new_obj_ptr->bbox.lty < selLtY) selLtY = new_obj_ptr->bbox.lty; + if (new_obj_ptr->bbox.rbx < selRbX) selRbX = new_obj_ptr->bbox.rbx; + if (new_obj_ptr->bbox.rby < selRbY) selRbY = new_obj_ptr->bbox.rby; + if (new_obj_ptr->obbox.ltx < selObjLtX) + selObjLtX = new_obj_ptr->obbox.ltx; + if (new_obj_ptr->obbox.lty < selObjLtY) + selObjLtY = new_obj_ptr->obbox.lty; + if (new_obj_ptr->obbox.rbx < selObjRbX) + selObjRbX = new_obj_ptr->obbox.rbx; + if (new_obj_ptr->obbox.rby < selObjRbY) + selObjRbY = new_obj_ptr->obbox.rby; + + changed = TRUE; + + UnlinkObj (obj_ptr); + PushTmpSel (obj_ptr); + + sel_ptr->obj = new_obj_ptr; + AddObj (NULL, topObj, new_obj_ptr); + } + } + } + + PushToCutBuffer (tmpTopSel, tmpBotSel); + + if (changed) + { + HighLightReverse (); + RedrawAnArea (botObj, selLtX-(1<<zoomScale), selLtY-(1<<zoomScale), + selRbX+(1<<zoomScale), selRbY+(1<<zoomScale)); + UpdSelBBox (); + HighLightForward (); + SetFileModified (TRUE); + } + justDupped = FALSE; } *** file.c.orig Mon Jan 7 13:02:38 1991 --- file.c Mon Jan 7 13:02:47 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/file.c,v 1.38 90/10/27 15:07:35 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/file.c,v 1.43 90/11/10 13:51:37 william Exp $"; #endif *************** *** 46,50 **** #include "text.e" ! #define CUR_VERSION 8 #define START_HAVING_ATTRS 8 --- 46,50 ---- #include "text.e" ! #define CUR_VERSION 9 #define START_HAVING_ATTRS 8 *************** *** 107,111 **** fprintf (FP, "%1d,%1d,%1d,%1d,", curSpline, lineStyle, objFill, penPat); fprintf (FP, "%1d,%1d,%1d,%1d,", textJust, curFont, curStyle, curSize); ! fprintf (FP, "%1d).\n", curFontDPI); } --- 107,111 ---- fprintf (FP, "%1d,%1d,%1d,%1d,", curSpline, lineStyle, objFill, penPat); fprintf (FP, "%1d,%1d,%1d,%1d,", textJust, curFont, curStyle, curSize); ! fprintf (FP, "%1d,%1d).\n", curFontDPI, curDash); } *************** *** 188,191 **** --- 188,192 ---- char new_file_name[MAXPATHLENGTH], s[MAXPATHLENGTH]; char new_full_name[MAXPATHLENGTH], tmp_str[MAXPATHLENGTH]; + char name_without_ext[MAXPATHLENGTH]; FILE * fp; int count = 0, len; *************** *** 210,214 **** --- 211,223 ---- } else if (strcmp (&new_file_name[len-4], ".obj") != 0) + { + strcpy (name_without_ext, new_file_name); strcat (new_file_name, ".obj"); + } + else + { + strcpy (name_without_ext, new_file_name); + name_without_ext[len-4] = '\0'; + } if (strlen (new_file_name) == 4) *************** *** 219,223 **** --- 228,235 ---- } else + { + strcpy (name_without_ext, new_file_name); strcat (new_file_name, ".obj"); + } break; case 1: *************** *** 230,234 **** --- 242,254 ---- } else if (strcmp (&new_file_name[len-4], ".sym") != 0) + { + strcpy (name_without_ext, new_file_name); strcat (new_file_name, ".sym"); + } + else + { + strcpy (name_without_ext, new_file_name); + name_without_ext[len-4] = '\0'; + } if (strlen (new_file_name) == 4) *************** *** 239,243 **** --- 259,266 ---- } else + { + strcpy (name_without_ext, new_file_name); strcat (new_file_name, ".sym"); + } break; default: *************** *** 249,257 **** strcat (new_full_name, new_file_name); else ! { ! strcpy (new_full_name, curDir); ! strcat (new_full_name, "/"); ! strcat (new_full_name, new_file_name); ! } if (!OkayToCreateFile (new_full_name)) return; --- 272,276 ---- strcat (new_full_name, new_file_name); else ! sprintf (new_full_name, "%s/%s", curDir, new_file_name); if (!OkayToCreateFile (new_full_name)) return; *************** *** 266,273 **** strcpy (tmp_str, curDir); SetCurDir (new_full_name); - *curSymDir = '\0'; curFileDefined = TRUE; ! if (strcmp (tmp_str, curDir) != 0) UpdateDirInfo (); sprintf (s, "Saving '%s/%s' ...", curDir, curFileName); --- 285,302 ---- strcpy (tmp_str, curDir); SetCurDir (new_full_name); curFileDefined = TRUE; ! switch (count) ! { ! case 0: ! *curSymDir = '\0'; ! if ((strcmp (tmp_str, curDir) != 0) || (!NameInCurDir (curFileName))) ! UpdateDirInfo (); ! break; ! case 1: ! strcpy (curSymDir, curDir); ! if (!DirInSymPath (curDir)) UpdateSymInfo (); ! break; ! } sprintf (s, "Saving '%s/%s' ...", curDir, curFileName); *************** *** 328,342 **** if (strcmp (ext, "sym") == 0) ! { ! strcpy (full_name, curSymDir); ! strcat (full_name, "/"); ! strcat (full_name, curFileName); ! } else if (strcmp (ext, "obj") == 0) ! { ! strcpy (full_name, curDir); ! strcat (full_name, "/"); ! strcat (full_name, curFileName); ! } if ((fp = fopen (full_name, "w")) == NULL) --- 357,363 ---- if (strcmp (ext, "sym") == 0) ! sprintf (full_name, "%s/%s", curSymDir, curFileName); else if (strcmp (ext, "obj") == 0) ! sprintf (full_name, "%s/%s", curDir, curFileName); if ((fp = fopen (full_name, "w")) == NULL) *************** *** 362,370 **** { register char * s = Str, * l = Left; ! while (*s != '\0' && *s != C) *l++ = *s++; if (*s == C) s++; *l = '\0'; return (s); } --- 383,403 ---- { register char * s = Str, * l = Left; + register int len = 0; ! while (*s != '\0' && *s != C) ! { ! *l++ = *s++; ! len++; ! } if (*s == C) s++; *l = '\0'; + + while (len >= 2 && *Left == '\'' && *(l-1) == '\'') + { + *(--l) = '\0'; + strcpy (Left, &Left[1]); + len -= 2; + } return (s); } *************** *** 425,428 **** --- 458,462 ---- curSpline = LT_STRAIGHT; curFontDPI = FONT_DPI_75; + curDash = 0; } else if (fileVersion <= 7) *************** *** 435,440 **** &curStyle, &curSize); curFontDPI = FONT_DPI_75; } ! else { sscanf (s, "%d , %d , %d , %d , %d , %d , %d , %d , %d , \ --- 469,475 ---- &curStyle, &curSize); curFontDPI = FONT_DPI_75; + curDash = 0; } ! else if (fileVersion <= 8) { sscanf (s, "%d , %d , %d , %d , %d , %d , %d , %d , %d , \ *************** *** 444,451 **** &lineStyle, &objFill, &penPat, &textJust, &curFont, &curStyle, &curSize, &curFontDPI); } if (colorIndex >= maxColors) { ! printf ("Can not find color '%s', use `%s' instead.\n", s, colorMenuItems[defaultColorIndex]); colorIndex = defaultColorIndex; --- 479,496 ---- &lineStyle, &objFill, &penPat, &textJust, &curFont, &curStyle, &curSize, &curFontDPI); + curDash = 0; } + else + { + sscanf (s, "%d , %d , %d , %d , %d , %d , %d , %d , %d , \ + %d , %d , %d , %d , %d , %d , %d , %d , %d , %d", + &drawOrigX, &drawOrigY, &zoomScale, &xyGrid, &gridOn, + &colorIndex, &horiAlign, &vertAlign, &lineWidth, &curSpline, + &lineStyle, &objFill, &penPat, &textJust, &curFont, + &curStyle, &curSize, &curFontDPI, &curDash); + } if (colorIndex >= maxColors) { ! printf ("Can not find color #%1d, use '%s' instead.\n", colorIndex, colorMenuItems[defaultColorIndex]); colorIndex = defaultColorIndex; *************** *** 717,723 **** struct ObjRec * obj_ptr; char file_name[MAXPATHLENGTH], s[MAXPATHLENGTH]; ! char full_name[MAXPATHLENGTH]; FILE * fp; if (SelectFileName ("Please select a file to OPEN ...",file_name) == INVALID) return; --- 762,769 ---- struct ObjRec * obj_ptr; char file_name[MAXPATHLENGTH], s[MAXPATHLENGTH]; ! char full_name[MAXPATHLENGTH], saved_cur_dir[MAXPATHLENGTH]; FILE * fp; + strcpy (saved_cur_dir, curDir); if (SelectFileName ("Please select a file to OPEN ...",file_name) == INVALID) return; *************** *** 734,737 **** --- 780,784 ---- TieLooseEnds (); CleanUpDrawingWindow (); + SetFileModified (FALSE); sprintf (s, "Loading '%s' ...", file_name); Msg (s); *************** *** 759,763 **** curFileDefined = TRUE; ! SetFileModified (FALSE); sprintf (s, "Current file is '%s'.", file_name); Msg (s); --- 806,812 ---- curFileDefined = TRUE; ! if (strcmp (saved_cur_dir, curDir) != 0 && DirInSymPath (".")) ! UpdateSymInfo (); ! sprintf (s, "Current file is '%s'.", file_name); Msg (s); *************** *** 778,781 **** --- 827,831 ---- fprintf (FP, "gsave\n"); + fprintf (FP, " 0 setgray\n"); fprintf (FP, " [4 4] 0 setdash\n"); fprintf (FP, " newpath\n %1d %1d moveto\n", ltx, lty); *************** *** 901,908 **** { if (PRTGIF) ! printf ("Can not create $s, print aborted.", tmp_file); else { ! sprintf (tmp_str, "Can not create %s, print aborted.", tmp_file); Msg (tmp_str); } --- 951,958 ---- { if (PRTGIF) ! printf ("Can not create '%s', print aborted.", tmp_file); else { ! sprintf (tmp_str, "Can not create '%s', print aborted.", tmp_file); Msg (tmp_str); } *************** *** 910,914 **** } ! if (PRTGIF) printf ("Writing to %s ...\n", tmp_file); fprintf (fp, "%%!\n"); --- 960,964 ---- } ! if (PRTGIF) printf ("Writing to '%s' ...\n", tmp_file); fprintf (fp, "%%!\n"); *************** *** 918,925 **** { if (PRTGIF) ! printf ("Can not find %s, print aborted.\n", ps_file); else { ! sprintf (message, "Can not find %s, print aborted.", ps_file); Msg (message); } --- 968,975 ---- { if (PRTGIF) ! printf ("Can not find '%s', print aborted.\n", ps_file); else { ! sprintf (message, "Can not find '%s', print aborted.", ps_file); Msg (message); } *************** *** 1010,1016 **** } ! strcpy (ps_file, curDir); ! strcat (ps_file, "/"); ! strcat (ps_file, curFileName); len = strlen (ps_file); for (i = len-1; ps_file[i] != '.'; i--) ; --- 1060,1064 ---- } ! sprintf (ps_file, "%s/%s", curDir, curFileName); len = strlen (ps_file); for (i = len-1; ps_file[i] != '.'; i--) ; ---------------------------------> cut here <--------------------------------- -- Bill Cheng // UCLA Computer Science Department // (213) 206-7135 3277 Boelter Hall // Los Angeles, California 90024 // USA william@CS.UCLA.EDU ...!{uunet|ucbvax}!cs.ucla.edu!william From news@CS.UCLA.EDU Mon Jan 7 18:37:41 1991 Received: from Shemp.CS.UCLA.EDU by uunet.UU.NET (5.61/1.14) with SMTP id AA02610; Mon, 7 Jan 91 18:37:29 -0500 Received: by shemp.cs.ucla.edu (Sendmail 5.61a+YP/2.33) id AA04286; Mon, 7 Jan 91 15:37:15 -0800 Newsgroups: comp.sources.x Path: oahu.cs.ucla.edu!william From: william@CS.UCLA.EDU (William Cheng) Subject: v07i056-076: tgif, Patch7 (tgif-1.16 => tgif-1.19), Part02/05 Message-Id: <1991Jan7.233701.4234@cs.ucla.edu> Followup-To: william@cs.ucla.edu Originator: william@oahu.cs.ucla.edu Keywords: draw, tool, postscript, latex, hierarchical, x11, xlib, wysiwyg Sender: news@cs.ucla.edu (Mr. News) Nntp-Posting-Host: oahu.cs.ucla.edu Organization: UCLA Computer Science Department Date: Mon, 7 Jan 91 23:37:01 GMT Patch-To: tgif: Volume 7, Issues 56-76 Apparently-To: comp-sources-x@uunet.uu.net Status: O ---------------------------------> cut here <--------------------------------- *** font.c.orig Mon Jan 7 13:03:27 1991 --- font.c Mon Jan 7 13:03:30 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/font.c,v 1.11 90/10/27 15:45:24 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/font.c,v 1.13 90/11/03 12:30:45 william Exp $"; #endif *************** *** 344,352 **** register int dpi_index, font_index, size_index, style_index; { - /* if (font_index == FONT_SYM) */ - /* return (FIndex(font_index,size_index,0)); */ - /* else */ - /* return (FIndex(font_index,size_index,style_index)); */ - if (font_index == FONT_SYM) return (size_index+MAXFONTSIZES*(MAXFONTSTYLES*font_index) + --- 344,347 ---- *************** *** 359,366 **** void SetCanvasFont () { ! register int index; ! canvasFontIndex = index = FontIndex (curFontDPI, curFont, curSize, curStyle); ! if (!myFontInfo[index].valid) { --- 354,360 ---- void SetCanvasFont () { ! register int index, old_index; ! index = FontIndex (curFontDPI, curFont, curSize, curStyle); if (!myFontInfo[index].valid) { *************** *** 368,372 **** XLoadQueryFont (mainDisplay, fontNameStr[index])) == NULL) { ! printf ("Can not open %s. Abort.\n\n", fontNameStr[index]); exit (-1); } myFontInfo[index].valid = TRUE; --- 362,378 ---- XLoadQueryFont (mainDisplay, fontNameStr[index])) == NULL) { ! old_index = index; ! curFontDPI = (curFontDPI==FONT_DPI_75) ? FONT_DPI_100 : FONT_DPI_75; ! index = FontIndex (curFontDPI, curFont, curSize, curStyle); ! if ((myFontInfo[index].xfs = ! XLoadQueryFont (mainDisplay, fontNameStr[index])) == NULL) ! { ! printf ("Can not open '%s' nor\n\t'%s'! Tgif aborted!\n\n", ! fontNameStr[old_index], fontNameStr[index]); ! exit (-1); ! } ! printf ("Warning: can not open '%s' font,\n\tuse '%s' instead.\n", ! fontNameStr[old_index], fontNameStr[index]); ! SetFileModified (TRUE); } myFontInfo[index].valid = TRUE; *************** *** 373,376 **** --- 379,384 ---- } + canvasFontIndex = index; + canvasFontPtr = myFontInfo[index].xfs; canvasFontAsc = canvasFontPtr->max_bounds.ascent; *************** *** 390,409 **** register int i; int ruler_index, default_index; - pointSize = (curFontDPI==FONT_DPI_75) ? pointSize75 : pointSize100; - sizeMenuStr = (curFontDPI==FONT_DPI_75) ? sizeMenuStr75 : sizeMenuStr100; - for (i = 0; i < FONTTABLESIZE; i++) myFontInfo[i].valid = FALSE; ! default_index = COUR18R_75; if ((myFontInfo[default_index].xfs = XLoadQueryFont (mainDisplay, fontNameStr[default_index])) == NULL) { ! default_index = COUR17R_100; if ((myFontInfo[default_index].xfs = XLoadQueryFont (mainDisplay, fontNameStr[default_index])) == NULL) { ! printf ("Can not open %s or %s. Abort.\n\n", ! fontNameStr[COUR18R_75], fontNameStr[COUR17R_100]); exit (-1); } --- 398,423 ---- register int i; int ruler_index, default_index; + int old_ruler_index, old_default_index; for (i = 0; i < FONTTABLESIZE; i++) myFontInfo[i].valid = FALSE; ! curFont = FONT_COU; ! curStyle = STYLE_NR; ! curSize = 4; ! curFontDPI = FONT_DPI_75; ! ! default_index = FontIndex(curFontDPI, curFont, curSize, curStyle); if ((myFontInfo[default_index].xfs = XLoadQueryFont (mainDisplay, fontNameStr[default_index])) == NULL) { ! old_default_index = default_index; ! curSize = 2; ! curFontDPI = FONT_DPI_100; ! default_index = FontIndex(curFontDPI, curFont, curSize, curStyle); if ((myFontInfo[default_index].xfs = XLoadQueryFont (mainDisplay, fontNameStr[default_index])) == NULL) { ! printf ("Can not open '%s' nor\n\t'%s'! Tgif aborted!\n\n", ! fontNameStr[old_default_index], fontNameStr[default_index]); exit (-1); } *************** *** 411,436 **** myFontInfo[default_index].valid = TRUE; ! if (default_index == COUR18R_75) { ! ruler_index = COUR10R_75; if ((myFontInfo[ruler_index].xfs = XLoadQueryFont (mainDisplay, fontNameStr[ruler_index])) == NULL) { ! printf ("Can not open %s. Abort.\n\n", fontNameStr[ruler_index]); exit (-1); } - curFontDPI = FONT_DPI_75; } - else - { - ruler_index = COUR11R_100; - if ((myFontInfo[ruler_index].xfs = - XLoadQueryFont (mainDisplay, fontNameStr[ruler_index])) == NULL) - { - printf ("Can not open %s. Abort.\n\n", fontNameStr[ruler_index]); - exit (-1); - } - curFontDPI = FONT_DPI_100; - } myFontInfo[ruler_index].valid = TRUE; --- 425,442 ---- myFontInfo[default_index].valid = TRUE; ! ruler_index = FontIndex(FONT_DPI_75, curFont, 1, curStyle); ! if ((myFontInfo[ruler_index].xfs = ! XLoadQueryFont (mainDisplay, fontNameStr[ruler_index])) == NULL) { ! old_ruler_index = ruler_index; ! ruler_index = FontIndex(FONT_DPI_100, curFont, 0, curStyle); if ((myFontInfo[ruler_index].xfs = XLoadQueryFont (mainDisplay, fontNameStr[ruler_index])) == NULL) { ! printf ("Can not open '%s' nor\n\t'%s'! Tgif aborted!\n\n", ! fontNameStr[old_ruler_index], fontNameStr[ruler_index]); exit (-1); } } myFontInfo[ruler_index].valid = TRUE; *************** *** 446,449 **** --- 452,458 ---- rulerFontDes = rulerFontPtr->max_bounds.descent; rulerFontHeight = rulerFontAsc + rulerFontDes; + + pointSize = (curFontDPI==FONT_DPI_75) ? pointSize75 : pointSize100; + sizeMenuStr = (curFontDPI==FONT_DPI_75) ? sizeMenuStr75 : sizeMenuStr100; } *** grid.c.orig Mon Jan 7 13:03:37 1991 --- grid.c Mon Jan 7 13:03:39 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/grid.c,v 1.7 90/08/20 13:56:57 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/grid.c,v 1.8 90/11/01 08:42:51 william Exp $"; #endif *************** *** 167,172 **** #define LAYOUT_SLIDELAND 10 #define LAYOUT_SLIDEPORT 11 ! #define LAYOUT_TO_LPR 12 ! #define LAYOUT_TO_TEXFIG 13 #define MAXLAYOUTMENUS 14 --- 167,172 ---- #define LAYOUT_SLIDELAND 10 #define LAYOUT_SLIDEPORT 11 ! #define LAYOUT_TOGGLE_WHERE_TO_PRINT 12 ! #define LAYOUT_TOGGLE_COLOR_PS 13 #define MAXLAYOUTMENUS 14 *************** *** 186,197 **** "SlidePort", "Printer", ! "LaTeX-Figure" }; #define MAX_LAYOUT_STR 13 /* longest string length in layoutMenuStr[] */ ! static char showGridStr[] = "ShowGrid #G"; ! static char hideGridStr[] = "HideGrid #G"; ! static char snapOnStr[] = "SnapOn ^#G"; ! static char snapOffStr[] = "SnapOff ^#G"; void IncGrid () --- 186,201 ---- "SlidePort", "Printer", ! "ColorPS" }; #define MAX_LAYOUT_STR 13 /* longest string length in layoutMenuStr[] */ ! static char showGridStr[] = "ShowGrid #G"; ! static char hideGridStr[] = "HideGrid #G"; ! static char snapOnStr[] = "SnapOn ^#G"; ! static char snapOffStr[] = "SnapOff ^#G"; ! static char printerStr[] = "Printer ^#X"; ! static char latexFigStr[] = "LaTeXFig ^#X"; ! static char bwPostScriptStr[] = "BlkWhtPS ^#K"; ! static char colorPostScriptStr[] = "ColorPS ^#K"; void IncGrid () *************** *** 237,240 **** --- 241,265 ---- } + void ToggleColorPostScript () + { + colorDump = !colorDump; + if (colorDump) + Msg ("PostScript file will print in color."); + else + Msg ("PostScript file will print in black-and-white."); + ShowWhereToPrint (); + } + + void ToggleWhereToPrint () + { + whereToPrint = !whereToPrint; + switch (whereToPrint) + { + case PRINTER: Msg ("Print device set to printer."); break; + case LATEX_FIG: Msg ("Print device set to LaTeX-Figure file."); break; + } + ShowWhereToPrint (); + } + void ZoomIn () { *************** *** 454,457 **** --- 479,490 ---- else strcpy (menu_strings[LAYOUT_SNAP], snapOnStr); + if (whereToPrint == PRINTER) + strcpy (menu_strings[LAYOUT_TOGGLE_WHERE_TO_PRINT], latexFigStr); + else + strcpy (menu_strings[LAYOUT_TOGGLE_WHERE_TO_PRINT], printerStr); + if (colorDump) + strcpy (menu_strings[LAYOUT_TOGGLE_COLOR_PS], bwPostScriptStr); + else + strcpy (menu_strings[LAYOUT_TOGGLE_COLOR_PS], colorPostScriptStr); DefaultColorArrays (MAXLAYOUTMENUS, &fore_colors, &valid); *************** *** 547,566 **** } break; ! case LAYOUT_TO_LPR: ! if (whereToPrint != PRINTER) ! { ! whereToPrint = PRINTER; ! ShowWhereToPrint (); ! Msg ("Print device set to printer."); ! } ! break; ! case LAYOUT_TO_TEXFIG: ! if (whereToPrint != LATEX_FIG) ! { ! whereToPrint = LATEX_FIG; ! ShowWhereToPrint (); ! Msg ("Print device set to LaTeX-Figure file."); ! } ! break; } } --- 580,585 ---- } break; ! case LAYOUT_TOGGLE_WHERE_TO_PRINT: ToggleWhereToPrint (); break; ! case LAYOUT_TOGGLE_COLOR_PS: ToggleColorPostScript (); break; } } *** mainloop.c.orig Mon Jan 7 13:03:46 1991 --- mainloop.c Mon Jan 7 13:03:48 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/mainloop.c,v 1.20 90/10/25 15:02:22 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/mainloop.c,v 1.22 90/11/03 12:42:48 william Exp $"; #endif *************** *** 51,58 **** char s[255]; ! strcpy (s, "xterm -bd red -e "); ! strcat (s, CmdName); ! strcat (s, " "); ! strcat (s, FileName); pid = fork (); if (pid == 0) --- 51,55 ---- char s[255]; ! sprintf (s, "xterm -bd red -e %s %s", CmdName, FileName); pid = fork (); if (pid == 0) *************** *** 152,156 **** char * c_ptr, file_name[MAXPATHLENGTH], s[MAXPATHLENGTH]; char full_name[MAXPATHLENGTH]; ! int shorthand_rc, draw_rc; struct ObjRec * obj_ptr; FILE * fp; --- 149,153 ---- char * c_ptr, file_name[MAXPATHLENGTH], s[MAXPATHLENGTH]; char full_name[MAXPATHLENGTH]; ! int shorthand_rc, draw_rc, len; struct ObjRec * obj_ptr; FILE * fp; *************** *** 184,191 **** if (FileName[0] != '\0') { ! sprintf (file_name, "%s.obj", FileName); if ((fp = fopen (file_name, "r")) == NULL) { ! sprintf (s, "CAN NOT OPEN %s.", file_name); Msg (s); } --- 181,193 ---- if (FileName[0] != '\0') { ! len = strlen (FileName); ! if (len >= 4 && strcmp (&FileName[len-4], ".obj") == 0) ! strcpy (file_name, FileName); ! else ! sprintf (file_name, "%s.obj", FileName); ! if ((fp = fopen (file_name, "r")) == NULL) { ! sprintf (s, "Can not open '%s'.", file_name); Msg (s); } *************** *** 204,212 **** strcat (full_name, file_name); else ! { ! strcpy (full_name, curDir); ! strcat (full_name, "/"); ! strcat (full_name, file_name); ! } SetCurDir (full_name); *curSymDir = '\0'; --- 206,211 ---- strcat (full_name, file_name); else ! sprintf (full_name, "%s/%s", curDir, file_name); ! SetCurDir (full_name); *curSymDir = '\0'; *************** *** 556,563 **** MyFormat(attr_ptr->s); if (attr_ptr->nameshown) ! { ! strcpy (s, attr_ptr->name); ! strcat (s, attr_ptr->s); ! } else strcpy (s, attr_ptr->s); --- 555,559 ---- MyFormat(attr_ptr->s); if (attr_ptr->nameshown) ! sprintf (s, "%s%s", attr_ptr->name, attr_ptr->s); else strcpy (s, attr_ptr->s); *** menu.c.orig Mon Jan 7 13:03:54 1991 --- menu.c Mon Jan 7 13:03:56 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/menu.c,v 1.14 90/10/25 14:58:18 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/menu.c,v 1.15 90/11/01 13:21:34 william Exp $"; #endif *************** *** 42,46 **** static int savedZoomScale = 0, savedDrawOrigX = 0, savedDrawOrigY = 0; ! static int savedDrawWinW = 0, savedDrawWinH = 0; static GC textMenuGC; --- 42,46 ---- static int savedZoomScale = 0, savedDrawOrigX = 0, savedDrawOrigY = 0; ! static int savedDrawWinW = 0, savedDrawWinH = 0, savedFileModified = FALSE; static GC textMenuGC; *************** *** 627,630 **** --- 627,631 ---- savedDrawWinW = drawWinW; savedDrawWinH = drawWinH; + savedFileModified = fileModified; } *************** *** 641,644 **** --- 642,646 ---- drawWinW = savedDrawWinW; drawWinH = savedDrawWinH; + fileModified = savedFileModified; UpdDrawWinBBox (); XMapWindow (mainDisplay, mainWindow); *** move.c.orig Mon Jan 7 13:04:04 1991 --- move.c Mon Jan 7 13:04:07 1991 *************** *** 7,11 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/move.c,v 1.7 90/08/11 00:14:18 william Exp $"; #endif #include <stdio.h> --- 7,11 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/move.c,v 1.9 90/10/31 11:38:53 william Exp $"; #endif #include <stdio.h> *************** *** 207,211 **** case OBJ_BOX: case OBJ_TEXT: ! SelBox (drawWindow, revDefaultGC, ltx+dx, lty+dy, rbx+dx, rby+dy); break; case OBJ_OVAL: --- 207,212 ---- case OBJ_BOX: case OBJ_TEXT: ! SelBox (drawWindow, revDefaultGC, ! ltx+dx, lty+dy, rbx+dx, rby+dy); break; case OBJ_OVAL: *** names.c.orig Mon Jan 7 13:04:52 1991 --- names.c Mon Jan 7 13:05:02 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/names.c,v 1.10 90/10/26 15:40:34 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/names.c,v 1.18 90/11/09 15:06:52 william Exp $"; #endif *************** *** 144,147 **** --- 144,149 ---- { strcpy (path, symPath[path_index]); + if (strcmp (".", path) == 0) strcpy (path, curDir); + if ((dirp = opendir (path)) == NULL) continue; *************** *** 224,228 **** cfree (dsp_ptr); } ! symbolList[numSymbols].next = NULL; topOfSymLinkList = NULL; } --- 226,230 ---- cfree (dsp_ptr); } ! symbolList[numSymbols-1].next = NULL; topOfSymLinkList = NULL; } *************** *** 267,272 **** else { ! strcpy (s, path); ! strcat (s, d->d_name); stat (s, &stat_buf); if (stat_buf.st_mode & S_IFDIR) --- 269,273 ---- else { ! sprintf (s, "%s%s", path, d->d_name); stat (s, &stat_buf); if (stat_buf.st_mode & S_IFDIR) *************** *** 330,334 **** cfree (dsp_ptr); } ! dirList[numDirEntries].next = NULL; topOfDirLinkList = NULL; } --- 331,335 ---- cfree (dsp_ptr); } ! dirList[numDirEntries-1].next = NULL; topOfDirLinkList = NULL; } *************** *** 799,804 **** nameMarked = 0; ! strcpy (full_name, dir_name); ! strcat (full_name, "/"); name[0] = '\0'; name_index = 0; --- 800,804 ---- nameMarked = 0; ! sprintf (full_name, "%s/", dir_name); name[0] = '\0'; name_index = 0; *************** *** 838,842 **** } ! /* if (!grabbed) { XGrabKeyboard (mainDisplay, nameBaseWin, False, --- 838,842 ---- } ! if (!grabbed) { XGrabKeyboard (mainDisplay, nameBaseWin, False, *************** *** 843,847 **** GrabModeAsync, GrabModeAsync, CurrentTime); grabbed = TRUE; ! } */ continue; --- 843,847 ---- GrabModeAsync, GrabModeAsync, CurrentTime); grabbed = TRUE; ! } continue; *************** *** 869,875 **** { name[--name_index] = '\0'; ! strcpy (full_name, dir_name); ! strcat (full_name, "/"); ! strcat (full_name, name); for (i = 0; i < nameEntries; i++) if (strncmp (nameDspPtr[i], name, name_index) == 0) --- 869,873 ---- { name[--name_index] = '\0'; ! sprintf (full_name, "%s/%s", dir_name, name); for (i = 0; i < nameEntries; i++) if (strncmp (nameDspPtr[i], name, name_index) == 0) *************** *** 913,934 **** if (i < nameEntries) { ! if (i < nameFirst) ! nameFirst = i; ! else if (i >= nameFirst+ITEM_DSPED) { ! if (i < nameEntries-ITEM_DSPED) ! nameFirst = i; ! else ! nameFirst = nameEntries-ITEM_DSPED; } ! nameMarked = i; ! strcpy (full_name, dir_name); ! strcat (full_name, "/"); ! strcat (full_name, name); ! RedrawNamePath (full_name, graph_start, ! 3*ROW_HEIGHT+defaultFontAsc+2); ! RedrawNameScrollWin (); ! RedrawDspWindow (); } else --- 911,938 ---- if (i < nameEntries) { ! if (buf[0] == '/') { ! changing = FALSE; ! index = nameMarked = i; } ! else ! { ! if (i < nameFirst) ! nameFirst = i; ! else if (i >= nameFirst+ITEM_DSPED) ! { ! if (i < nameEntries-ITEM_DSPED) ! nameFirst = i; ! else ! nameFirst = nameEntries-ITEM_DSPED; ! } ! nameMarked = i; ! sprintf (full_name, "%s/%s", dir_name, name); ! RedrawNamePath (full_name, graph_start, ! 3*ROW_HEIGHT+defaultFontAsc+2); ! RedrawNameScrollWin (); ! RedrawDspWindow (); ! } } else *************** *** 965,971 **** { strcpy (name, nameDspPtr[nameMarked]); ! strcpy (full_name, dir_name); ! strcat (full_name, "/"); ! strcat (full_name, name); RedrawNamePath (full_name, graph_start, 3*ROW_HEIGHT+defaultFontAsc+2); --- 969,973 ---- { strcpy (name, nameDspPtr[nameMarked]); ! sprintf (full_name, "%s/%s", dir_name, name); RedrawNamePath (full_name, graph_start, 3*ROW_HEIGHT+defaultFontAsc+2); *************** *** 1016,1022 **** if (grabbed) XUngrabKeyboard (mainDisplay, CurrentTime); ! strcpy (SelStr, dir_name); ! strcat (SelStr, "/"); ! strcat (SelStr, sel_str); if (index == INVALID) --- 1018,1022 ---- if (grabbed) XUngrabKeyboard (mainDisplay, CurrentTime); ! sprintf (SelStr, "%s/%s", dir_name, sel_str); if (index == INVALID) *************** *** 1130,1134 **** RedrawDspWindow (); ! /* if (!grabbed) { XGrabKeyboard (mainDisplay, nameBaseWin, False, --- 1130,1134 ---- RedrawDspWindow (); ! if (!grabbed) { XGrabKeyboard (mainDisplay, nameBaseWin, False, *************** *** 1135,1139 **** GrabModeAsync, GrabModeAsync, CurrentTime); grabbed = TRUE; ! } */ continue; --- 1135,1139 ---- GrabModeAsync, GrabModeAsync, CurrentTime); grabbed = TRUE; ! } continue; *************** *** 1308,1320 **** Msg (s); - /* if ((topOfSymLinkList = SymbolListing ()) == NULL) */ - /* { */ - /* Msg ("No symbol found!"); */ - /* SelSymName[0] = '\0'; */ - /* PathName[0] = '\0'; */ - /* return (INVALID); */ - /* } */ - /* BuildSymbolList (); */ - nameEntries = numSymbols; nameDspPtr = MakeNameDspItemArray (nameEntries, symbolList); --- 1308,1311 ---- *************** *** 1355,1358 **** --- 1346,1373 ---- } + int NameInCurDir (FileName) + char * FileName; + { + register int i; + + for (i = 0; i < numDirEntries; i++) + if (dirList[i].directory && strcmp (FileName, dirList[i].itemstr) == 0) + return (TRUE); + + return (FALSE); + } + + int DirInSymPath (DirName) + char * DirName; + { + register int i; + + for (i = 0; i < symPathNumEntries; i++) + if (strcmp (DirName, symPath[i]) == 0) + return (TRUE); + + return (FALSE); + } + static DspList * DomainListing (Entries) *************** *** 1447,1454 **** char file_name[MAXPATHLENGTH]; ! if (*FileName != '/') ! strcpy (file_name, bootDir); ! else ! strcpy (file_name, FileName); for (i = strlen(file_name)-1; i>=0 && file_name[i]!='/'; i--) ; --- 1462,1466 ---- char file_name[MAXPATHLENGTH]; ! strcpy (file_name, FileName); for (i = strlen(file_name)-1; i>=0 && file_name[i]!='/'; i--) ; *************** *** 1455,1460 **** if (i < 0) TwoLineMsg ("Error: No '/' found in SetCurDir ().", ! " curDir and curFileName not set."); else { --- 1467,1476 ---- if (i < 0) + { TwoLineMsg ("Error: No '/' found in SetCurDir ().", ! " curDir set to '.'."); ! strcpy (curDir, "."); ! strcpy (curFileName, FileName); ! } else { *** oval.c.orig Mon Jan 7 13:05:13 1991 --- oval.c Mon Jan 7 13:05:15 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/oval.c,v 1.8 90/10/27 15:10:00 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/oval.c,v 1.11 90/11/10 13:51:00 william Exp $"; #endif *************** *** 93,97 **** struct ObjRec * ObjPtr; { ! int ltx, lty, rbx, rby, xc, yc, a, b, fill, width, pen; ltx = ObjPtr->obbox.ltx; lty = ObjPtr->obbox.lty; --- 93,98 ---- struct ObjRec * ObjPtr; { ! int ltx, lty, rbx, rby, xc, yc, a, b, i; ! int fill, width, pen, dash, color_index; ltx = ObjPtr->obbox.ltx; lty = ObjPtr->obbox.lty; *************** *** 103,109 **** --- 104,120 ---- width = ObjPtr->detail.o->width; pen = ObjPtr->detail.o->pen; + dash = ObjPtr->detail.o->dash; if (fill == NONEPAT && pen == NONEPAT) return; + if (colorDump) + { + color_index = ObjPtr->color; + fprintf (FP, "%.3f %.3f %.3f setrgbcolor\n", + ((float)tgifColors[color_index].red/maxRGB), + ((float)tgifColors[color_index].green/maxRGB), + ((float)tgifColors[color_index].blue/maxRGB)); + } + switch (fill) { *************** *** 128,131 **** --- 139,150 ---- fprintf (FP, "%1d setlinewidth\n", widthOfLine[width]); + if (dash != 0) + { + fprintf (FP, "["); + for (i = 0; i < dashListLength[dash]-1; i++) + fprintf (FP, "%1d ", (int)(dashList[dash][i])); + fprintf (FP, "%1d] 0 setdash\n", + (int)(dashList[dash][dashListLength[dash]-1])); + } switch (pen) *************** *** 147,150 **** --- 166,170 ---- break; } + if (dash != 0) fprintf (FP, "[] 0 setdash\n"); fprintf (FP, "1 setlinewidth\n\n"); } *************** *** 156,160 **** { struct OvalRec * oval_ptr = ObjPtr->detail.o; ! int fill, width, pen, pixel, real_x_off, real_y_off; char s[80]; struct BBRec bbox; --- 176,180 ---- { struct OvalRec * oval_ptr = ObjPtr->detail.o; ! int fill, width, pen, dash, pixel, real_x_off, real_y_off; char s[80]; struct BBRec bbox; *************** *** 171,174 **** --- 191,195 ---- width = ObjPtr->detail.o->width; pen = ObjPtr->detail.o->pen; + dash = ObjPtr->detail.o->dash; pixel = colorPixels[ObjPtr->color]; *************** *** 191,197 **** values.stipple = patPixmap[pen]; values.line_width = widthOfLine[width] >> zoomScale; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth, ! &values); XDrawArc (mainDisplay, window, drawGC, bbox.ltx, bbox.lty, bbox.rbx-bbox.ltx, bbox.rby-bbox.lty, 0, 360*64); --- 212,226 ---- values.stipple = patPixmap[pen]; values.line_width = widthOfLine[width] >> zoomScale; + if (dash != 0) + { + XSetDashes (mainDisplay, drawGC, 0, dashList[dash], + dashListLength[dash]); + values.line_style = LineOnOffDash; + } + else + values.line_style = LineSolid; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth | ! GCLineStyle, &values); XDrawArc (mainDisplay, window, drawGC, bbox.ltx, bbox.lty, bbox.rbx-bbox.ltx, bbox.rby-bbox.lty, 0, 360*64); *************** *** 211,214 **** --- 240,244 ---- oval_ptr->width = lineWidth; oval_ptr->pen = penPat; + oval_ptr->dash = curDash; obj_ptr = (struct ObjRec *) calloc (1, sizeof(struct ObjRec)); *************** *** 257,262 **** values.fill_style = FillSolid; values.line_width = 0; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCLineWidth, &values); grid_x = end_x = OrigX; --- 287,294 ---- values.fill_style = FillSolid; values.line_width = 0; + values.line_style = LineSolid; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCLineWidth | GCLineStyle, ! &values); grid_x = end_x = OrigX; *************** *** 333,341 **** struct ObjRec * ObjPtr; { ! fprintf (FP, "oval(%s,", colorMenuItems[ObjPtr->color]); ! fprintf (FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,", ObjPtr->obbox.ltx, ObjPtr->obbox.lty, ObjPtr->obbox.rbx, ObjPtr->obbox.rby, ObjPtr->detail.o->fill, ObjPtr->detail.o->width, ! ObjPtr->detail.o->pen, ObjPtr->id); SaveAttrs (FP, ObjPtr->lattr); fprintf (FP, ")"); --- 365,373 ---- struct ObjRec * ObjPtr; { ! fprintf (FP, "oval('%s',", colorMenuItems[ObjPtr->color]); ! fprintf (FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,", ObjPtr->obbox.ltx, ObjPtr->obbox.lty, ObjPtr->obbox.rbx, ObjPtr->obbox.rby, ObjPtr->detail.o->fill, ObjPtr->detail.o->width, ! ObjPtr->detail.o->pen, ObjPtr->id, ObjPtr->detail.o->dash); SaveAttrs (FP, ObjPtr->lattr); fprintf (FP, ")"); *************** *** 348,352 **** struct OvalRec * oval_ptr; char color_str[20], * s; ! int ltx, lty, rbx, rby, fill, width, pen, w; * ObjPtr = (struct ObjRec *) calloc (1, sizeof(struct ObjRec)); --- 380,384 ---- struct OvalRec * oval_ptr; char color_str[20], * s; ! int ltx, lty, rbx, rby, fill, width, pen, dash, w; * ObjPtr = (struct ObjRec *) calloc (1, sizeof(struct ObjRec)); *************** *** 365,368 **** --- 397,401 ---- } (*ObjPtr)->id = objId++; + dash = 0; } else if (fileVersion <= 7) *************** *** 371,376 **** <x, <y, &rbx, &rby, &fill, &width, &pen); (*ObjPtr)->id = objId++; } ! else { sscanf (s, "%d , %d, %d , %d , %d , %d , %d , %d", --- 404,410 ---- <x, <y, &rbx, &rby, &fill, &width, &pen); (*ObjPtr)->id = objId++; + dash = 0; } ! else if (fileVersion <= 8) { sscanf (s, "%d , %d, %d , %d , %d , %d , %d , %d", *************** *** 377,381 **** --- 411,423 ---- <x, <y, &rbx, &rby, &fill, &width, &pen, &((*ObjPtr)->id)); if ((*ObjPtr)->id >= objId) objId = (*ObjPtr)->id + 1; + dash = 0; } + else + { + sscanf (s, "%d , %d, %d , %d , %d , %d , %d , %d , %d", + <x, <y, &rbx, &rby, &fill, &width, &pen, &((*ObjPtr)->id), + &dash); + if ((*ObjPtr)->id >= objId) objId = (*ObjPtr)->id + 1; + } oval_ptr->fill = fill; *************** *** 382,385 **** --- 424,428 ---- oval_ptr->width = width; oval_ptr->pen = pen; + oval_ptr->dash = dash; (*ObjPtr)->x = ltx; (*ObjPtr)->y = lty; ---------------------------------> cut here <--------------------------------- -- Bill Cheng // UCLA Computer Science Department // (213) 206-7135 3277 Boelter Hall // Los Angeles, California 90024 // USA william@CS.UCLA.EDU ...!{uunet|ucbvax}!cs.ucla.edu!william From news@CS.UCLA.EDU Mon Jan 7 18:39:55 1991 Received: from Shemp.CS.UCLA.EDU by uunet.UU.NET (5.61/1.14) with SMTP id AA03202; Mon, 7 Jan 91 18:39:40 -0500 Received: by shemp.cs.ucla.edu (Sendmail 5.61a+YP/2.33) id AA04454; Mon, 7 Jan 91 15:39:32 -0800 Newsgroups: comp.sources.x Path: oahu.cs.ucla.edu!william From: william@CS.UCLA.EDU (William Cheng) Subject: v07i056-076: tgif, Patch7 (tgif-1.16 => tgif-1.19), Part03/05 Message-Id: <1991Jan7.233920.4392@cs.ucla.edu> Followup-To: william@cs.ucla.edu Originator: william@oahu.cs.ucla.edu Keywords: draw, tool, postscript, latex, hierarchical, x11, xlib, wysiwyg Sender: news@cs.ucla.edu (Mr. News) Nntp-Posting-Host: oahu.cs.ucla.edu Organization: UCLA Computer Science Department Date: Mon, 7 Jan 91 23:39:20 GMT Patch-To: tgif: Volume 7, Issues 56-76 Apparently-To: comp-sources-x@uunet.uu.net Status: O Submitted-by: William Cheng <william@cs.ucla.edu> ---------------------------------> cut here <--------------------------------- *** pattern.c.orig Mon Jan 7 13:05:27 1991 --- pattern.c Mon Jan 7 13:05:29 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/pattern.c,v 1.4 90/10/27 15:40:34 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/pattern.c,v 1.5 90/10/31 11:37:19 william Exp $"; #endif *************** *** 626,646 **** int index, ltx, lty, rbx, rby, * fore_colors, * valid; ! DefaultColorArrays (MAXLINEWIDTHS+MAXLINETYPES+MAXLINESTYLES, &fore_colors, ! &valid); ! cfree (valid); ! index = PxMpMenuLoop (X, Y, menuImageW, menuImageH, ! MAXLINEWIDTHS+MAXLINETYPES+MAXLINESTYLES, 1, ! MAXLINEWIDTHS+MAXLINETYPES+MAXLINESTYLES, ! fore_colors, lineStylePixmap, SINGLECOLOR); ! if (index == INVALID) return; ! /* DefaultColorArrays (MAXLINEWIDTHS+MAXLINETYPES+MAXDASHES+MAXLINESTYLES, */ ! /* &fore_colors, &valid); */ /* cfree (valid); */ /* index = PxMpMenuLoop (X, Y, menuImageW, menuImageH, */ ! /* MAXLINEWIDTHS+MAXLINETYPES+MAXDASHES+MAXLINESTYLES, 1, */ ! /* MAXLINEWIDTHS+MAXLINETYPES+MAXDASHES+MAXLINESTYLES, */ /* fore_colors, lineStylePixmap, SINGLECOLOR); */ /* if (index == INVALID) return; */ if (index < MAXLINEWIDTHS) ChangeAllSelLineWidth (index); --- 626,647 ---- int index, ltx, lty, rbx, rby, * fore_colors, * valid; ! /* DefaultColorArrays (MAXLINEWIDTHS+MAXLINETYPES+MAXLINESTYLES, &fore_colors, */ ! /* &valid); */ /* cfree (valid); */ /* index = PxMpMenuLoop (X, Y, menuImageW, menuImageH, */ ! /* MAXLINEWIDTHS+MAXLINETYPES+MAXLINESTYLES, 1, */ ! /* MAXLINEWIDTHS+MAXLINETYPES+MAXLINESTYLES, */ /* fore_colors, lineStylePixmap, SINGLECOLOR); */ /* if (index == INVALID) return; */ + DefaultColorArrays (MAXLINEWIDTHS+MAXLINETYPES+MAXDASHES+MAXLINESTYLES, + &fore_colors, &valid); + cfree (valid); + index = PxMpMenuLoop (X, Y, menuImageW, menuImageH, + MAXLINEWIDTHS+MAXLINETYPES+MAXDASHES+MAXLINESTYLES, 1, + MAXLINEWIDTHS+MAXLINETYPES+MAXDASHES+MAXLINESTYLES, + fore_colors, lineStylePixmap, SINGLECOLOR); + if (index == INVALID) return; + if (index < MAXLINEWIDTHS) ChangeAllSelLineWidth (index); *************** *** 647,656 **** else if (index < MAXLINEWIDTHS+MAXLINETYPES) ChangeAllSelLineType (index - MAXLINEWIDTHS); ! /* else if (index < MAXLINEWIDTHS+MAXLINETYPES+MAXDASHES) */ ! /* ChangeAllSelDashes (index - MAXLINEWIDTHS - MAXLINETYPES); */ ! /* else */ ! /* ChangeAllSelLineStyle (index - MAXLINEWIDTHS - MAXLINETYPES - MAXDASHES); */ else ! ChangeAllSelLineStyle (index - MAXLINEWIDTHS - MAXLINETYPES); } --- 648,655 ---- else if (index < MAXLINEWIDTHS+MAXLINETYPES) ChangeAllSelLineType (index - MAXLINEWIDTHS); ! else if (index < MAXLINEWIDTHS+MAXLINETYPES+MAXDASHES) ! ChangeAllSelDashes (index - MAXLINEWIDTHS - MAXLINETYPES); else ! ChangeAllSelLineStyle (index - MAXLINEWIDTHS - MAXLINETYPES - MAXDASHES); } *** poly.c.orig Mon Jan 7 13:05:51 1991 --- poly.c Mon Jan 7 13:05:54 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/poly.c,v 1.7 90/10/27 15:10:15 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/poly.c,v 1.10 90/11/10 13:51:04 william Exp $"; #endif *************** *** 117,120 **** --- 117,121 ---- poly_ptr->curved = curSpline; poly_ptr->fill = objFill; + poly_ptr->dash = curDash; obj_ptr = (struct ObjRec *) calloc (1, sizeof(struct ObjRec)); obj_ptr->color = colorIndex; *************** *** 175,181 **** */ ! void MyLine (Win,Cont,Rb,N,StartX,StartY,EndX,EndY,W,S,P,Pix) Window Win; ! int Cont, Rb, N, StartX, StartY, EndX, EndY, W, S, P, Pix; /* 'Cont' means continue */ /* 'Rb' means rubber-band */ --- 176,182 ---- */ ! void MyLine (Win,Cont,Rb,N,StartX,StartY,EndX,EndY,W,S,P,Pix,Dash) Window Win; ! int Cont, Rb, N, StartX, StartY, EndX, EndY, W, S, P, Pix, Dash; /* 'Cont' means continue */ /* 'Rb' means rubber-band */ *************** *** 245,250 **** values.fill_style = FillSolid; values.line_width = 0; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCLineWidth, &values); } else if (P != 0) --- 246,253 ---- values.fill_style = FillSolid; values.line_width = 0; + values.line_style = LineSolid; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCLineWidth | GCLineStyle, ! &values); } else if (P != 0) *************** *** 255,261 **** values.stipple = patPixmap[P]; values.line_width = widthOfLine[W] >> zoomScale; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth, ! &values); } else --- 258,272 ---- values.stipple = patPixmap[P]; values.line_width = widthOfLine[W] >> zoomScale; + if (Dash != 0) + { + XSetDashes (mainDisplay, drawGC, 0, dashList[Dash], + dashListLength[Dash]); + values.line_style = LineOnOffDash; + } + else + values.line_style = LineSolid; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth | ! GCLineStyle, &values); } else *************** *** 344,350 **** values.fill_style = FillSolid; values.line_width = 0; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCLineWidth, &values); --- 355,362 ---- values.fill_style = FillSolid; values.line_width = 0; + values.line_style = LineSolid; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCLineWidth | GCLineStyle, &values); *************** *** 362,366 **** motion_ev = &(input.xmotion); MyLine (drawWindow, CONT, RB, num_pts, OrigX, OrigY, grid_x, ! grid_y, lineWidth, lineStyle, penPat, xor_pixel); end_x = motion_ev->x; --- 374,378 ---- motion_ev = &(input.xmotion); MyLine (drawWindow, CONT, RB, num_pts, OrigX, OrigY, grid_x, ! grid_y, lineWidth, lineStyle, penPat, xor_pixel,0); end_x = motion_ev->x; *************** *** 369,373 **** MarkRulers (grid_x, grid_y); MyLine (drawWindow, CONT, RB, num_pts, OrigX, OrigY, grid_x, ! grid_y, lineWidth, lineStyle, penPat, xor_pixel); while (XCheckMaskEvent (mainDisplay, PointerMotionMask, &ev)) ; } --- 381,385 ---- MarkRulers (grid_x, grid_y); MyLine (drawWindow, CONT, RB, num_pts, OrigX, OrigY, grid_x, ! grid_y, lineWidth, lineStyle, penPat, xor_pixel,0); while (XCheckMaskEvent (mainDisplay, PointerMotionMask, &ev)) ; } *************** *** 376,380 **** button_ev = &(input.xbutton); MyLine (drawWindow, CONT, RB, num_pts, OrigX, OrigY, grid_x, ! grid_y, lineWidth, lineStyle, penPat, xor_pixel); GridXY (end_x, end_y, &grid_x, &grid_y); --- 388,392 ---- button_ev = &(input.xbutton); MyLine (drawWindow, CONT, RB, num_pts, OrigX, OrigY, grid_x, ! grid_y, lineWidth, lineStyle, penPat, xor_pixel,0); GridXY (end_x, end_y, &grid_x, &grid_y); *************** *** 394,398 **** MyLine (drawWindow, CONT, NORB, num_pts-1, OrigX, OrigY, grid_x, grid_y, lineWidth, lineStyle, penPat, ! pixel); OrigX = grid_x; OrigY = grid_y; --- 406,410 ---- MyLine (drawWindow, CONT, NORB, num_pts-1, OrigX, OrigY, grid_x, grid_y, lineWidth, lineStyle, penPat, ! pixel,0); OrigX = grid_x; OrigY = grid_y; *************** *** 404,408 **** MyLine (drawWindow, NOCONT, NORB, num_pts-1, OrigX, OrigY, grid_x, grid_y, lineWidth, lineStyle, ! penPat, pixel); done = TRUE; --- 416,420 ---- MyLine (drawWindow, NOCONT, NORB, num_pts-1, OrigX, OrigY, grid_x, grid_y, lineWidth, lineStyle, ! penPat, pixel,0); done = TRUE; *************** *** 416,424 **** { CreatePolyObj (num_pts); ! if (topObj->detail.p->curved == LT_SPLINE || ! topObj->detail.p->fill != NONEPAT) ! RedrawAnArea (botObj, topObj->bbox.ltx-(1<<zoomScale), ! topObj->bbox.lty-(1<<zoomScale), topObj->bbox.rbx+(1<<zoomScale), ! topObj->bbox.rby+(1<<zoomScale)); polyDrawn = TRUE; SetFileModified (TRUE); --- 428,434 ---- { CreatePolyObj (num_pts); ! RedrawAnArea (botObj, topObj->bbox.ltx-(1<<zoomScale), ! topObj->bbox.lty-(1<<zoomScale), topObj->bbox.rbx+(1<<zoomScale), ! topObj->bbox.rby+(1<<zoomScale)); polyDrawn = TRUE; SetFileModified (TRUE); *************** *** 473,477 **** { XPoint * v; ! int num_pts, fill, pen, width, curved, w, aw, ah, dy, dx; fill = ObjPtr->detail.p->fill; --- 483,488 ---- { XPoint * v; ! int i, num_pts, fill, pen, width, curved, dash, color_index; ! int w, aw, ah, dy, dx; fill = ObjPtr->detail.p->fill; *************** *** 479,485 **** --- 490,508 ---- pen = ObjPtr->detail.p->pen; curved = ObjPtr->detail.p->curved; + dash = ObjPtr->detail.p->dash; v = ObjPtr->detail.p->vlist; num_pts = ObjPtr->detail.p->n; + if (fill == NONEPAT && pen == NONEPAT) return; + + if (colorDump) + { + color_index = ObjPtr->color; + fprintf (FP, "%.3f %.3f %.3f setrgbcolor\n", + ((float)tgifColors[color_index].red/maxRGB), + ((float)tgifColors[color_index].green/maxRGB), + ((float)tgifColors[color_index].blue/maxRGB)); + } + if (fill != NONEPAT && num_pts > 2) { *************** *** 545,549 **** } ! if (pen == NONEPAT) return; fprintf (FP, "gsave\n"); --- 568,573 ---- } ! if (pen == NONEPAT) { fprintf (FP, "\n"); return; } ! fprintf (FP, "gsave\n"); *************** *** 562,565 **** --- 586,597 ---- fprintf (FP, " %1d setlinewidth\n", w); + if (dash != 0) + { + fprintf (FP, " ["); + for (i = 0; i < dashListLength[dash]-1; i++) + fprintf (FP, "%1d ", (int)(dashList[dash][i])); + fprintf (FP, "%1d] 0 setdash\n", + (int)(dashList[dash][dashListLength[dash]-1])); + } fprintf (FP, "newpath\n %1d %1d moveto\n", v[0].x, v[0].y); *************** *** 622,626 **** register struct PolyRec * poly_ptr = ObjPtr->detail.p; XPoint * pv = poly_ptr->vlist, * v; ! int pen, width, pixel, fill, curved, n; int x1, y1, x2, y2, ah, real_x_off, real_y_off; Pixmap tile; --- 654,658 ---- register struct PolyRec * poly_ptr = ObjPtr->detail.p; XPoint * pv = poly_ptr->vlist, * v; ! int pen, width, pixel, fill, curved, n, dash; int x1, y1, x2, y2, ah, real_x_off, real_y_off; Pixmap tile; *************** *** 632,639 **** pen = poly_ptr->pen; curved = poly_ptr->curved; pixel = colorPixels[ObjPtr->color]; if (curved == LT_SPLINE) ! DrawSplinePolyObj (Win, XOff, YOff, fill, width, pen, pixel, poly_ptr); else { --- 664,673 ---- pen = poly_ptr->pen; curved = poly_ptr->curved; + dash = poly_ptr->dash; pixel = colorPixels[ObjPtr->color]; if (curved == LT_SPLINE) ! DrawSplinePolyObj (Win, XOff, YOff, fill, width, pen, dash, pixel, ! poly_ptr); else { *************** *** 671,675 **** MyLine (Win, CONT, NORB, i+1, x1, y1, x2, y2, poly_ptr->width, ! poly_ptr->style, pen, pixel); } x1 = (pv[i].x-real_x_off)>>zoomScale; --- 705,709 ---- MyLine (Win, CONT, NORB, i+1, x1, y1, x2, y2, poly_ptr->width, ! poly_ptr->style, pen, pixel, dash); } x1 = (pv[i].x-real_x_off)>>zoomScale; *************** *** 679,683 **** MyLine (Win, NOCONT, NORB, i+1, x1, y1, x2, y2, poly_ptr->width, ! poly_ptr->style, pen, pixel); } } --- 713,717 ---- MyLine (Win, NOCONT, NORB, i+1, x1, y1, x2, y2, poly_ptr->width, ! poly_ptr->style, pen, pixel, dash); } } *************** *** 691,695 **** n = poly_ptr->n; ! fprintf (FP, "poly(%s,%1d,[", colorMenuItems[ObjPtr->color], poly_ptr->n); for (i = 0; i < n-1; i++) { --- 725,729 ---- n = poly_ptr->n; ! fprintf (FP, "poly('%s',%1d,[", colorMenuItems[ObjPtr->color], poly_ptr->n); for (i = 0; i < n-1; i++) { *************** *** 697,702 **** } fprintf (FP, "%1d,%1d", poly_ptr->vlist[n-1].x, poly_ptr->vlist[n-1].y); ! fprintf (FP, "],%1d,%1d,%1d,%1d,%1d,%1d,", poly_ptr->style, poly_ptr->width, ! poly_ptr->pen, ObjPtr->id, poly_ptr->curved, poly_ptr->fill); SaveAttrs (FP, ObjPtr->lattr); fprintf (FP, ")"); --- 731,736 ---- } fprintf (FP, "%1d,%1d", poly_ptr->vlist[n-1].x, poly_ptr->vlist[n-1].y); ! fprintf (FP, "],%1d,%1d,%1d,%1d,%1d,%1d,%1d,", poly_ptr->style, poly_ptr->width, ! poly_ptr->pen, ObjPtr->id, poly_ptr->curved, poly_ptr->fill, poly_ptr->dash); SaveAttrs (FP, ObjPtr->lattr); fprintf (FP, ")"); *************** *** 754,757 **** --- 788,792 ---- case 2: poly_ptr->width = 6; break; } + poly_ptr->dash = 0; } else if (fileVersion <= 3) *************** *** 773,776 **** --- 808,812 ---- case 2: poly_ptr->width = 6; break; } + poly_ptr->dash = 0; } else if (fileVersion <= 4) *************** *** 786,789 **** --- 822,826 ---- case 2: poly_ptr->width = 6; break; } + poly_ptr->dash = 0; } else if (fileVersion <= 5) *************** *** 798,803 **** case 2: poly_ptr->width = 6; break; } } ! else { sscanf (s, "%d , %d , %d , %d, %d, %d", &(poly_ptr->style), --- 835,841 ---- case 2: poly_ptr->width = 6; break; } + poly_ptr->dash = 0; } ! else if (fileVersion <= 8) { sscanf (s, "%d , %d , %d , %d, %d, %d", &(poly_ptr->style), *************** *** 804,807 **** --- 842,853 ---- &(poly_ptr->width), &(poly_ptr->pen), &((*ObjPtr)->id), &(poly_ptr->curved), &(poly_ptr->fill)); + if ((*ObjPtr)->id >= objId) objId = (*ObjPtr)->id + 1; + poly_ptr->dash = 0; + } + else + { + sscanf (s, "%d , %d , %d , %d , %d , %d , %d", &(poly_ptr->style), + &(poly_ptr->width), &(poly_ptr->pen), &((*ObjPtr)->id), + &(poly_ptr->curved), &(poly_ptr->fill), &(poly_ptr->dash)); if ((*ObjPtr)->id >= objId) objId = (*ObjPtr)->id + 1; } *** polygon.c.orig Mon Jan 7 13:06:06 1991 --- polygon.c Mon Jan 7 13:06:09 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/polygon.c,v 1.6 90/10/27 15:10:32 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/polygon.c,v 1.9 90/11/10 13:51:09 william Exp $"; #endif *************** *** 52,56 **** { XPoint * v = ObjPtr->detail.g->vlist; ! int num_pts = ObjPtr->detail.g->n, fill, width, pen, curved; fill = ObjPtr->detail.g->fill; --- 52,57 ---- { XPoint * v = ObjPtr->detail.g->vlist; ! int num_pts = ObjPtr->detail.g->n, i; ! int fill, width, pen, curved, dash, color_index; fill = ObjPtr->detail.g->fill; *************** *** 58,62 **** --- 59,75 ---- pen = ObjPtr->detail.g->pen; curved = ObjPtr->detail.g->curved; + dash = ObjPtr->detail.g->dash; + if (fill == NONEPAT && pen == NONEPAT) return; + + if (colorDump) + { + color_index = ObjPtr->color; + fprintf (FP, "%.3f %.3f %.3f setrgbcolor\n", + ((float)tgifColors[color_index].red/maxRGB), + ((float)tgifColors[color_index].green/maxRGB), + ((float)tgifColors[color_index].blue/maxRGB)); + } + if (fill != NONEPAT) { *************** *** 115,177 **** } ! if (pen != NONEPAT) { ! fprintf (FP, "%1d setlinewidth\n", widthOfLine[width]); ! switch (curved) ! { ! case LT_STRAIGHT: ! switch (pen) ! { ! case SOLIDPAT: ! fprintf (FP, "newpath\n %1d %1d moveto\n", v[0].x, v[0].y); ! DumpPoints (FP, num_pts-1, v, 3); ! fprintf (FP, "closepath stroke\n"); ! break; ! case BACKPAT: ! fprintf (FP, "newpath\n %1d %1d moveto\n", v[0].x, v[0].y); ! DumpPoints (FP, num_pts-1, v, 3); ! fprintf (FP, "closepath 1 setgray stroke 0 setgray\n"); ! break; ! default: ! fprintf (FP, "gsave\n"); ! fprintf (FP, " pat%1d 8 1 0 72 300 32 div div setpattern\n", ! pen); ! fprintf (FP, " newpath\n"); ! fprintf (FP, " %1d %1d moveto\n", v[0].x, v[0].y); ! DumpPoints (FP, num_pts-1, v, 6); ! fprintf (FP, " closepath stroke\n"); ! fprintf (FP, "grestore\n"); ! break; ! } ! break; ! case LT_SPLINE: ! switch (pen) ! { ! case SOLIDPAT: ! fprintf (FP, "newpath\n"); ! DumpCurvedPolygonPoints (FP, num_pts, v, 3); ! fprintf (FP, "closepath stroke\n"); ! break; ! case BACKPAT: ! fprintf (FP, "newpath\n"); ! DumpCurvedPolygonPoints (FP, num_pts, v, 3); ! fprintf (FP, "closepath 1 setgray stroke 0 setgray\n"); ! break; ! default: ! fprintf (FP, "gsave\n"); ! fprintf (FP, " pat%1d 8 1 0 72 300 32 div div setpattern\n", ! pen); ! fprintf (FP, " newpath\n"); ! DumpCurvedPolygonPoints (FP, num_pts, v, 6); ! fprintf (FP, " closepath stroke\n"); ! fprintf (FP, "grestore\n"); ! break; ! } ! break; ! } ! fprintf (FP, "1 setlinewidth\n"); } ! fprintf (FP, "\n"); } --- 128,197 ---- } ! if (pen == NONEPAT) { fprintf (FP, "\n"); return; } ! ! fprintf (FP, "%1d setlinewidth\n", widthOfLine[width]); ! if (dash != 0) { ! fprintf (FP, "["); ! for (i = 0; i < dashListLength[dash]-1; i++) ! fprintf (FP, "%1d ", (int)(dashList[dash][i])); ! fprintf (FP, "%1d] 0 setdash\n", ! (int)(dashList[dash][dashListLength[dash]-1])); ! } ! switch (curved) ! { ! case LT_STRAIGHT: ! switch (pen) ! { ! case SOLIDPAT: ! fprintf (FP, "newpath\n %1d %1d moveto\n", v[0].x, v[0].y); ! DumpPoints (FP, num_pts-1, v, 3); ! fprintf (FP, "closepath stroke\n"); ! break; ! case BACKPAT: ! fprintf (FP, "newpath\n %1d %1d moveto\n", v[0].x, v[0].y); ! DumpPoints (FP, num_pts-1, v, 3); ! fprintf (FP, "closepath 1 setgray stroke 0 setgray\n"); ! break; ! default: ! fprintf (FP, "gsave\n"); ! fprintf (FP, " pat%1d 8 1 0 72 300 32 div div setpattern\n", ! pen); ! fprintf (FP, " newpath\n"); ! fprintf (FP, " %1d %1d moveto\n", v[0].x, v[0].y); ! DumpPoints (FP, num_pts-1, v, 6); ! fprintf (FP, " closepath stroke\n"); ! fprintf (FP, "grestore\n"); ! break; ! } ! break; ! case LT_SPLINE: ! switch (pen) ! { ! case SOLIDPAT: ! fprintf (FP, "newpath\n"); ! DumpCurvedPolygonPoints (FP, num_pts, v, 3); ! fprintf (FP, "closepath stroke\n"); ! break; ! case BACKPAT: ! fprintf (FP, "newpath\n"); ! DumpCurvedPolygonPoints (FP, num_pts, v, 3); ! fprintf (FP, "closepath 1 setgray stroke 0 setgray\n"); ! break; ! default: ! fprintf (FP, "gsave\n"); ! fprintf (FP, " pat%1d 8 1 0 72 300 32 div div setpattern\n", ! pen); ! fprintf (FP, " newpath\n"); ! DumpCurvedPolygonPoints (FP, num_pts, v, 6); ! fprintf (FP, " closepath stroke\n"); ! fprintf (FP, "grestore\n"); ! break; ! } ! break; } ! if (dash != 0) fprintf (FP, "[] 0 setdash\n"); ! fprintf (FP, "1 setlinewidth\n\n"); } *************** *** 184,188 **** XPoint * v; struct PolygonRec * polygon_ptr = ObjPtr->detail.g; ! int fill, width, pen, curved, pixel; int real_x_off, real_y_off; XGCValues values; --- 204,208 ---- XPoint * v; struct PolygonRec * polygon_ptr = ObjPtr->detail.g; ! int fill, width, pen, curved, dash, pixel; int real_x_off, real_y_off; XGCValues values; *************** *** 192,199 **** pen = polygon_ptr->pen; curved = polygon_ptr->curved; pixel = colorPixels[ObjPtr->color]; if (curved == LT_SPLINE) ! DrawSplinePolygonObj (Win, XOff, YOff, fill, width, pen, pixel, polygon_ptr); else --- 212,220 ---- pen = polygon_ptr->pen; curved = polygon_ptr->curved; + dash = polygon_ptr->dash; pixel = colorPixels[ObjPtr->color]; if (curved == LT_SPLINE) ! DrawSplinePolygonObj (Win, XOff, YOff, fill, width, pen, dash, pixel, polygon_ptr); else *************** *** 228,234 **** values.stipple = patPixmap[pen]; values.line_width = widthOfLine[width] >> zoomScale; XChangeGC (mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple | ! GCLineWidth, &values); XDrawLines (mainDisplay, Win, drawGC, v, polygon_ptr->n, --- 249,263 ---- values.stipple = patPixmap[pen]; values.line_width = widthOfLine[width] >> zoomScale; + if (dash != 0) + { + XSetDashes (mainDisplay, drawGC, 0, dashList[dash], + dashListLength[dash]); + values.line_style = LineOnOffDash; + } + else + values.line_style = LineSolid; XChangeGC (mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple | ! GCLineWidth | GCLineStyle, &values); XDrawLines (mainDisplay, Win, drawGC, v, polygon_ptr->n, *************** *** 274,277 **** --- 303,307 ---- polygon_ptr->pen = penPat; polygon_ptr->curved = curSpline; + polygon_ptr->dash = curDash; obj_ptr = (struct ObjRec *) calloc (1, sizeof(struct ObjRec)); obj_ptr->color = colorIndex; *************** *** 320,326 **** values.fill_style = FillSolid; values.line_width = 0; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCLineWidth, &values); --- 350,357 ---- values.fill_style = FillSolid; values.line_width = 0; + values.line_style = LineSolid; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCLineWidth | GCLineStyle, &values); *************** *** 450,461 **** default: CreatePolygonObj (num_pts); ! if (topObj->detail.g->curved == LT_SPLINE) ! RedrawAnArea (botObj, topObj->bbox.ltx-(1<<zoomScale), ! topObj->bbox.lty-(1<<zoomScale), ! topObj->bbox.rbx+(1<<zoomScale), ! topObj->bbox.rby+(1<<zoomScale)); ! else if (objFill != 0) ! DrawPolygonObj (drawWindow, drawOrigX, drawOrigY, topObj); ! polygonDrawn = TRUE; SetFileModified (TRUE); --- 481,488 ---- default: CreatePolygonObj (num_pts); ! RedrawAnArea (botObj, topObj->bbox.ltx-(1<<zoomScale), ! topObj->bbox.lty-(1<<zoomScale), ! topObj->bbox.rbx+(1<<zoomScale), ! topObj->bbox.rby+(1<<zoomScale)); polygonDrawn = TRUE; SetFileModified (TRUE); *************** *** 497,501 **** n = polygon_ptr->n; ! fprintf (FP, "polygon(%s,%1d,[", colorMenuItems[ObjPtr->color], polygon_ptr->n); for (i = 0; i < n-1; i++) --- 524,528 ---- n = polygon_ptr->n; ! fprintf (FP, "polygon('%s',%1d,[", colorMenuItems[ObjPtr->color], polygon_ptr->n); for (i = 0; i < n-1; i++) *************** *** 502,508 **** fprintf (FP, "%1d,%1d,", polygon_ptr->vlist[i].x, polygon_ptr->vlist[i].y); ! fprintf (FP, "%1d,%1d],%1d,%1d,%1d,%1d,%1d,", polygon_ptr->vlist[n-1].x, polygon_ptr->vlist[n-1].y, polygon_ptr->fill, polygon_ptr->width, ! polygon_ptr->pen, polygon_ptr->curved, ObjPtr->id); SaveAttrs (FP, ObjPtr->lattr); fprintf (FP, ")"); --- 529,535 ---- fprintf (FP, "%1d,%1d,", polygon_ptr->vlist[i].x, polygon_ptr->vlist[i].y); ! fprintf (FP, "%1d,%1d],%1d,%1d,%1d,%1d,%1d,%1d,", polygon_ptr->vlist[n-1].x, polygon_ptr->vlist[n-1].y, polygon_ptr->fill, polygon_ptr->width, ! polygon_ptr->pen, polygon_ptr->curved, ObjPtr->id, polygon_ptr->dash); SaveAttrs (FP, ObjPtr->lattr); fprintf (FP, ")"); *************** *** 518,522 **** char color_str[20], * s; int num_pts, ltx, lty, rbx, rby, x, y, fill, width, pen, w; ! int curved; * ObjPtr = (struct ObjRec *) calloc (1, sizeof(struct ObjRec)); --- 545,549 ---- char color_str[20], * s; int num_pts, ltx, lty, rbx, rby, x, y, fill, width, pen, w; ! int curved, dash; * ObjPtr = (struct ObjRec *) calloc (1, sizeof(struct ObjRec)); *************** *** 559,562 **** --- 586,590 ---- } (*ObjPtr)->id = objId++; + dash = 0; } else if (fileVersion <= 5) *************** *** 569,572 **** --- 597,601 ---- } (*ObjPtr)->id = objId++; + dash = 0; } else if (fileVersion <= 7) *************** *** 574,579 **** sscanf (s, "%d , %d , %d , %d", &fill, &width, &pen, &curved); (*ObjPtr)->id = objId++; } ! else { sscanf (s, "%d , %d , %d , %d , %d", &fill, &width, &pen, &curved, --- 603,609 ---- sscanf (s, "%d , %d , %d , %d", &fill, &width, &pen, &curved); (*ObjPtr)->id = objId++; + dash = 0; } ! else if (fileVersion <= 8) { sscanf (s, "%d , %d , %d , %d , %d", &fill, &width, &pen, &curved, *************** *** 580,584 **** --- 610,621 ---- &((*ObjPtr)->id)); if ((*ObjPtr)->id >= objId) objId = (*ObjPtr)->id + 1; + dash = 0; } + else + { + sscanf (s, "%d , %d , %d , %d , %d , %d", &fill, &width, &pen, &curved, + &((*ObjPtr)->id), &dash); + if ((*ObjPtr)->id >= objId) objId = (*ObjPtr)->id + 1; + } polygon_ptr->vlist = v; *************** *** 590,593 **** --- 627,631 ---- polygon_ptr->pen = pen; polygon_ptr->curved = curved; + polygon_ptr->dash = dash; (*ObjPtr)->x = ltx; (*ObjPtr)->y = lty; *** prtgif.c.orig Mon Jan 7 13:06:15 1991 --- prtgif.c Mon Jan 7 13:06:18 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/prtgif.c,v 1.16 90/08/16 15:28:30 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/prtgif.c,v 1.17 90/11/01 13:49:48 william Exp $"; #endif *************** *** 108,119 **** struct ObjRec * obj_ptr; char full_name[MAXPATHLENGTH]; FILE * fp; ! strcpy (full_name, FileName); ! strcat (full_name, ".obj"); if ((fp = fopen (full_name, "r")) == NULL) { ! printf ("Can not open '%s'.", full_name); return (FALSE); } --- 108,123 ---- struct ObjRec * obj_ptr; char full_name[MAXPATHLENGTH]; + int len; FILE * fp; ! len = strlen (FileName); ! if (len >= 4 && strcmp (&FileName[len-4], ".obj") == 0) ! strcpy (full_name, FileName); ! else ! sprintf (full_name, "%s.obj", FileName); if ((fp = fopen (full_name, "r")) == NULL) { ! printf ("Can not open '%s'.\n", full_name); return (FALSE); } *** raster.c.orig Mon Jan 7 13:06:24 1991 --- raster.c Mon Jan 7 13:06:26 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/raster.c,v 1.7 90/10/27 16:09:36 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/raster.c,v 1.8 90/11/01 08:44:35 william Exp $"; #endif *************** *** 82,85 **** --- 82,86 ---- #include "bitmaps/ld2.bm" #include "bitmaps/ld3.bm" + #include "bitmaps/ld4.bm" #include "bitmaps/lw0s.bm" *************** *** 103,106 **** --- 104,108 ---- #include "bitmaps/ld2s.bm" #include "bitmaps/ld3s.bm" + #include "bitmaps/ld4s.bm" #include "bitmaps/printer.bm" *************** *** 107,110 **** --- 109,119 ---- #include "bitmaps/latex.bm" + #include "bitmaps/file.bm" + #include "bitmaps/special.bm" + #include "bitmaps/rotate_0.bm" + #include "bitmaps/rotate_90.bm" + #include "bitmaps/rotate_180.bm" + #include "bitmaps/rotate_270.bm" + GC rasterGC; *************** *** 125,128 **** --- 134,140 ---- Pixmap alignVertPixmap[MAXALIGNS]; Pixmap shortLineWidthPixmap[MAXLINEWIDTHS]; + Pixmap filePixmap; + Pixmap specialPixmap; + Pixmap rotatePixmap[4]; Pixmap whereToPrintPixmap[2]; Pixmap shortLineTypePixmap[MAXLINETYPES]; *************** *** 131,136 **** int pat_w[MAXPATTERNS+1], pat_h[MAXPATTERNS+1]; ! int dashListLength[MAXDASHES] = { 0, 2, 2, 4 }; ! char * dashList[MAXDASHES] = {"","\004\004","\006\002","\012\002\002\002"}; static char * patData[MAXPATTERNS+1]; --- 143,149 ---- int pat_w[MAXPATTERNS+1], pat_h[MAXPATTERNS+1]; ! int dashListLength[MAXDASHES] = { 0, 2, 2, 2, 4 }; ! char * dashList[MAXDASHES] = ! {"","\004\014","\010\010","\014\004","\024\004\004\004"}; static char * patData[MAXPATTERNS+1]; *************** *** 238,249 **** lt1_bits, lt1_width, lt1_height); ! /* dashPixmap[0] = XCreateBitmapFromData (mainDisplay, mainWindow, */ ! /* ld0_bits, ld0_width, ld0_height); */ ! /* dashPixmap[1] = XCreateBitmapFromData (mainDisplay, mainWindow, */ ! /* ld1_bits, ld1_width, ld1_height); */ ! /* dashPixmap[2] = XCreateBitmapFromData (mainDisplay, mainWindow, */ ! /* ld2_bits, ld2_width, ld2_height); */ ! /* dashPixmap[3] = XCreateBitmapFromData (mainDisplay, mainWindow, */ ! /* ld3_bits, ld3_width, ld3_height); */ lineStylePixmap[0] = XCreateBitmapFromData (mainDisplay, mainWindow, --- 251,264 ---- lt1_bits, lt1_width, lt1_height); ! dashPixmap[0] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ld0_bits, ld0_width, ld0_height); ! dashPixmap[1] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ld1_bits, ld1_width, ld1_height); ! dashPixmap[2] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ld2_bits, ld2_width, ld2_height); ! dashPixmap[3] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ld3_bits, ld3_width, ld3_height); ! dashPixmap[4] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ld4_bits, ld4_width, ld4_height); lineStylePixmap[0] = XCreateBitmapFromData (mainDisplay, mainWindow, *************** *** 267,295 **** lt1_bits, lt1_width, lt1_height); - /* lineStylePixmap[9] = XCreateBitmapFromData (mainDisplay, mainWindow, */ - /* ld0_bits, ld0_width, ld0_height); */ - /* lineStylePixmap[10] = XCreateBitmapFromData (mainDisplay, mainWindow, */ - /* ld1_bits, ld1_width, ld1_height); */ - /* lineStylePixmap[11] = XCreateBitmapFromData (mainDisplay, mainWindow, */ - /* ld2_bits, ld2_width, ld2_height); */ - /* lineStylePixmap[12] = XCreateBitmapFromData (mainDisplay, mainWindow, */ - /* ld3_bits, ld3_width, ld3_height); */ - - /* lineStylePixmap[13] = XCreateBitmapFromData (mainDisplay, mainWindow, */ - /* ls0_bits, ls0_width, ls0_height); */ - /* lineStylePixmap[14] = XCreateBitmapFromData (mainDisplay, mainWindow, */ - /* ls1_bits, ls1_width, ls1_height); */ - /* lineStylePixmap[15] = XCreateBitmapFromData (mainDisplay, mainWindow, */ - /* ls2_bits, ls2_width, ls2_height); */ - /* lineStylePixmap[16] = XCreateBitmapFromData (mainDisplay, mainWindow, */ - /* ls3_bits, ls3_width, ls3_height); */ - lineStylePixmap[9] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ls0_bits, ls0_width, ls0_height); lineStylePixmap[10] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ls1_bits, ls1_width, ls1_height); lineStylePixmap[11] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ls2_bits, ls2_width, ls2_height); lineStylePixmap[12] = XCreateBitmapFromData (mainDisplay, mainWindow, ls3_bits, ls3_width, ls3_height); --- 282,303 ---- lt1_bits, lt1_width, lt1_height); lineStylePixmap[9] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ld0_bits, ld0_width, ld0_height); lineStylePixmap[10] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ld1_bits, ld1_width, ld1_height); lineStylePixmap[11] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ld2_bits, ld2_width, ld2_height); lineStylePixmap[12] = XCreateBitmapFromData (mainDisplay, mainWindow, + ld3_bits, ld3_width, ld3_height); + lineStylePixmap[13] = XCreateBitmapFromData (mainDisplay, mainWindow, + ld4_bits, ld4_width, ld4_height); + + lineStylePixmap[14] = XCreateBitmapFromData (mainDisplay, mainWindow, + ls0_bits, ls0_width, ls0_height); + lineStylePixmap[15] = XCreateBitmapFromData (mainDisplay, mainWindow, + ls1_bits, ls1_width, ls1_height); + lineStylePixmap[16] = XCreateBitmapFromData (mainDisplay, mainWindow, + ls2_bits, ls2_width, ls2_height); + lineStylePixmap[17] = XCreateBitmapFromData (mainDisplay, mainWindow, ls3_bits, ls3_width, ls3_height); *************** *** 303,306 **** --- 311,329 ---- ls3s_bits, ls3s_width, ls3s_height); + filePixmap = XCreateBitmapFromData (mainDisplay, mainWindow, + file_bits, file_width, file_height); + + specialPixmap = XCreateBitmapFromData (mainDisplay, mainWindow, + special_bits, special_width, special_height); + + rotatePixmap[0] = XCreateBitmapFromData (mainDisplay, mainWindow, + rotate_0_bits, rotate_0_width, rotate_0_height); + rotatePixmap[1] = XCreateBitmapFromData (mainDisplay, mainWindow, + rotate_90_bits, rotate_90_width, rotate_90_height); + rotatePixmap[2] = XCreateBitmapFromData (mainDisplay, mainWindow, + rotate_180_bits, rotate_180_width, rotate_180_height); + rotatePixmap[3] = XCreateBitmapFromData (mainDisplay, mainWindow, + rotate_270_bits, rotate_270_width, rotate_270_height); + whereToPrintPixmap[PRINTER] = XCreateBitmapFromData (mainDisplay, mainWindow, printer_bits, printer_width, printer_height); *************** *** 313,324 **** lt1s_bits, lt1s_width, lt1s_height); ! /* shortDashPixmap[0] = XCreateBitmapFromData (mainDisplay, mainWindow, */ ! /* ld0s_bits, ld0s_width, ld0s_height); */ ! /* shortDashPixmap[1] = XCreateBitmapFromData (mainDisplay, mainWindow, */ ! /* ld1s_bits, ld1s_width, ld1s_height); */ ! /* shortDashPixmap[2] = XCreateBitmapFromData (mainDisplay, mainWindow, */ ! /* ld2s_bits, ld2s_width, ld2s_height); */ ! /* shortDashPixmap[3] = XCreateBitmapFromData (mainDisplay, mainWindow, */ ! /* ld3s_bits, ld3s_width, ld3s_height); */ shortLineWidthPixmap[0] = XCreateBitmapFromData (mainDisplay, mainWindow, --- 336,349 ---- lt1s_bits, lt1s_width, lt1s_height); ! shortDashPixmap[0] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ld0s_bits, ld0s_width, ld0s_height); ! shortDashPixmap[1] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ld1s_bits, ld1s_width, ld1s_height); ! shortDashPixmap[2] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ld2s_bits, ld2s_width, ld2s_height); ! shortDashPixmap[3] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ld3s_bits, ld3s_width, ld3s_height); ! shortDashPixmap[4] = XCreateBitmapFromData (mainDisplay, mainWindow, ! ld4s_bits, ld4s_width, ld4s_height); shortLineWidthPixmap[0] = XCreateBitmapFromData (mainDisplay, mainWindow, *************** *** 354,358 **** { ShowMode (); ! ShowColor (); ShowHoriAlign (); ShowVertAlign (); --- 379,383 ---- { ShowMode (); ! ShowColor (FALSE); ShowHoriAlign (); ShowVertAlign (); *************** *** 359,366 **** ShowJust (); ShowCurFont (); ShowLineWidth (); - ShowWhereToPrint (); - ShowLineType (); ShowLineStyle (); ShowFill (); ShowPen (); --- 384,395 ---- ShowJust (); ShowCurFont (); + ShowRotate (); + ShowSpecial (); ShowLineWidth (); ShowLineStyle (); + ShowLineType (); + ShowDash (); + ShowWhereToPrint (); + ShowFile (); ShowFill (); ShowPen (); *************** *** 379,384 **** for (i = 0; i < MAXLINETYPES; i++) XFreePixmap (mainDisplay, lineTypePixmap[i]); ! /* for (i = 0; i < MAXDASHES; i++) */ ! /* XFreePixmap (mainDisplay, dashPixmap[i]); */ for (i = 0; i < MAXJUSTS; i++) XFreePixmap (mainDisplay, justPixmap[i]); XFreePixmap (mainDisplay, alignHoriPixmap[0]); --- 408,413 ---- for (i = 0; i < MAXLINETYPES; i++) XFreePixmap (mainDisplay, lineTypePixmap[i]); ! for (i = 0; i < MAXDASHES; i++) ! XFreePixmap (mainDisplay, dashPixmap[i]); for (i = 0; i < MAXJUSTS; i++) XFreePixmap (mainDisplay, justPixmap[i]); XFreePixmap (mainDisplay, alignHoriPixmap[0]); *************** *** 389,392 **** --- 418,425 ---- for (i = 0; i < MAXLINEWIDTHS; i++) XFreePixmap (mainDisplay, shortLineWidthPixmap[i]); + XFreePixmap (mainDisplay, filePixmap); + XFreePixmap (mainDisplay, specialPixmap); + for (i = 0; i < 4; i++) + XFreePixmap (mainDisplay, rotatePixmap[i]); for (i = 0; i < 2; i++) XFreePixmap (mainDisplay, whereToPrintPixmap[i]); *************** *** 395,400 **** for (i = 0; i < MAXLINESTYLES; i++) XFreePixmap (mainDisplay, shortLineStylePixmap[i]); ! /* for (i = 0; i < MAXDASHES; i++) */ ! /* XFreePixmap (mainDisplay, shortDashPixmap[i]); */ XFreeGC (mainDisplay, rasterGC); --- 428,433 ---- for (i = 0; i < MAXLINESTYLES; i++) XFreePixmap (mainDisplay, shortLineStylePixmap[i]); ! for (i = 0; i < MAXDASHES; i++) ! XFreePixmap (mainDisplay, shortDashPixmap[i]); XFreeGC (mainDisplay, rasterGC); *** select.c.orig Mon Jan 7 13:06:39 1991 --- select.c Mon Jan 7 13:06:41 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/select.c,v 1.7 90/07/27 14:37:59 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/select.c,v 1.9 90/11/01 18:08:44 william Exp $"; #endif *************** *** 624,639 **** } ! void CopySelToCut () { ! register struct SelRec * sel_ptr, * top_cut_ptr, * bot_cut_ptr; ! struct SelRec * top_sel_ptr, * bot_sel_ptr; - if (topSel == NULL) return; - - JustDupSelObj (&top_sel_ptr, &bot_sel_ptr); - top_cut_ptr = (struct SelRec *) calloc (2, sizeof (struct SelRec)); bot_cut_ptr = &top_cut_ptr[1]; ! top_cut_ptr->next = top_sel_ptr; bot_cut_ptr->next = bot_sel_ptr; top_cut_ptr->prev = topCutSel; bot_cut_ptr->prev = botCutSel; topCutSel = top_cut_ptr; botCutSel = bot_cut_ptr; --- 624,635 ---- } ! void PushToCutBuffer (TopSelPtr, BotSelPtr) ! struct SelRec * TopSelPtr, * BotSelPtr; { ! register struct SelRec * top_cut_ptr, * bot_cut_ptr; top_cut_ptr = (struct SelRec *) calloc (2, sizeof (struct SelRec)); bot_cut_ptr = &top_cut_ptr[1]; ! top_cut_ptr->next = TopSelPtr; bot_cut_ptr->next = BotSelPtr; top_cut_ptr->prev = topCutSel; bot_cut_ptr->prev = botCutSel; topCutSel = top_cut_ptr; botCutSel = bot_cut_ptr; *************** *** 640,649 **** } ! void DelAllSelObj () { ! register struct SelRec * sel_ptr, * top_cut_ptr, * bot_cut_ptr; if (topSel == NULL) return; HighLightReverse (); tmpTopObj = tmpBotObj = NULL; --- 636,653 ---- } ! void CopySelToCut () { ! struct SelRec * top_sel_ptr, * bot_sel_ptr; if (topSel == NULL) return; + JustDupSelObj (&top_sel_ptr, &bot_sel_ptr); + PushToCutBuffer (top_sel_ptr, bot_sel_ptr); + } + + void DelAllSelObj () + { + if (topSel == NULL) return; + HighLightReverse (); tmpTopObj = tmpBotObj = NULL; *************** *** 650,658 **** BreakSel (); ! top_cut_ptr = (struct SelRec *) calloc (2, sizeof (struct SelRec)); ! bot_cut_ptr = &top_cut_ptr[1]; ! top_cut_ptr->next = topSel; bot_cut_ptr->next = botSel; ! top_cut_ptr->prev = topCutSel; bot_cut_ptr->prev = botCutSel; ! topCutSel = top_cut_ptr; botCutSel = bot_cut_ptr; topSel = botSel = NULL; --- 654,658 ---- BreakSel (); ! PushToCutBuffer (topSel, botSel); topSel = botSel = NULL; ---------------------------------> cut here <--------------------------------- -- Bill Cheng // UCLA Computer Science Department // (213) 206-7135 3277 Boelter Hall // Los Angeles, California 90024 // USA william@CS.UCLA.EDU ...!{uunet|ucbvax}!cs.ucla.edu!william From news@CS.UCLA.EDU Mon Jan 7 18:58:35 1991 Received: from Shemp.CS.UCLA.EDU by uunet.UU.NET (5.61/1.14) with SMTP id AA06690; Mon, 7 Jan 91 18:58:25 -0500 Received: by shemp.cs.ucla.edu (Sendmail 5.61a+YP/2.33) id AA05177; Mon, 7 Jan 91 15:57:54 -0800 Newsgroups: comp.sources.x Path: oahu.cs.ucla.edu!william From: william@CS.UCLA.EDU (William Cheng) Subject: v07i056-076: tgif, Patch7 (tgif-1.16 => tgif-1.19), Part04/05 Message-Id: <1991Jan7.235737.5120@cs.ucla.edu> Followup-To: william@cs.ucla.edu Originator: william@oahu.cs.ucla.edu Keywords: draw, tool, postscript, latex, hierarchical, x11, xlib, wysiwyg Sender: news@cs.ucla.edu (Mr. News) Nntp-Posting-Host: oahu.cs.ucla.edu Organization: UCLA Computer Science Department Date: Mon, 7 Jan 91 23:57:37 GMT Patch-To: tgif: Volume 7, Issues 56-76 Apparently-To: comp-sources-x@uunet.uu.net Status: O ---------------------------------> cut here <--------------------------------- *** setup.c.orig Mon Jan 7 13:06:48 1991 --- setup.c Mon Jan 7 13:06:50 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/setup.c,v 1.14 90/10/22 10:21:53 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/setup.c,v 1.16 90/11/02 09:20:33 william Exp $"; #endif *************** *** 39,43 **** #define DRAW_WINDOW_W (5*PIX_PER_INCH) #define DRAW_WINDOW_H (5*PIX_PER_INCH) ! #define CHOICE_WINDOW_W (6*CHOICE_IMAGE_W) #define CHOICE_WINDOW_H (2*CHOICE_IMAGE_H) #define VSBAR_H (DRAW_WINDOW_H+RULER_W+2*BRDR_W) --- 39,43 ---- #define DRAW_WINDOW_W (5*PIX_PER_INCH) #define DRAW_WINDOW_H (5*PIX_PER_INCH) ! #define CHOICE_WINDOW_W (8*CHOICE_IMAGE_W) #define CHOICE_WINDOW_H (2*CHOICE_IMAGE_H) #define VSBAR_H (DRAW_WINDOW_H+RULER_W+2*BRDR_W) *************** *** 247,257 **** strcpy (homeDir, c_ptr); ! if ((c_ptr = getenv ("PWD")) == NULL) ! strcpy (bootDir, "."); ! else ! if (strlen (c_ptr) >= MAXPATHLENGTH-1) ! strcpy (bootDir, "."); ! else ! strcpy (bootDir, c_ptr); sizehints.flags = PPosition | PSize | PMinSize; --- 247,251 ---- strcpy (homeDir, c_ptr); ! if (getwd (bootDir) == NULL) strcpy (bootDir, "."); sizehints.flags = PPosition | PSize | PMinSize; *** special.c.orig Mon Jan 7 13:06:58 1991 --- special.c Mon Jan 7 13:07:02 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/special.c,v 1.13 90/10/25 14:57:35 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/special.c,v 1.14 90/11/01 18:09:43 william Exp $"; #endif *************** *** 100,103 **** --- 100,125 ---- } return (NULL); + } + + struct ObjRec * GetObjRepresentation (PathName, SymName) + char * PathName, * SymName; + { + char file_name[MAXPATHLENGTH]; + struct ObjRec * obj_ptr; + FILE * fp; + + sprintf (file_name, "%s/%s.sym", PathName, SymName); + if ((fp = fopen (file_name, "r")) == NULL) + { printf ("Can not open '%s'\n", file_name); return (NULL); } + + if ((obj_ptr = ReadSymbol (fp)) != NULL) + { + obj_ptr->id = objId++; + obj_ptr->dirty = FALSE; + strcpy (obj_ptr->detail.r->s, SymName); + AdjObjBBox (obj_ptr); + } + fclose (fp); + return (obj_ptr); } *** spline.c.orig Mon Jan 7 13:07:12 1991 --- spline.c Mon Jan 7 13:07:14 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/spline.c,v 1.3 90/07/16 10:58:15 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/spline.c,v 1.5 90/11/01 08:41:00 william Exp $"; #endif *************** *** 164,170 **** static XPoint arrow_v[4]; ! void DrawSplinePolyObj (Win, XOff, YOff, Fill, Width, Pen, Pixel, PolyPtr) Window Win; ! int XOff, YOff, Fill, Width, Pen, Pixel; struct PolyRec * PolyPtr; { --- 164,170 ---- static XPoint arrow_v[4]; ! void DrawSplinePolyObj (Win, XOff, YOff, Fill, Width, Pen, Dash, Pixel, PolyPtr) Window Win; ! int XOff, YOff, Fill, Width, Pen, Dash, Pixel; struct PolyRec * PolyPtr; { *************** *** 199,205 **** values.stipple = patPixmap[Pen]; values.line_width = widthOfLine[Width] >> zoomScale; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth, ! &values); XDrawLines (mainDisplay, Win, drawGC, sv, sn, CoordModeOrigin); --- 199,213 ---- values.stipple = patPixmap[Pen]; values.line_width = widthOfLine[Width] >> zoomScale; + if (Dash != 0) + { + XSetDashes (mainDisplay, drawGC, 0, dashList[Dash], + dashListLength[Dash]); + values.line_style = LineOnOffDash; + } + else + values.line_style = LineSolid; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth | ! GCLineStyle, &values); XDrawLines (mainDisplay, Win, drawGC, sv, sn, CoordModeOrigin); *************** *** 280,286 **** } ! void DrawSplinePolygonObj (Win, XOff, YOff, Fill, Width, Pen, Pixel, PolygonPtr) Window Win; ! int XOff, YOff, Fill, Width, Pen, Pixel; struct PolygonRec * PolygonPtr; { --- 288,294 ---- } ! void DrawSplinePolygonObj (Win,XOff,YOff,Fill,Width,Pen,Dash,Pixel,PolygonPtr) Window Win; ! int XOff, YOff, Fill, Width, Pen, Dash, Pixel; struct PolygonRec * PolygonPtr; { *************** *** 308,314 **** values.stipple = patPixmap[Pen]; values.line_width = widthOfLine[Width] >> zoomScale; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth, ! &values); XDrawLines (mainDisplay, Win, drawGC, sv, sn, CoordModeOrigin); --- 316,330 ---- values.stipple = patPixmap[Pen]; values.line_width = widthOfLine[Width] >> zoomScale; + if (Dash != 0) + { + XSetDashes (mainDisplay, drawGC, 0, dashList[Dash], + dashListLength[Dash]); + values.line_style = LineOnOffDash; + } + else + values.line_style = LineSolid; XChangeGC (mainDisplay, drawGC, ! GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth | ! GCLineStyle, &values); XDrawLines (mainDisplay, Win, drawGC, sv, sn, CoordModeOrigin); *** stk.c.orig Mon Jan 7 13:07:19 1991 --- stk.c Mon Jan 7 13:07:21 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/stk.c,v 1.10 90/10/27 15:09:07 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/stk.c,v 1.11 90/11/06 16:42:39 william Exp $"; #endif *************** *** 125,128 **** --- 125,129 ---- CleanUpDrawingWindow (); XClearWindow (mainDisplay, drawWindow); + SetFileModified (FALSE); while (ReadObj (fp, &obj_ptr, FALSE)) *************** *** 146,150 **** curFileDefined = TRUE; - SetFileModified (FALSE); sprintf (s, "Current file is '%s'.", file_name); Msg (s); --- 147,150 ---- *** text.c.orig Mon Jan 7 13:08:02 1991 --- text.c Mon Jan 7 13:08:07 1991 *************** *** 6,10 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/text.c,v 1.18 90/08/21 16:24:22 william Exp $"; #endif --- 6,10 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/text.c,v 1.22 90/11/10 13:51:14 william Exp $"; #endif *************** *** 125,128 **** --- 125,129 ---- static Pixmap textBackingPixmap; static int textBackingPixmapSize = INVALID; + static GC rotateGC = NULL; void CleanUpText () *************** *** 133,136 **** --- 134,138 ---- textBackingPixmapSize = INVALID; } + if (rotateGC != NULL) XFreeGC (mainDisplay, rotateGC); } *************** *** 265,278 **** textBackingPixmapSize = max(w,h); } ! XSetForeground (mainDisplay, defaultGC, 0); ! XFillRectangle (mainDisplay, textBackingPixmap, defaultGC, 0, 0, w, h); ! XSetForeground (mainDisplay, defaultGC, myFgPixel); ! XSetFont (mainDisplay, revDefaultGC, canvasFontPtr->fid); ! XDrawImageString (mainDisplay, textBackingPixmap, revDefaultGC, 0, canvasFontAsc, Str, len); from_image = XGetImage (mainDisplay, textBackingPixmap, 0, 0, w, h, 1, ! XYPixmap); values.foreground = colorPixels[ColorIndex]; --- 267,290 ---- textBackingPixmapSize = max(w,h); } + if (rotateGC == NULL) + { + values.foreground = 1; + values.background = 0; + values.fill_style = FillSolid; + values.function = GXcopy; + rotateGC = XCreateGC (mainDisplay, drawWindow, + GCForeground | GCBackground | GCFillStyle | GCFunction, + &values); + } ! XSetForeground (mainDisplay, rotateGC, 0); ! XFillRectangle (mainDisplay, textBackingPixmap, rotateGC, 0, 0, w, h); ! XSetForeground (mainDisplay, rotateGC, 1); ! XSetFont (mainDisplay, rotateGC, canvasFontPtr->fid); ! XDrawString (mainDisplay, textBackingPixmap, rotateGC, 0, canvasFontAsc, Str, len); from_image = XGetImage (mainDisplay, textBackingPixmap, 0, 0, w, h, 1, ! ZPixmap); values.foreground = colorPixels[ColorIndex]; *************** *** 592,596 **** PopCurFont (); ShowJust (); ! ShowColor (); ShowCurFont (); editingText = FALSE; --- 604,608 ---- PopCurFont (); ShowJust (); ! ShowColor (FALSE); ShowCurFont (); editingText = FALSE; *************** *** 674,678 **** PopCurFont (); ShowJust (); ! ShowColor (); ShowCurFont (); editingText = FALSE; --- 686,690 ---- PopCurFont (); ShowJust (); ! ShowColor (FALSE); ShowCurFont (); editingText = FALSE; *************** *** 811,815 **** ShowPen (); colorIndex = obj_ptr->color; ! ShowColor (); ShowCurFont (); --- 823,827 ---- ShowPen (); colorIndex = obj_ptr->color; ! ShowColor (FALSE); ShowCurFont (); *************** *** 1375,1379 **** int PRTGIF; { ! int x, y, font_size, xinc, yinc; struct StrRec * s_ptr; struct TextRec * text_ptr = ObjPtr->detail.t; --- 1387,1391 ---- int PRTGIF; { ! int x, y, font_size, xinc, yinc, color_index; struct StrRec * s_ptr; struct TextRec * text_ptr = ObjPtr->detail.t; *************** *** 1406,1409 **** --- 1418,1430 ---- y = ObjPtr->y; + if (colorDump) + { + color_index = ObjPtr->color; + fprintf (FP, "%.3f %.3f %.3f setrgbcolor\n", + ((float)tgifColors[color_index].red/maxRGB), + ((float)tgifColors[color_index].green/maxRGB), + ((float)tgifColors[color_index].blue/maxRGB)); + } + if (curFont == FONT_SYM) { *************** *** 1555,1558 **** --- 1576,1580 ---- } + if (curFontDPI != text_ptr->dpi) text_ptr->dpi = curFontDPI; RestoreCurFont (); } *************** *** 1652,1656 **** register struct StrRec * s_ptr; ! fprintf (FP, "text(%s,", colorMenuItems[ObjPtr->color]); fprintf (FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,[\n", ObjPtr->x, ObjPtr->y, t_ptr->font, t_ptr->style, t_ptr->size, --- 1674,1678 ---- register struct StrRec * s_ptr; ! fprintf (FP, "text('%s',", colorMenuItems[ObjPtr->color]); fprintf (FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,[\n", ObjPtr->x, ObjPtr->y, t_ptr->font, t_ptr->style, t_ptr->size, *************** *** 1793,1797 **** (*ObjPtr)->detail.t = text_ptr; ! if (!PRTGIF) RestoreCurFont (); } --- 1815,1823 ---- (*ObjPtr)->detail.t = text_ptr; ! if (!PRTGIF) ! { ! if (curFontDPI != text_ptr->dpi) text_ptr->dpi = curFontDPI; ! RestoreCurFont (); ! } } *************** *** 1806,1810 **** PopCurFont (); ShowJust (); ! ShowColor (); ShowCurFont (); } --- 1832,1836 ---- PopCurFont (); ShowJust (); ! ShowColor (FALSE); ShowCurFont (); } *** version.c.orig Mon Jan 7 13:08:16 1991 --- version.c Mon Jan 7 13:08:17 1991 *************** *** 6,11 **** #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/version.c,v 1.20 90/10/27 15:40:59 william Exp $"; #endif ! char * version_string = "1.16"; --- 6,11 ---- #ifndef lint static char RCSid[] = ! "@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/version.c,v 1.23 90/11/10 13:53:37 william Exp $"; #endif ! char * version_string = "1.19"; *** choice.e.orig Mon Jan 7 13:08:21 1991 --- choice.e Mon Jan 7 13:08:22 1991 *************** *** 4,8 **** * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/choice.e,v 1.4 90/10/26 18:35:33 william Exp $ */ --- 4,8 ---- * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/choice.e,v 1.6 90/10/30 16:35:47 william Exp $ */ *************** *** 18,21 **** --- 18,25 ---- extern void ShowCurFont (); extern void ShowCurFontDPI (); + extern void ShowDash (); + extern void ShowFile (); + extern void ShowSpecial (); + extern void ShowRotate (); extern void ShowLineWidth (); extern void ShowWhereToPrint (); *** edit.e.orig Mon Jan 7 13:08:25 1991 --- edit.e Mon Jan 7 13:08:26 1991 *************** *** 4,8 **** * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/edit.e,v 1.2 90/07/04 21:07:20 william Exp $ */ --- 4,8 ---- * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/edit.e,v 1.3 90/11/01 15:19:52 william Exp $ */ *************** *** 13,14 **** --- 13,15 ---- extern void BackProc (); extern void ArrangeMenu (); + extern void UpdateSymbols (); *** font.e.orig Mon Jan 7 13:08:30 1991 --- font.e Mon Jan 7 13:08:30 1991 *************** *** 4,8 **** * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/font.e,v 1.4 90/08/15 16:58:35 william Exp $ */ --- 4,8 ---- * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/font.e,v 1.5 90/10/30 19:33:51 william Exp $ */ *************** *** 46,49 **** --- 46,51 ---- extern void ChangeFont (); extern void FontMenu (); + extern void ChangeFontDPI (); + extern void FontDPIMenu (); extern void SaveCurFont (); extern void RestoreCurFont (); *** grid.e.orig Mon Jan 7 13:08:35 1991 --- grid.e Mon Jan 7 13:08:35 1991 *************** *** 4,8 **** * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/grid.e,v 1.3 90/07/16 10:18:50 william Exp $ */ --- 4,8 ---- * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/grid.e,v 1.7 90/10/30 16:07:25 william Exp $ */ *************** *** 20,23 **** --- 20,25 ---- extern void ToggleGridShown (); extern void ToggleSnapOn (); + extern void ToggleWhereToPrint (); + extern void ToggleColorPostScript (); extern void ZoomIn (); extern void ZoomOut (); *** names.e.orig Mon Jan 7 13:08:40 1991 --- names.e Mon Jan 7 13:08:41 1991 *************** *** 4,8 **** * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/names.e,v 1.12 90/10/25 14:58:59 william Exp $ */ --- 4,8 ---- * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/names.e,v 1.17 90/11/07 01:26:37 william Exp $ */ *************** *** 21,23 **** --- 21,25 ---- extern int SelectDomain (); extern void SetCurDir (); + extern int NameInCurDir (); + extern int DirInSymPath (); extern int GetSymbolPath (); *** raster.e.orig Mon Jan 7 13:08:45 1991 --- raster.e Mon Jan 7 13:08:46 1991 *************** *** 4,8 **** * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/raster.e,v 1.4 90/10/26 18:17:39 william Exp $ */ --- 4,8 ---- * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/raster.e,v 1.7 90/10/30 16:31:15 william Exp $ */ *************** *** 25,28 **** --- 25,31 ---- extern Pixmap alignHoriPixmap[]; extern Pixmap alignVertPixmap[]; + extern Pixmap filePixmap; + extern Pixmap specialPixmap; + extern Pixmap rotatePixmap[]; extern Pixmap whereToPrintPixmap[]; extern Pixmap shortLineWidthPixmap[]; *************** *** 32,36 **** extern int pat_w[], pat_h[]; ! extern int *dashListLength[]; extern char *dashList[]; --- 35,39 ---- extern int pat_w[], pat_h[]; ! extern int dashListLength[]; extern char *dashList[]; *** select.e.orig Mon Jan 7 13:08:49 1991 --- select.e Mon Jan 7 13:08:50 1991 *************** *** 4,8 **** * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/select.e,v 1.2 90/07/06 18:02:44 william Exp $ */ --- 4,8 ---- * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/select.e,v 1.3 90/11/01 16:42:13 william Exp $ */ *************** *** 23,26 **** --- 23,27 ---- extern void DelAllCutSel (); extern void UndoDelete (); + extern void PushToCutBuffer (); extern void CopySelToCut (); extern void DelAllSelObj (); *** special.e.orig Mon Jan 7 13:08:55 1991 --- special.e Mon Jan 7 13:08:56 1991 *************** *** 4,11 **** * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/special.e,v 1.1 90/04/01 22:17:22 william Exp $ */ extern struct ObjRec * ReadSymbol (); extern void PlaceTopObj (); extern void Instantiate (); --- 4,12 ---- * Copyright (C) 1989, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/special.e,v 1.2 90/11/01 18:02:05 william Exp $ */ extern struct ObjRec * ReadSymbol (); + extern struct ObjRec * GetObjRepresentation (); extern void PlaceTopObj (); extern void Instantiate (); *** const.h.orig Mon Jan 7 13:09:00 1991 --- const.h Mon Jan 7 13:09:02 1991 *************** *** 4,8 **** * Copyright (C) 1990, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/const.h,v 1.8 90/10/26 17:51:55 william Exp $ */ --- 4,8 ---- * Copyright (C) 1990, William Cheng. * ! * @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/const.h,v 1.9 90/10/29 17:54:01 william Exp $ */ *************** *** 91,95 **** #define MAXLINESTYLES 4 ! #define MAXDASHES 4 #define NOCONT (FALSE) --- 91,95 ---- #define MAXLINESTYLES 4 ! #define MAXDASHES 5 #define NOCONT (FALSE) *** Makefile.noimake.orig Mon Jan 7 13:09:08 1991 --- Makefile.noimake Mon Jan 7 13:09:09 1991 *************** *** 4,8 **** # Copyright (C) 1990, William Cheng. # ! # @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/Makefile.noimake,v 1.26 90/10/27 15:44:10 william Exp $ # --- 4,8 ---- # Copyright (C) 1990, William Cheng. # ! # @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/Makefile.noimake,v 1.29 90/11/10 13:53:48 william Exp $ # *************** *** 10,15 **** LINK.c = $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) ! TGIFVERSION = 1.16 ! INSTALLDIR = /u/tangram/bin CC = cc --- 10,15 ---- LINK.c = $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) ! TGIFVERSION = 1.19 ! INSTALLDIR = /u/tangram/$(MACHINE)/bin CC = cc *************** *** 48,51 **** --- 48,55 ---- bitmaps/ld0.bm bitmaps/ld0s.bm bitmaps/ld1.bm bitmaps/ld1s.bm \ bitmaps/ld2.bm bitmaps/ld2s.bm bitmaps/ld3.bm bitmaps/ld3s.bm \ + bitmaps/ld4.bm bitmaps/ld4s.bm \ + bitmaps/file.bm bitmaps/special.bm \ + bitmaps/rotate_0.bm bitmaps/rotate_90.bm \ + bitmaps/rotate_180.bm bitmaps/rotate_270.bm \ bitmaps/oval.bm bitmaps/pat0.bm bitmaps/pat1.bm bitmaps/pat10.bm \ bitmaps/pat11.bm bitmaps/pat12.bm bitmaps/pat13.bm bitmaps/pat14.bm \ *************** *** 113,118 **** edit.o: const.h types.h \ align.e color.e copypaste.e cursor.e drawing.e dup.e font.e \ ! group.e mark.e obj.e poly.e raster.e select.e setup.e spline.e \ ! stretch.e file.o: const.h types.h \ align.e attr.e box.e button.e choice.e color.e dialog.e \ --- 117,122 ---- edit.o: const.h types.h \ align.e color.e copypaste.e cursor.e drawing.e dup.e font.e \ ! group.e mark.e obj.e poly.e raster.e select.e setup.e \ ! special.e spline.e stretch.e file.o: const.h types.h \ align.e attr.e box.e button.e choice.e color.e dialog.e \ *************** *** 175,180 **** choice.e color.e cursor.e drawing.e font.e mainloop.e menu.e \ names.e raster.e ruler.e scroll.e stk.e - spline.o: const.h types.h \ - poly.e raster.e rect.e setup.e special.o: const.h types.h \ animate.e attr.e choice.e color.e cursor.e dialog.e drawing.e \ --- 179,182 ---- *************** *** 181,184 **** --- 183,188 ---- dup.e file.e grid.e group.e mark.e msg.e move.e names.e \ obj.e raster.e select.e setup.e stk.e + spline.o: const.h types.h \ + poly.e raster.e rect.e setup.e stk.o: const.h types.h \ align.e button.e choice.e color.e dup.e file.e font.e grid.e \ *** Imakefile.orig Mon Jan 7 13:09:15 1991 --- Imakefile Mon Jan 7 13:09:16 1991 *************** *** 4,11 **** /**/# Copyright (C) 1990, William Cheng. /**/# ! /**/# @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/Imakefile,v 1.29 90/10/27 15:42:31 william Exp $ /**/# ! TGIFVERSION = 1.16 PROGRAMS = tgif prtgif tgif2ps frontend11.o /**/#CDEBUGFLAGS= -g --- 4,11 ---- /**/# Copyright (C) 1990, William Cheng. /**/# ! /**/# @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/Imakefile,v 1.34 90/11/10 13:53:45 william Exp $ /**/# ! TGIFVERSION = 1.19 PROGRAMS = tgif prtgif tgif2ps frontend11.o /**/#CDEBUGFLAGS= -g *************** *** 13,17 **** /**/#MANPATH = /u/tangram/man /**/#TGIFDIR = /u/tangram/lib/tgif ! TGIFDIR = $(LIBDIR)/tgif DEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=\"664\" LOCAL_LIBRARIES = $(XLIB) --- 13,17 ---- /**/#MANPATH = /u/tangram/man /**/#TGIFDIR = /u/tangram/lib/tgif ! TGIFDIR = $(LIBDIR)/tgif DEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=\"664\" LOCAL_LIBRARIES = $(XLIB) *************** *** 62,66 **** OBJDEMO = an-sr-flip-flop.obj fonts.obj slide-demo.obj spice//**/*.obj SYMDEMO = flip-flop.sym nand2.sym pin.sym tangram.sym spice//**/*.sym ! MISCTAR = *.man README Copyright tgif.pl spice//**/*.mod example.tex distr: tar version --- 62,66 ---- OBJDEMO = an-sr-flip-flop.obj fonts.obj slide-demo.obj spice//**/*.obj SYMDEMO = flip-flop.sym nand2.sym pin.sym tangram.sym spice//**/*.sym ! MISCTAR = /**/*.man README Copyright tgif.pl spice//**/*.mod example.tex distr: tar version *************** *** 116,119 **** version: what /**/*.c /**/*.e /**/*.h Makefile.noimake Imakefile \ ! /**/*.man tgif.pl README \ > VersionInfo/Distribution/tgif-$(TGIFVERSION) --- 116,119 ---- version: what /**/*.c /**/*.e /**/*.h Makefile.noimake Imakefile \ ! /**/*.man tgif.pl README example.tex \ > VersionInfo/Distribution/tgif-$(TGIFVERSION) *** tgif.man.orig Mon Jan 7 13:09:28 1991 --- tgif.man Mon Jan 7 13:09:30 1991 *************** *** 1,3 **** ! .\"@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/tgif.man,v 1.13 90/10/27 17:28:39 william Exp $ .TH TGIF 1 "Version 1.13 and Above" "Tgif" .SH NAME --- 1,3 ---- ! .\"@(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/tgif.man,v 1.17 90/11/08 17:02:40 william Exp $ .TH TGIF 1 "Version 1.13 and Above" "Tgif" .SH NAME *************** *** 50,55 **** See \fBATTRIBUTES\fR section for details. .PP ! The output of tgif is in PostScript(TM) form. Normally, the output ! is printed to /tmp/DRAW.PS and that file is piped to lpr. A mode within tgif allows the printout to go to a file with a .I \.ps --- 50,56 ---- See \fBATTRIBUTES\fR section for details. .PP ! The output of tgif is in PostScript(TM) form (color PostScript ! is supported). Normally, the output ! is printed to /tmp/Tgifa* where * is a number and that file is piped to lpr. A mode within tgif allows the printout to go to a file with a .I \.ps *************** *** 79,83 **** Tgif supports 20 fill patterns, 20 pen patterns, 7 line widths, 4 line styles (plain, head arrow, tail arrow, double arrows) for ! polyline and open-splines, 3 types of text justifications, 4 text styles (roman, itatlic, bold, bold-italic), 12 text sizes (8, 10, 12, 14, 18, and 24 for the 75dpi fonts and --- 80,85 ---- Tgif supports 20 fill patterns, 20 pen patterns, 7 line widths, 4 line styles (plain, head arrow, tail arrow, double arrows) for ! polyline and open-splines, 5 dash patterns, ! 3 types of text justifications, 4 text styles (roman, itatlic, bold, bold-italic), 12 text sizes (8, 10, 12, 14, 18, and 24 for the 75dpi fonts and *************** *** 100,110 **** It displays tgif messages. Mouse clicks and key presses have no effect. .TP ! .I Panel Window This is the window to the right of the message window. It displays the current choice (in top/bottom, left/right order) of the ! drawing mode, color, horizontal alignment, vertical alignment, ! text justification, font and text rotation, line width, line style, print mode, ! poly or spline, fill pattern, and pen pattern. ! Key presses have no effect. .PP .RS --- 102,114 ---- It displays tgif messages. Mouse clicks and key presses have no effect. .TP ! .I Panel (Choice) Window This is the window to the right of the message window. It displays the current choice (in top/bottom, left/right order) of the ! drawing mode, color, horizontal alignment (L C R -), ! vertical alignment (T M B -), ! text justification, font, text rotation, line width, line style, ! poly or spline, dash pattern, print mode, ! fill pattern, and pen pattern. ! Key presses have no effect in this window. .PP .RS *************** *** 117,120 **** --- 121,133 ---- is used; also, icon objects will not change because they should be thought of as ``bitmaps''. + .PP + The settings of the horizontal and vertical + alignments determine how objects align with + each other when the ^L keyboard command is issued, and they + determine how each individual object aligns with the grids + when the ^T keyboard command is issued. The horizontal + alignments are left (L), center (C), right (R), and ignore (-). + The vertical alignments are top (T), middle (M), bottom (B), and + ignore (-). The best way to understand them is to try them out. .RE .TP *************** *** 223,226 **** --- 236,240 ---- ^#I make the selected complex object iconic\br ^#J make the selected icon object a grouped object\br + ^#K select color or black-and-white PostScript output\br ^#L change the text justification to left justified\br ^#M make the selected complex object symbolic\br *************** *** 232,237 **** --- 246,253 ---- ^#S save the file under a new name\br ^#T change the text style to italic\br + ^#U update iconic representations of selected objects\br ^#V change the drawing mode to oval\br ^#W toggle between poly and spline\br + ^#X select between printer and LaTeX file output\br ^#Y paste from the cut buffer\br .DE *************** *** 341,346 **** high, which is the total height of the picture in an-sr-flip-flop. ! Notice that the psfile special construct is used. Encapsulated ! PostScript format is not supported. Again, \fItgif2ps\fR is used to generate the \fI.ps\fR file, so it should be installed in the path. --- 357,361 ---- high, which is the total height of the picture in an-sr-flip-flop. ! Again, \fItgif2ps\fR is used to generate the \fI.ps\fR file, so it should be installed in the path. *** tgif.pl.orig Mon Jan 7 13:09:35 1991 --- tgif.pl Mon Jan 7 13:09:36 1991 *************** *** 6,10 **** % 4) Trace any other goals. % ! % @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/tgif.pl,v 1.5 90/08/27 11:19:13 william Exp $ % --- 6,10 ---- % 4) Trace any other goals. % ! % @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/tgif.pl,v 1.6 90/11/03 13:29:22 william Exp $ % *************** *** 48,54 **** _TextStyle,_TextSize,_TextDPI), ( OutputObj == true -> call(Obj) ; true ), ! FileVersion >= 8, !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). % --------------------------------------------------------------------- % --- 48,68 ---- _TextStyle,_TextSize,_TextDPI), ( OutputObj == true -> call(Obj) ; true ), ! FileVersion =< 8, !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). + tgif_state(FileVersion,Obj) :- + ( var(Obj) -> OutputObj = true, + current_predicate(state, + state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) + ; OutputObj = false + ), + Obj = state(_PageStyle,FileVersion,_OrigX,_OrigY,_Zoom, + _GridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, + _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_Font, + _TextStyle,_TextSize,_TextDPI,_Dash), + ( OutputObj == true -> call(Obj) ; true ), + FileVersion >= 9, + !, abolish(tgif_file_version/1), + !, assert(tgif_file_version(FileVersion)). % --------------------------------------------------------------------- % *************** *** 103,107 **** current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), ! FileVersion >= 8, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = box(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat,_Id, --- 117,121 ---- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), ! FileVersion =< 8, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = box(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat,_Id, *************** *** 109,112 **** --- 123,135 ---- ( OutputObj == true -> call(Obj) ; true ), tgif_attrs(AttrList). + tgif_box(Obj) :- + current_predicate(tgif_file_version,tgif_file_version(_)), + tgif_file_version(FileVersion), + FileVersion >= 9, !, + ( var(Obj) -> OutputObj = true ; OutputObj = false ), + Obj = box(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat,_Id,_Dash, + AttrList), + ( OutputObj == true -> call(Obj) ; true ), + tgif_attrs(AttrList). % --------------------------------------------------------------------- % *************** *** 123,127 **** current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), ! FileVersion >= 8, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = oval(_Color,_LeftTopX,_LeftTopY,_RightBotX,_RightBotY,_ObjFill, --- 146,150 ---- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), ! FileVersion =< 8, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = oval(_Color,_LeftTopX,_LeftTopY,_RightBotX,_RightBotY,_ObjFill, *************** *** 129,132 **** --- 152,164 ---- ( OutputObj == true -> call(Obj) ; true ), tgif_attrs(AttrList). + tgif_oval(Obj) :- + current_predicate(tgif_file_version,tgif_file_version(_)), + tgif_file_version(FileVersion), + FileVersion >= 9, !, + ( var(Obj) -> OutputObj = true ; OutputObj = false ), + Obj = oval(_Color,_LeftTopX,_LeftTopY,_RightBotX,_RightBotY,_ObjFill, + _LineWidth,_PenPat,_Id,_Dash,AttrList), + ( OutputObj == true -> call(Obj) ; true ), + tgif_attrs(AttrList). % --------------------------------------------------------------------- % *************** *** 153,157 **** current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), ! FileVersion >= 5, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = poly(_Color,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id,_Spline, --- 185,189 ---- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), ! FileVersion =< 8, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = poly(_Color,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id,_Spline, *************** *** 159,162 **** --- 191,203 ---- ( OutputObj == true -> call(Obj) ; true ), tgif_attrs(AttrList). + tgif_poly(Obj) :- + current_predicate(tgif_file_version,tgif_file_version(_)), + tgif_file_version(FileVersion), + FileVersion >= 9, !, + ( var(Obj) -> OutputObj = true ; OutputObj = false ), + Obj = poly(_Color,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id,_Spline, + _ObjFill,_Dash,AttrList), + ( OutputObj == true -> call(Obj) ; true ), + tgif_attrs(AttrList). % --------------------------------------------------------------------- % *************** *** 179,186 **** current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), ! FileVersion >= 8, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = polygon(_Color,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat,_Spline, _Id,AttrList), ( OutputObj == true -> call(Obj) ; true ), tgif_attrs(AttrList). --- 220,236 ---- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), ! FileVersion =< 8, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = polygon(_Color,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat,_Spline, _Id,AttrList), + ( OutputObj == true -> call(Obj) ; true ), + tgif_attrs(AttrList). + tgif_polygon(Obj) :- + current_predicate(tgif_file_version,tgif_file_version(_)), + tgif_file_version(FileVersion), + FileVersion >= 9, !, + ( var(Obj) -> OutputObj = true ; OutputObj = false ), + Obj = polygon(_Color,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat,_Spline, + _Id,_Dash,AttrList), ( OutputObj == true -> call(Obj) ; true ), tgif_attrs(AttrList). *** example.tex.orig Mon Jan 7 13:09:39 1991 --- example.tex Mon Jan 7 13:09:40 1991 *************** *** 0 **** --- 1,40 ---- + % + % @(#)$Header: /n/kona/u/tangram/u/william/X11/TGIF/RCS/example.tex,v 1.1 90/11/06 02:26:33 william Exp $ + % + \documentstyle[12pt]{article} + % + \oddsidemargin=0in + \textwidth=6.5in + \topmargin=0in + \textheight=609pt + \parskip=14pt + \setlength{\unitlength}{0.5cm} + \begin{document} + % + Figure \ref{fig:psfig} is an example of a tgif \LaTeX\,\, figure printed with + the ``psfig'' macro. Here is a bunch of random text. + % + \begin{figure*}[htb] + \input{psfig} + \centerline{\psfig{figure=an-sr-flip-flop.ps}} + \caption{Example Tgif Diagram Printed with ``psfig'' Macro.\label{fig:psfig}} + \end{figure*} + % + Here is another bunch of random text, just to see how it looks on the page. + What it should do is to center the picture on the page. But what does + it really do? We shall see $\ldots$ + + Figure \ref{fig:an-sr-flip-flop} is an example of a tgif \LaTeX\,\, figure + printed with the ``psfile'' macro. Here is a bunch of random text. + % + \begin{figure*}[htb] + \special{psfile="an-sr-flip-flop.ps" hoffset=-40} + \rule{0in}{1.1in} + \caption{Example Tgif Diagram Printed with ``psfile'' Macro. + \label{fig:an-sr-flip-flop}} + \end{figure*} + % + Here is another bunch of random text, just to see how it looks on the page. + What it should do is to center the picture on the page. But what does + it really do? We shall see $\ldots$ + \end{document} *** bitmaps/ld1.bm.orig Mon Oct 29 20:56:26 1990 --- bitmaps/ld1.bm Mon Oct 29 20:56:27 1990 *************** *** 10,14 **** 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0x78, 0x78, 0x78, 0x78, 0x78, 0x78, 0x78, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, --- 10,14 ---- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, *** bitmaps/ld1s.bm.orig Mon Oct 29 20:56:43 1990 --- bitmaps/ld1s.bm Mon Oct 29 20:56:43 1990 *************** *** 7,11 **** 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0x78, 0x78, 0x78, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, --- 7,11 ---- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, *** bitmaps/ld2.bm.orig Mon Oct 29 20:56:54 1990 --- bitmaps/ld2.bm Mon Oct 29 20:56:55 1990 *************** *** 10,14 **** 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0xf8, 0xf9, 0xf9, 0xf9, 0xf9, 0xf9, 0xf9, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, --- 10,14 ---- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0x78, 0x78, 0x78, 0x78, 0x78, 0x78, 0x78, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, *** bitmaps/ld2s.bm.orig Mon Oct 29 20:57:05 1990 --- bitmaps/ld2s.bm Mon Oct 29 20:57:06 1990 *************** *** 7,11 **** 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0xf8, 0xf9, 0xf9, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, --- 7,11 ---- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0x78, 0x78, 0x78, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, *** bitmaps/ld3.bm.orig Mon Oct 29 20:57:18 1990 --- bitmaps/ld3.bm Mon Oct 29 20:57:19 1990 *************** *** 10,14 **** 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0xf8, 0x9f, 0xf9, 0x9f, 0xf9, 0x9f, 0xf9, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, --- 10,14 ---- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0xf8, 0xf9, 0xf9, 0xf9, 0xf9, 0xf9, 0xf9, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, *************** *** 16,19 **** 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x3c, 0x3c, 0x3c, ! 0x3c, 0x3c, 0x3c, 0x3c}; --- 16,19 ---- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0x00, 0x00, 0x00, 0x00}; *** bitmaps/ld3s.bm.orig Mon Oct 29 20:57:31 1990 --- bitmaps/ld3s.bm Mon Oct 29 20:57:31 1990 *************** *** 7,11 **** 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0xf8, 0x9f, 0xf9, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, --- 7,11 ---- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ! 0xf8, 0xf9, 0xf9, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, *** bitmaps/ld4.bm.orig Mon Oct 29 20:58:06 1990 --- bitmaps/ld4.bm Mon Oct 29 20:58:06 1990 *************** *** 0 **** --- 1,19 ---- + #define ld4_width 64 + #define ld4_height 20 + #define ld4_x_hot 0 + #define ld4_y_hot 0 + static char ld4_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xf8, 0x9f, 0xf9, 0x9f, 0xf9, 0x9f, 0xf9, 0x1f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x3c, 0x3c, 0x3c, + 0x3c, 0x3c, 0x3c, 0x3c}; *** bitmaps/ld4s.bm.orig Mon Oct 29 20:58:15 1990 --- bitmaps/ld4s.bm Mon Oct 29 20:58:16 1990 *************** *** 0 **** --- 1,12 ---- + #define ld4s_width 32 + #define ld4s_height 20 + #define ld4s_x_hot 0 + #define ld4s_y_hot 0 + static char ld4s_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xf8, 0x9f, 0xf9, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ---------------------------------> cut here <--------------------------------- -- Bill Cheng // UCLA Computer Science Department // (213) 206-7135 3277 Boelter Hall // Los Angeles, California 90024 // USA william@CS.UCLA.EDU ...!{uunet|ucbvax}!cs.ucla.edu!william From news@CS.UCLA.EDU Mon Jan 7 19:01:03 1991 Received: from Shemp.CS.UCLA.EDU by uunet.UU.NET (5.61/1.14) with SMTP id AA07044; Mon, 7 Jan 91 19:00:53 -0500 Received: by shemp.cs.ucla.edu (Sendmail 5.61a+YP/2.33) id AA05404; Mon, 7 Jan 91 16:00:39 -0800 Newsgroups: comp.sources.x Path: oahu.cs.ucla.edu!william From: william@CS.UCLA.EDU (William Cheng) Subject: v07i056-076: tgif, Patch7 (tgif-1.16 => tgif-1.19), Part05/05 Message-Id: <1991Jan8.000022.5315@cs.ucla.edu> Followup-To: william@cs.ucla.edu Originator: william@oahu.cs.ucla.edu Keywords: draw, tool, postscript, latex, hierarchical, x11, xlib, wysiwyg Sender: news@cs.ucla.edu (Mr. News) Nntp-Posting-Host: oahu.cs.ucla.edu Organization: UCLA Computer Science Department Date: Tue, 8 Jan 91 00:00:22 GMT Patch-To: tgif: Volume 7, Issues 56-76 Apparently-To: comp-sources-x@uunet.uu.net Status: O ---------------------------------> cut here <--------------------------------- *** bitmaps/file.bm.orig Wed Jun 27 09:15:24 1990 --- bitmaps/file.bm Tue Oct 30 14:31:43 1990 *************** *** 1,9 **** ! #define file_width 20 ! #define file_height 15 #define file_x_hot 0 #define file_y_hot 0 static char file_bits[] = { ! 0x00, 0x00, 0x00, 0xe0, 0x0f, 0x00, 0x20, 0x18, 0x00, 0x20, 0x38, 0x00, ! 0x20, 0x78, 0x00, 0x20, 0x40, 0x00, 0x20, 0x40, 0x00, 0x20, 0x40, 0x00, ! 0x20, 0x40, 0x00, 0x20, 0x40, 0x00, 0x20, 0x40, 0x00, 0x20, 0x40, 0x00, ! 0x20, 0x40, 0x00, 0xe0, 0x7f, 0x00, 0x00, 0x00, 0x00}; --- 1,12 ---- ! #define file_width 32 ! #define file_height 20 #define file_x_hot 0 #define file_y_hot 0 static char file_bits[] = { ! 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x02, 0x06, 0x00, ! 0x00, 0x02, 0x0a, 0x00, 0x00, 0x02, 0x12, 0x00, 0x00, 0x02, 0x22, 0x00, ! 0x00, 0x02, 0x7e, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, ! 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, ! 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, ! 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, ! 0x00, 0xfe, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00}; *** bitmaps/rotate_0.bm.orig Thu Nov 1 10:04:52 1990 --- bitmaps/rotate_0.bm Tue Oct 30 16:21:06 1990 *************** *** 0 **** --- 1,12 ---- + #define rotate_0_width 32 + #define rotate_0_height 20 + #define rotate_0_x_hot 0 + #define rotate_0_y_hot 0 + static char rotate_0_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x30, 0x18, 0x00, + 0x00, 0x0c, 0x61, 0x00, 0x00, 0x04, 0x41, 0x00, 0x00, 0x82, 0x83, 0x00, + 0x00, 0x82, 0x83, 0x00, 0x00, 0x01, 0x01, 0x01, 0x00, 0x01, 0x01, 0x01, + 0x00, 0x01, 0x01, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, + 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x04, 0x40, 0x00, + 0x00, 0x0c, 0x60, 0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0xc0, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; *** bitmaps/rotate_180.bm.orig Thu Nov 1 10:04:52 1990 --- bitmaps/rotate_180.bm Tue Oct 30 16:21:07 1990 *************** *** 0 **** --- 1,12 ---- + #define rotate_180_width 32 + #define rotate_180_height 20 + #define rotate_180_x_hot 0 + #define rotate_180_y_hot 0 + static char rotate_180_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x30, 0x18, 0x00, + 0x00, 0x0c, 0x60, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x80, 0x00, + 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, + 0x00, 0x01, 0x01, 0x01, 0x00, 0x01, 0x01, 0x01, 0x00, 0x01, 0x01, 0x01, + 0x00, 0x82, 0x83, 0x00, 0x00, 0x82, 0x83, 0x00, 0x00, 0x04, 0x41, 0x00, + 0x00, 0x0c, 0x61, 0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0xc0, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; *** bitmaps/rotate_270.bm.orig Thu Nov 1 10:04:52 1990 --- bitmaps/rotate_270.bm Tue Oct 30 16:21:08 1990 *************** *** 0 **** --- 1,12 ---- + #define rotate_270_width 32 + #define rotate_270_height 20 + #define rotate_270_x_hot 0 + #define rotate_270_y_hot 0 + static char rotate_270_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x30, 0x18, 0x00, + 0x00, 0x0c, 0x60, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x80, 0x00, + 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x31, 0x00, 0x01, + 0x00, 0xfd, 0x01, 0x01, 0x00, 0x31, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, + 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x04, 0x40, 0x00, + 0x00, 0x0c, 0x60, 0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0xc0, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; *** bitmaps/rotate_90.bm.orig Thu Nov 1 10:04:52 1990 --- bitmaps/rotate_90.bm Tue Oct 30 16:21:09 1990 *************** *** 0 **** --- 1,12 ---- + #define rotate_90_width 32 + #define rotate_90_height 20 + #define rotate_90_x_hot 0 + #define rotate_90_y_hot 0 + static char rotate_90_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x30, 0x18, 0x00, + 0x00, 0x0c, 0x60, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x80, 0x00, + 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x18, 0x01, + 0x00, 0x01, 0x7f, 0x01, 0x00, 0x01, 0x18, 0x01, 0x00, 0x01, 0x00, 0x01, + 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x04, 0x40, 0x00, + 0x00, 0x0c, 0x60, 0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0xc0, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; *** bitmaps/special.bm.orig Thu Nov 1 10:04:52 1990 --- bitmaps/special.bm Tue Oct 30 16:29:15 1990 *************** *** 0 **** --- 1,12 ---- + #define special_width 32 + #define special_height 20 + #define special_x_hot 0 + #define special_y_hot 0 + static char special_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x20, 0x08, 0x00, + 0x00, 0x10, 0x10, 0x00, 0x00, 0x08, 0x20, 0x00, 0x00, 0x08, 0x20, 0x00, + 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x10, 0x00, + 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x01, 0x00, + 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x80, 0x03, 0x00, + 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00}; *** an-sr-flip-flop.obj.orig Wed Jun 27 09:16:31 1990 --- an-sr-flip-flop.obj Mon Jul 30 17:57:36 1990 *************** *** 1,3 **** ! state(0,6,0,0,0,8,1,6,0,2,0,1,0,0,1,1,0,0,4). icon([ group([ --- 1,3 ---- ! state(0,7,0,0,0,8,1,6,0,2,0,1,0,0,1,1,0,0,4). icon([ group([ *************** *** 19,26 **** "pin",43,[ attr("name=", "Q", 1, 0, 1, ! text(green,504,8,1,0,4,1,1,0,1,[ "Q"])), attr("num=", "", 0, 1, 1, ! text(green,536,-24,1,0,4,1,1,0,1,[ "num="])) ]), --- 19,26 ---- "pin",43,[ attr("name=", "Q", 1, 0, 1, ! text(green,504,8,1,0,4,1,1,0,1,11,17,[ "Q"])), attr("num=", "", 0, 1, 1, ! text(green,536,-24,1,0,4,1,1,0,1,44,17,[ "num="])) ]), *************** *** 31,38 **** "pin",44,[ attr("num=", "", 0, 1, 1, ! text(green,536,24,1,0,4,1,1,0,1,[ "num="])), attr("name=", "Q'", 1, 0, 1, ! text(green,496,56,1,0,4,1,1,0,1,[ "Q'"])) ]), --- 31,38 ---- "pin",44,[ attr("num=", "", 0, 1, 1, ! text(green,536,24,1,0,4,1,1,0,1,44,17,[ "num="])), attr("name=", "Q'", 1, 0, 1, ! text(green,496,56,1,0,4,1,1,0,1,22,17,[ "Q'"])) ]), *************** *** 43,50 **** "pin",45,[ attr("num=", "", 0, 1, 1, ! text(green,424,-24,1,0,4,1,1,0,1,[ "num="])), attr("name=", "S'", 1, 0, 1, ! text(green,464,8,1,0,4,1,1,0,1,[ "S'"])) ]), --- 43,50 ---- "pin",45,[ attr("num=", "", 0, 1, 1, ! text(green,424,-24,1,0,4,1,1,0,1,44,17,[ "num="])), attr("name=", "S'", 1, 0, 1, ! text(green,464,8,1,0,4,1,1,0,1,22,17,[ "S'"])) ]), *************** *** 55,62 **** "pin",46,[ attr("name=", "R'", 1, 0, 1, ! text(green,464,56,1,0,4,1,1,0,1,[ "R'"])), attr("num=", "", 0, 1, 1, ! text(green,424,24,1,0,4,1,1,0,1,[ "num="])) ]) --- 55,62 ---- "pin",46,[ attr("name=", "R'", 1, 0, 1, ! text(green,464,56,1,0,4,1,1,0,1,22,17,[ "R'"])), attr("num=", "", 0, 1, 1, ! text(green,424,24,1,0,4,1,1,0,1,44,17,[ "num="])) ]) *************** *** 64,68 **** "flip-flop",51,[ ]). ! text(white,480,104,0,0,4,2,1,0,1,[ "This is a SR flip-flop", "Select the flip-flop with left mouse button and type ^V"]). --- 64,68 ---- "flip-flop",51,[ ]). ! text(white,480,104,0,0,4,2,1,0,1,405,38,[ "This is a SR flip-flop", "Select the flip-flop with left mouse button and type ^V"]). *** fonts.obj.orig Wed Jun 27 09:16:32 1990 --- fonts.obj Mon Jul 30 17:53:07 1990 *************** *** 1,241 **** ! state(0,2,0,192,0,16,1,0,1,1,1,1,2,7,0,0,3,4). ! text(yellow,64,64,0,0,4,1,0,[ "hello world"]). ! text(yellow,64,80,1,0,4,1,0,[ "hello world"]). ! text(yellow,64,96,2,0,4,1,0,[ "hello world"]). ! text(yellow,64,112,3,0,4,1,0,[ "hello world"]). ! text(yellow,64,128,4,0,4,1,0,[ "hello world"]). ! text(yellow,192,64,0,1,4,1,0,[ "hello world"]). ! text(yellow,192,80,1,1,4,1,0,[ "hello world"]). ! text(yellow,192,96,2,1,4,1,0,[ "hello world"]). ! text(yellow,192,112,3,1,4,1,0,[ "hello world"]). ! text(yellow,192,128,4,1,4,1,0,[ "hello world"]). ! text(yellow,320,64,0,2,4,1,0,[ "hello world"]). ! text(yellow,320,80,1,2,4,1,0,[ "hello world"]). ! text(yellow,320,96,2,2,4,1,0,[ "hello world"]). ! text(yellow,320,112,3,2,4,1,0,[ "hello world"]). ! text(yellow,320,128,4,2,4,1,0,[ "hello world"]). ! text(yellow,448,64,0,3,4,1,0,[ "hello world"]). ! text(yellow,448,80,1,3,4,1,0,[ "hello world"]). ! text(yellow,448,96,2,3,4,1,0,[ "hello world"]). ! text(yellow,448,112,3,3,4,1,0,[ "hello world"]). ! text(yellow,448,128,4,3,4,1,0,[ "hello world"]). ! text(yellow,64,192,0,0,5,1,0,[ "hello world"]). ! text(yellow,64,208,1,0,5,1,0,[ "hello world"]). ! text(yellow,64,224,2,0,5,1,0,[ "hello world"]). ! text(yellow,64,240,3,0,5,1,0,[ "hello world"]). ! text(yellow,64,256,4,0,5,1,0,[ "hello world"]). ! text(yellow,256,192,0,1,5,1,0,[ "hello world"]). ! text(yellow,256,208,1,1,5,1,0,[ "hello world"]). ! text(yellow,256,224,2,1,5,1,0,[ "hello world"]). ! text(yellow,256,240,3,1,5,1,0,[ "hello world"]). ! text(yellow,256,256,4,1,5,1,0,[ "hello world"]). ! text(yellow,448,192,0,2,5,1,0,[ "hello world"]). ! text(yellow,448,208,1,2,5,1,0,[ "hello world"]). ! text(yellow,448,224,2,2,5,1,0,[ "hello world"]). ! text(yellow,448,240,3,2,5,1,0,[ "hello world"]). ! text(yellow,448,256,4,2,5,1,0,[ "hello world"]). ! text(yellow,640,192,0,3,5,1,0,[ "hello world"]). ! text(yellow,640,208,1,3,5,1,0,[ "hello world"]). ! text(yellow,640,224,2,3,5,1,0,[ "hello world"]). ! text(yellow,640,240,3,3,5,1,0,[ "hello world"]). ! text(yellow,640,256,4,3,5,1,0,[ "hello world"]). ! text(yellow,64,320,0,0,3,1,0,[ "hello world"]). ! text(yellow,64,336,1,0,3,1,0,[ "hello world"]). ! text(yellow,64,352,2,0,3,1,0,[ "hello world"]). ! text(yellow,64,368,3,0,3,1,0,[ "hello world"]). ! text(yellow,64,384,4,0,3,1,0,[ "hello world"]). ! text(yellow,192,320,0,1,3,1,0,[ "hello world"]). ! text(yellow,192,336,1,1,3,1,0,[ "hello world"]). ! text(yellow,192,352,2,1,3,1,0,[ "hello world"]). ! text(yellow,192,368,3,1,3,1,0,[ "hello world"]). ! text(yellow,192,384,4,1,3,1,0,[ "hello world"]). ! text(yellow,320,320,0,2,3,1,0,[ "hello world"]). ! text(yellow,320,336,1,2,3,1,0,[ "hello world"]). ! text(yellow,320,352,2,2,3,1,0,[ "hello world"]). ! text(yellow,320,368,3,2,3,1,0,[ "hello world"]). ! text(yellow,320,384,4,2,3,1,0,[ "hello world"]). ! text(yellow,448,320,0,3,3,1,0,[ "hello world"]). ! text(yellow,448,336,1,3,3,1,0,[ "hello world"]). ! text(yellow,448,352,2,3,3,1,0,[ "hello world"]). ! text(yellow,448,368,3,3,3,1,0,[ "hello world"]). ! text(yellow,448,384,4,3,3,1,0,[ "hello world"]). ! text(yellow,64,448,0,0,2,1,0,[ "hello world"]). ! text(yellow,64,464,1,0,2,1,0,[ "hello world"]). ! text(yellow,64,480,2,0,2,1,0,[ "hello world"]). ! text(yellow,64,496,3,0,2,1,0,[ "hello world"]). ! text(yellow,64,512,4,0,2,1,0,[ "hello world"]). ! text(yellow,192,448,0,1,2,1,0,[ "hello world"]). ! text(yellow,192,464,1,1,2,1,0,[ "hello world"]). ! text(yellow,192,480,2,1,2,1,0,[ "hello world"]). ! text(yellow,192,496,3,1,2,1,0,[ "hello world"]). ! text(yellow,192,512,4,1,2,1,0,[ "hello world"]). ! text(yellow,320,448,0,2,2,1,0,[ "hello world"]). ! text(yellow,320,464,1,2,2,1,0,[ "hello world"]). ! text(yellow,320,480,2,2,2,1,0,[ "hello world"]). ! text(yellow,320,496,3,2,2,1,0,[ "hello world"]). ! text(yellow,320,512,4,2,2,1,0,[ "hello world"]). ! text(yellow,448,448,0,3,2,1,0,[ "hello world"]). ! text(yellow,448,464,1,3,2,1,0,[ "hello world"]). ! text(yellow,448,480,2,3,2,1,0,[ "hello world"]). ! text(yellow,448,496,3,3,2,1,0,[ "hello world"]). ! text(yellow,448,512,4,3,2,1,0,[ "hello world"]). ! text(yellow,64,576,0,0,1,1,0,[ "hello world"]). ! text(yellow,64,592,1,0,1,1,0,[ "hello world"]). ! text(yellow,64,608,2,0,1,1,0,[ "hello world"]). ! text(yellow,64,624,3,0,1,1,0,[ "hello world"]). ! text(yellow,64,640,4,0,1,1,0,[ "hello world"]). ! text(yellow,192,576,0,1,1,1,0,[ "hello world"]). ! text(yellow,192,592,1,1,1,1,0,[ "hello world"]). ! text(yellow,192,608,2,1,1,1,0,[ "hello world"]). ! text(yellow,192,624,3,1,1,1,0,[ "hello world"]). ! text(yellow,192,640,4,1,1,1,0,[ "hello world"]). ! text(yellow,320,576,0,2,1,1,0,[ "hello world"]). ! text(yellow,320,592,1,2,1,1,0,[ "hello world"]). ! text(yellow,320,608,2,2,1,1,0,[ "hello world"]). ! text(yellow,320,624,3,2,1,1,0,[ "hello world"]). ! text(yellow,320,640,4,2,1,1,0,[ "hello world"]). ! text(yellow,448,576,0,3,1,1,0,[ "hello world"]). ! text(yellow,448,592,1,3,1,1,0,[ "hello world"]). ! text(yellow,448,608,2,3,1,1,0,[ "hello world"]). ! text(yellow,448,624,3,3,1,1,0,[ "hello world"]). ! text(yellow,448,640,4,3,1,1,0,[ "hello world"]). ! text(yellow,64,704,0,0,0,1,0,[ "hello world"]). ! text(yellow,64,720,1,0,0,1,0,[ "hello world"]). ! text(yellow,64,736,2,0,0,1,0,[ "hello world"]). ! text(yellow,64,752,3,0,0,1,0,[ "hello world"]). ! text(yellow,64,768,4,0,0,1,0,[ "hello world"]). ! text(yellow,192,704,0,1,0,1,0,[ "hello world"]). ! text(yellow,192,720,1,1,0,1,0,[ "hello world"]). ! text(yellow,192,736,2,1,0,1,0,[ "hello world"]). ! text(yellow,192,752,3,1,0,1,0,[ "hello world"]). ! text(yellow,192,768,4,1,0,1,0,[ "hello world"]). ! text(yellow,320,704,0,2,0,1,0,[ "hello world"]). ! text(yellow,320,720,1,2,0,1,0,[ "hello world"]). ! text(yellow,320,736,2,2,0,1,0,[ "hello world"]). ! text(yellow,320,752,3,2,0,1,0,[ "hello world"]). ! text(yellow,320,768,4,2,0,1,0,[ "hello world"]). ! text(yellow,448,704,0,3,0,1,0,[ "hello world"]). ! text(yellow,448,720,1,3,0,1,0,[ "hello world"]). ! text(yellow,448,736,2,3,0,1,0,[ "hello world"]). ! text(yellow,448,752,3,3,0,1,0,[ "hello world"]). ! text(yellow,448,768,4,3,0,1,0,[ "hello world"]). --- 1,241 ---- ! state(0,7,0,0,0,16,1,0,1,1,1,0,1,2,7,0,0,3,4). ! text(yellow,64,64,0,0,4,1,0,0,1,83,19,[ "hello world"]). ! text(yellow,64,80,1,0,4,1,0,0,1,121,17,[ "hello world"]). ! text(yellow,64,96,2,0,4,1,0,0,1,90,20,[ "hello world"]). ! text(yellow,64,112,3,0,4,1,0,0,1,94,20,[ "hello world"]). ! text(yellow,64,128,4,0,4,1,0,0,1,105,18,[ "hello world"]). ! text(yellow,256,64,0,1,4,1,0,0,1,89,19,[ "hello world"]). ! text(yellow,256,80,1,1,4,1,0,0,1,121,18,[ "hello world"]). ! text(yellow,256,96,2,1,4,1,0,0,1,98,21,[ "hello world"]). ! text(yellow,256,112,3,1,4,1,0,0,1,107,20,[ "hello world"]). ! text(yellow,256,128,4,1,4,1,0,0,1,105,18,[ "hello world"]). ! text(yellow,448,64,0,2,4,1,0,0,1,84,19,[ "hello world"]). ! text(yellow,448,80,1,2,4,1,0,0,1,121,17,[ "hello world"]). ! text(yellow,448,96,2,2,4,1,0,0,1,88,21,[ "hello world"]). ! text(yellow,448,112,3,2,4,1,0,0,1,94,24,[ "hello world"]). ! text(yellow,448,128,4,2,4,1,0,0,1,105,18,[ "hello world"]). ! text(yellow,640,64,0,3,4,1,0,0,1,85,19,[ "hello world"]). ! text(yellow,640,80,1,3,4,1,0,0,1,121,17,[ "hello world"]). ! text(yellow,640,96,2,3,4,1,0,0,1,93,21,[ "hello world"]). ! text(yellow,640,112,3,3,4,1,0,0,1,104,24,[ "hello world"]). ! text(yellow,640,128,4,3,4,1,0,0,1,105,18,[ "hello world"]). ! text(yellow,64,192,0,0,5,1,0,0,1,109,26,[ "hello world"]). ! text(yellow,64,208,1,0,5,1,0,0,1,165,22,[ "hello world"]). ! text(yellow,64,224,2,0,5,1,0,0,1,117,27,[ "hello world"]). ! text(yellow,64,240,3,0,5,1,0,0,1,125,26,[ "hello world"]). ! text(yellow,64,256,4,0,5,1,0,0,1,140,24,[ "hello world"]). ! text(yellow,288,192,0,1,5,1,0,0,1,121,26,[ "hello world"]). ! text(yellow,288,208,1,1,5,1,0,0,1,165,23,[ "hello world"]). ! text(yellow,288,224,2,1,5,1,0,0,1,128,27,[ "hello world"]). ! text(yellow,288,240,3,1,5,1,0,0,1,148,26,[ "hello world"]). ! text(yellow,288,256,4,1,5,1,0,0,1,140,24,[ "hello world"]). ! text(yellow,512,192,0,2,5,1,0,0,1,110,25,[ "hello world"]). ! text(yellow,512,208,1,2,5,1,0,0,1,165,22,[ "hello world"]). ! text(yellow,512,224,2,2,5,1,0,0,1,117,27,[ "hello world"]). ! text(yellow,512,240,3,2,5,1,0,0,1,127,26,[ "hello world"]). ! text(yellow,512,256,4,2,5,1,0,0,1,140,24,[ "hello world"]). ! text(yellow,736,192,0,3,5,1,0,0,1,113,25,[ "hello world"]). ! text(yellow,736,208,1,3,5,1,0,0,1,165,28,[ "hello world"]). ! text(yellow,736,224,2,3,5,1,0,0,1,128,27,[ "hello world"]). ! text(yellow,736,240,3,3,5,1,0,0,1,140,26,[ "hello world"]). ! text(yellow,736,256,4,3,5,1,0,0,1,140,24,[ "hello world"]). ! text(yellow,64,320,0,0,3,1,0,0,1,63,15,[ "hello world"]). ! text(yellow,64,336,1,0,3,1,0,0,1,99,14,[ "hello world"]). ! text(yellow,64,352,2,0,3,1,0,0,1,67,16,[ "hello world"]). ! text(yellow,64,368,3,0,3,1,0,0,1,72,16,[ "hello world"]). ! text(yellow,64,384,4,0,3,1,0,0,1,84,14,[ "hello world"]). ! text(yellow,192,320,0,1,3,1,0,0,1,70,15,[ "hello world"]). ! text(yellow,192,336,1,1,3,1,0,0,1,99,15,[ "hello world"]). ! text(yellow,192,352,2,1,3,1,0,0,1,76,16,[ "hello world"]). ! text(yellow,192,368,3,1,3,1,0,0,1,84,16,[ "hello world"]). ! text(yellow,192,384,4,1,3,1,0,0,1,84,14,[ "hello world"]). ! text(yellow,320,320,0,2,3,1,0,0,1,64,15,[ "hello world"]). ! text(yellow,320,336,1,2,3,1,0,0,1,99,14,[ "hello world"]). ! text(yellow,320,352,2,2,3,1,0,0,1,68,16,[ "hello world"]). ! text(yellow,320,368,3,2,3,1,0,0,1,71,16,[ "hello world"]). ! text(yellow,320,384,4,2,3,1,0,0,1,84,14,[ "hello world"]). ! text(yellow,448,320,0,3,3,1,0,0,1,66,15,[ "hello world"]). ! text(yellow,448,336,1,3,3,1,0,0,1,99,15,[ "hello world"]). ! text(yellow,448,352,2,3,3,1,0,0,1,75,16,[ "hello world"]). ! text(yellow,448,368,3,3,3,1,0,0,1,82,16,[ "hello world"]). ! text(yellow,448,384,4,3,3,1,0,0,1,84,14,[ "hello world"]). ! text(yellow,64,448,0,0,2,1,0,0,1,55,14,[ "hello world"]). ! text(yellow,64,464,1,0,2,1,0,0,1,77,13,[ "hello world"]). ! text(yellow,64,480,2,0,2,1,0,0,1,61,14,[ "hello world"]). ! text(yellow,64,496,3,0,2,1,0,0,1,64,14,[ "hello world"]). ! text(yellow,64,512,4,0,2,1,0,0,1,75,12,[ "hello world"]). ! text(yellow,192,448,0,1,2,1,0,0,1,59,14,[ "hello world"]). ! text(yellow,192,464,1,1,2,1,0,0,1,77,13,[ "hello world"]). ! text(yellow,192,480,2,1,2,1,0,0,1,64,14,[ "hello world"]). ! text(yellow,192,496,3,1,2,1,0,0,1,77,14,[ "hello world"]). ! text(yellow,192,512,4,1,2,1,0,0,1,75,12,[ "hello world"]). ! text(yellow,320,448,0,2,2,1,0,0,1,55,14,[ "hello world"]). ! text(yellow,320,464,1,2,2,1,0,0,1,77,13,[ "hello world"]). ! text(yellow,320,480,2,2,2,1,0,0,1,60,14,[ "hello world"]). ! text(yellow,320,496,3,2,2,1,0,0,1,64,14,[ "hello world"]). ! text(yellow,320,512,4,2,2,1,0,0,1,75,12,[ "hello world"]). ! text(yellow,448,448,0,3,2,1,0,0,1,58,14,[ "hello world"]). ! text(yellow,448,464,1,3,2,1,0,0,1,77,13,[ "hello world"]). ! text(yellow,448,480,2,3,2,1,0,0,1,63,14,[ "hello world"]). ! text(yellow,448,496,3,3,2,1,0,0,1,70,14,[ "hello world"]). ! text(yellow,448,512,4,3,2,1,0,0,1,75,12,[ "hello world"]). ! text(yellow,64,576,0,0,1,1,0,0,1,50,12,[ "hello world"]). ! text(yellow,64,592,1,0,1,1,0,0,1,66,10,[ "hello world"]). ! text(yellow,64,608,2,0,1,1,0,0,1,50,12,[ "hello world"]). ! text(yellow,64,624,3,0,1,1,0,0,1,54,12,[ "hello world"]). ! text(yellow,64,640,4,0,1,1,0,0,1,60,10,[ "hello world"]). ! text(yellow,192,576,0,1,1,1,0,0,1,49,12,[ "hello world"]). ! text(yellow,192,592,1,1,1,1,0,0,1,66,10,[ "hello world"]). ! text(yellow,192,608,2,1,1,1,0,0,1,54,12,[ "hello world"]). ! text(yellow,192,624,3,1,1,1,0,0,1,66,12,[ "hello world"]). ! text(yellow,192,640,4,1,1,1,0,0,1,60,10,[ "hello world"]). ! text(yellow,320,576,0,2,1,1,0,0,1,47,12,[ "hello world"]). ! text(yellow,320,592,1,2,1,1,0,0,1,66,10,[ "hello world"]). ! text(yellow,320,608,2,2,1,1,0,0,1,49,12,[ "hello world"]). ! text(yellow,320,624,3,2,1,1,0,0,1,54,12,[ "hello world"]). ! text(yellow,320,640,4,2,1,1,0,0,1,60,10,[ "hello world"]). ! text(yellow,448,576,0,3,1,1,0,0,1,47,12,[ "hello world"]). ! text(yellow,448,592,1,3,1,1,0,0,1,66,10,[ "hello world"]). ! text(yellow,448,608,2,3,1,1,0,0,1,54,12,[ "hello world"]). ! text(yellow,448,624,3,3,1,1,0,0,1,61,12,[ "hello world"]). ! text(yellow,448,640,4,3,1,1,0,0,1,60,10,[ "hello world"]). ! text(yellow,64,704,0,0,0,1,0,0,1,40,9,[ "hello world"]). ! text(yellow,64,720,1,0,0,1,0,0,1,55,9,[ "hello world"]). ! text(yellow,64,736,2,0,0,1,0,0,1,41,10,[ "hello world"]). ! text(yellow,64,752,3,0,0,1,0,0,1,43,9,[ "hello world"]). ! text(yellow,64,768,4,0,0,1,0,0,1,48,11,[ "hello world"]). ! text(yellow,192,704,0,1,0,1,0,0,1,39,9,[ "hello world"]). ! text(yellow,192,720,1,1,0,1,0,0,1,55,10,[ "hello world"]). ! text(yellow,192,736,2,1,0,1,0,0,1,42,10,[ "hello world"]). ! text(yellow,192,752,3,1,0,1,0,0,1,55,9,[ "hello world"]). ! text(yellow,192,768,4,1,0,1,0,0,1,48,11,[ "hello world"]). ! text(yellow,320,704,0,2,0,1,0,0,1,38,9,[ "hello world"]). ! text(yellow,320,720,1,2,0,1,0,0,1,55,10,[ "hello world"]). ! text(yellow,320,736,2,2,0,1,0,0,1,40,10,[ "hello world"]). ! text(yellow,320,752,3,2,0,1,0,0,1,43,9,[ "hello world"]). ! text(yellow,320,768,4,2,0,1,0,0,1,48,11,[ "hello world"]). ! text(yellow,448,704,0,3,0,1,0,0,1,37,9,[ "hello world"]). ! text(yellow,448,720,1,3,0,1,0,0,1,55,10,[ "hello world"]). ! text(yellow,448,736,2,3,0,1,0,0,1,42,10,[ "hello world"]). ! text(yellow,448,752,3,3,0,1,0,0,1,50,9,[ "hello world"]). ! text(yellow,448,768,4,3,0,1,0,0,1,48,11,[ "hello world"]). *** slide-demo.obj.orig Wed Jun 27 09:16:33 1990 --- slide-demo.obj Mon Jul 30 17:57:38 1990 *************** *** 1,7 **** ! state(4,6,0,0,0,16,1,0,1,2,0,0,1,2,1,1,1,0,4). polygon(magenta,5,[144,32,144,152,336,152,336,32,144,32],1,4,10,1). ! text(magenta,240,48,0,0,5,1,1,0,2,[ "A Slide"]). ! text(magenta,240,112,3,2,5,1,1,0,2,[ "Tgif"]). group([ --- 1,7 ---- ! state(4,7,0,0,0,16,1,0,1,2,0,0,1,2,1,1,1,0,4). polygon(magenta,5,[144,32,144,152,336,152,336,32,144,32],1,4,10,1). ! text(magenta,240,48,0,0,5,1,1,0,2,71,26,[ "A Slide"]). ! text(magenta,240,112,3,2,5,1,1,0,2,43,26,[ "Tgif"]). group([ *************** *** 10,18 **** ],[ ]). ! text(magenta,64,183,0,1,4,1,0,0,1,[ "Dot is at 0.5 inch from the left."]). ! text(magenta,64,246,2,0,4,1,0,0,1,[ "Text is at 1 inch from the left."]). ! text(magenta,96,308,3,3,4,1,0,0,1,[ "This text is at 1.5 inch from the left."]). group([ --- 10,18 ---- ],[ ]). ! text(magenta,64,183,0,1,4,1,0,0,1,241,19,[ "Dot is at 0.5 inch from the left."]). ! text(magenta,64,246,2,0,4,1,0,0,1,239,20,[ "Text is at 1 inch from the left."]). ! text(magenta,96,308,3,3,4,1,0,0,1,322,24,[ "This text is at 1.5 inch from the left."]). group([ *************** *** 21,49 **** ],[ ]). ! text(magenta,128,464,0,0,3,1,1,0,1,[ "2in"]). ! text(magenta,256,464,0,0,3,1,1,0,1,[ "4in"]). ! text(magenta,384,464,0,0,3,1,1,0,1,[ "6in"]). ! text(magenta,448,512,0,0,3,1,1,0,1,[ "7in"]). ! text(magenta,320,512,0,0,3,1,1,0,1,[ "5in"]). ! text(magenta,192,512,0,0,3,1,1,0,1,[ "3in"]). ! text(magenta,64,512,0,0,3,1,1,0,1,[ "1in"]). ! text(magenta,384,144,1,0,0,1,1,0,1,[ "8pt"]). ! text(magenta,384,160,1,0,1,1,1,0,1,[ "10pt"]). ! text(magenta,384,176,1,0,2,1,1,0,1,[ "12pt"]). ! text(magenta,384,192,1,0,3,1,1,0,1,[ "14pt"]). ! text(magenta,384,208,1,0,4,1,1,0,1,[ "18pt"]). ! text(magenta,384,224,1,0,5,1,1,0,1,[ "24pt"]). poly(magenta,2,[384,336,384,456],2,0,1,8,0,0,[ --- 21,49 ---- ],[ ]). ! text(magenta,128,464,0,0,3,1,1,0,1,17,15,[ "2in"]). ! text(magenta,256,464,0,0,3,1,1,0,1,17,15,[ "4in"]). ! text(magenta,384,464,0,0,3,1,1,0,1,17,15,[ "6in"]). ! text(magenta,448,512,0,0,3,1,1,0,1,17,15,[ "7in"]). ! text(magenta,320,512,0,0,3,1,1,0,1,17,15,[ "5in"]). ! text(magenta,192,512,0,0,3,1,1,0,1,17,15,[ "3in"]). ! text(magenta,64,512,0,0,3,1,1,0,1,17,15,[ "1in"]). ! text(magenta,384,144,1,0,0,1,1,0,1,15,9,[ "8pt"]). ! text(magenta,384,160,1,0,1,1,1,0,1,24,10,[ "10pt"]). ! text(magenta,384,176,1,0,2,1,1,0,1,28,13,[ "12pt"]). ! text(magenta,384,192,1,0,3,1,1,0,1,36,14,[ "14pt"]). ! text(magenta,384,208,1,0,4,1,1,0,1,44,17,[ "18pt"]). ! text(magenta,384,224,1,0,5,1,1,0,1,60,22,[ "24pt"]). poly(magenta,2,[384,336,384,456],2,0,1,8,0,0,[ *************** *** 61,64 **** poly(magenta,2,[64,336,64,504],2,0,1,13,0,0,[ ]). ! text(magenta,240,80,2,0,5,1,1,0,7,[ "Presented by"]). --- 61,64 ---- poly(magenta,2,[64,336,64,504],2,0,1,13,0,0,[ ]). ! text(magenta,240,80,2,0,5,1,1,0,7,145,27,[ "Presented by"]). *** tgificon.obj.orig Wed Jun 27 09:14:47 1990 --- tgificon.obj Mon Jul 30 17:57:40 1990 *************** *** 1,3 **** ! state(0,6,0,0,0,16,1,4,0,3,0,0,1,2,1,0,3,0,5). group([ group([ --- 1,3 ---- ! state(0,7,0,0,0,16,1,4,0,3,0,0,1,2,1,0,3,0,5). group([ group([ *************** *** 11,21 **** ],[ ]), ! text(yellow,40,6,0,3,3,1,1,0,1,[ "T"]), ! text(yellow,30,24,1,1,3,1,1,0,1,[ "G"]), ! text(yellow,50,43,3,3,3,1,1,0,1,[ "I"]), ! text(yellow,30,52,2,3,3,1,1,0,1,[ "F"]) ],[ --- 11,21 ---- ],[ ]), ! text(yellow,40,6,0,3,3,1,1,0,1,10,15,[ "T"]), ! text(yellow,30,24,1,1,3,1,1,0,1,9,15,[ "G"]), ! text(yellow,50,43,3,3,3,1,1,0,1,6,16,[ "I"]), ! text(yellow,30,52,2,3,3,1,1,0,1,8,16,[ "F"]) ],[ *** flip-flop.sym.orig Wed Jun 27 09:16:34 1990 --- flip-flop.sym Mon Jul 30 17:58:02 1990 *************** *** 1,16 **** ! state(0,6,0,0,0,8,1,8,0,2,0,1,0,0,1,0,0,0,4). ! text(white,496,184,0,0,4,1,0,0,1,[ "definition part of the NAND gate."]). ! text(white,448,160,0,0,4,1,0,0,1,[ "Select a NAND gate and type ^V to see the"]). ! text(white,496,136,0,0,4,1,0,0,1,[ "building-block object."]). ! text(white,448,112,0,0,4,1,0,0,1,[ "The rest of this file is the definition part of the"]). ! text(white,496,88,0,0,4,1,0,0,1,[ "is highlighted with a dashed outline."]). ! text(white,448,64,0,0,4,1,0,0,1,[ "The representation part of the flip-flop"]). ! text(white,448,40,0,0,4,1,0,0,1,[ "The SR flip-flop is a building-block object."]). icon([ --- 1,16 ---- ! state(0,7,0,0,0,8,1,8,0,2,0,1,0,0,1,0,0,0,4). ! text(white,496,184,0,0,4,1,0,0,1,252,19,[ "definition part of the NAND gate."]). ! text(white,448,160,0,0,4,1,0,0,1,317,19,[ "Select a NAND gate and type ^V to see the"]). ! text(white,496,136,0,0,4,1,0,0,1,164,19,[ "building-block object."]). ! text(white,448,112,0,0,4,1,0,0,1,341,19,[ "The rest of this file is the definition part of the"]). ! text(white,496,88,0,0,4,1,0,0,1,264,19,[ "is highlighted with a dashed outline."]). ! text(white,448,64,0,0,4,1,0,0,1,293,19,[ "The representation part of the flip-flop"]). ! text(white,448,40,0,0,4,1,0,0,1,321,19,[ "The SR flip-flop is a building-block object."]). icon([ *************** *** 40,47 **** "pin",17,[ attr("name=", "out", 0, 1, 1, ! text(green,312,272,1,0,4,1,1,0,1,[ "name=out"])), attr("num=", "3", 1, 0, 1, ! text(green,296,280,1,0,4,1,1,0,1,[ "3"])) ]), --- 40,47 ---- "pin",17,[ attr("name=", "out", 0, 1, 1, ! text(green,312,272,1,0,4,1,1,0,1,88,17,[ "name=out"])), attr("num=", "3", 1, 0, 1, ! text(green,296,280,1,0,4,1,1,0,1,11,17,[ "3"])) ]), *************** *** 52,59 **** "pin",18,[ attr("num=", "1", 1, 0, 1, ! text(green,184,256,1,0,4,1,1,0,1,[ "1"])), attr("name=", "in1", 0, 1, 1, ! text(green,168,248,1,0,4,1,1,0,1,[ "name=in1"])) ]), --- 52,59 ---- "pin",18,[ attr("num=", "1", 1, 0, 1, ! text(green,184,256,1,0,4,1,1,0,1,11,17,[ "1"])), attr("name=", "in1", 0, 1, 1, ! text(green,168,248,1,0,4,1,1,0,1,88,17,[ "name=in1"])) ]), *************** *** 64,71 **** "pin",19,[ attr("name=", "in2", 0, 1, 1, ! text(green,168,296,1,0,4,1,1,0,1,[ "name=in2"])), attr("num=", "2", 1, 0, 1, ! text(green,184,304,1,0,4,1,1,0,1,[ "2"])) ]) --- 64,71 ---- "pin",19,[ attr("name=", "in2", 0, 1, 1, ! text(green,168,296,1,0,4,1,1,0,1,88,17,[ "name=in2"])), attr("num=", "2", 1, 0, 1, ! text(green,184,304,1,0,4,1,1,0,1,11,17,[ "2"])) ]) *************** *** 73,77 **** "nand2",26,[ attr("LOC=", "", 1, 1, 1, ! text(red,228,285,1,0,5,1,1,0,1,[ "LOC="])) ]). --- 73,77 ---- "nand2",26,[ attr("LOC=", "", 1, 1, 1, ! text(red,228,285,1,0,5,1,1,0,1,60,22,[ "LOC="])) ]). *************** *** 102,109 **** "pin",33,[ attr("num=", "3", 1, 0, 1, ! text(green,296,400,1,0,4,1,1,0,1,[ "3"])), attr("name=", "out", 0, 1, 1, ! text(green,312,392,1,0,4,1,1,0,1,[ "name=out"])) ]), --- 102,109 ---- "pin",33,[ attr("num=", "3", 1, 0, 1, ! text(green,296,400,1,0,4,1,1,0,1,11,17,[ "3"])), attr("name=", "out", 0, 1, 1, ! text(green,312,392,1,0,4,1,1,0,1,88,17,[ "name=out"])) ]), *************** *** 114,121 **** "pin",34,[ attr("name=", "in1", 0, 1, 1, ! text(green,168,368,1,0,4,1,1,0,1,[ "name=in1"])), attr("num=", "1", 1, 0, 1, ! text(green,184,376,1,0,4,1,1,0,1,[ "1"])) ]), --- 114,121 ---- "pin",34,[ attr("name=", "in1", 0, 1, 1, ! text(green,168,368,1,0,4,1,1,0,1,88,17,[ "name=in1"])), attr("num=", "1", 1, 0, 1, ! text(green,184,376,1,0,4,1,1,0,1,11,17,[ "1"])) ]), *************** *** 126,133 **** "pin",35,[ attr("num=", "2", 1, 0, 1, ! text(green,184,424,1,0,4,1,1,0,1,[ "2"])), attr("name=", "in2", 0, 1, 1, ! text(green,168,416,1,0,4,1,1,0,1,[ "name=in2"])) ]) --- 126,133 ---- "pin",35,[ attr("num=", "2", 1, 0, 1, ! text(green,184,424,1,0,4,1,1,0,1,11,17,[ "2"])), attr("name=", "in2", 0, 1, 1, ! text(green,168,416,1,0,4,1,1,0,1,88,17,[ "name=in2"])) ]) *************** *** 135,139 **** "nand2",36,[ attr("LOC=", "", 1, 1, 1, ! text(red,228,405,1,0,5,1,1,0,1,[ "LOC="])) ]). --- 135,139 ---- "nand2",36,[ attr("LOC=", "", 1, 1, 1, ! text(red,228,405,1,0,5,1,1,0,1,60,22,[ "LOC="])) ]). *************** *** 161,168 **** "pin",43,[ attr("name=", "Q", 1, 0, 1, ! text(green,264,96,1,0,4,1,1,0,1,[ "Q"])), attr("num=", "", 0, 1, 1, ! text(green,296,64,1,0,4,1,1,0,1,[ "num="])) ]), --- 161,168 ---- "pin",43,[ attr("name=", "Q", 1, 0, 1, ! text(green,264,96,1,0,4,1,1,0,1,11,17,[ "Q"])), attr("num=", "", 0, 1, 1, ! text(green,296,64,1,0,4,1,1,0,1,44,17,[ "num="])) ]), *************** *** 173,180 **** "pin",44,[ attr("num=", "", 0, 1, 1, ! text(green,296,112,1,0,4,1,1,0,1,[ "num="])), attr("name=", "Q'", 1, 0, 1, ! text(green,256,144,1,0,4,1,1,0,1,[ "Q'"])) ]), --- 173,180 ---- "pin",44,[ attr("num=", "", 0, 1, 1, ! text(green,296,112,1,0,4,1,1,0,1,44,17,[ "num="])), attr("name=", "Q'", 1, 0, 1, ! text(green,256,144,1,0,4,1,1,0,1,22,17,[ "Q'"])) ]), *************** *** 185,192 **** "pin",45,[ attr("num=", "", 0, 1, 1, ! text(green,184,64,1,0,4,1,1,0,1,[ "num="])), attr("name=", "S'", 1, 0, 1, ! text(green,224,96,1,0,4,1,1,0,1,[ "S'"])) ]), --- 185,192 ---- "pin",45,[ attr("num=", "", 0, 1, 1, ! text(green,184,64,1,0,4,1,1,0,1,44,17,[ "num="])), attr("name=", "S'", 1, 0, 1, ! text(green,224,96,1,0,4,1,1,0,1,22,17,[ "S'"])) ]), *************** *** 197,204 **** "pin",46,[ attr("name=", "R'", 1, 0, 1, ! text(green,224,144,1,0,4,1,1,0,1,[ "R'"])), attr("num=", "", 0, 1, 1, ! text(green,184,112,1,0,4,1,1,0,1,[ "num="])) ]) --- 197,204 ---- "pin",46,[ attr("name=", "R'", 1, 0, 1, ! text(green,224,144,1,0,4,1,1,0,1,22,17,[ "R'"])), attr("num=", "", 0, 1, 1, ! text(green,184,112,1,0,4,1,1,0,1,44,17,[ "num="])) ]) *** nand2.sym.orig Wed Jun 27 09:16:36 1990 --- nand2.sym Mon Jul 30 17:58:05 1990 *************** *** 1,24 **** ! state(0,6,0,0,0,8,1,8,0,2,0,1,0,0,1,0,0,0,4). ! text(white,320,264,0,0,4,1,0,0,1,[ "Select a pin icon and type #M to look at the pin attributes."]). ! text(white,320,240,0,0,4,1,0,0,1,[ "You can actually push into the little squares which are pins."]). ! text(white,320,216,0,0,4,1,0,0,1,[ "Ungroup the little pieces and see what is it made of."]). ! text(white,384,192,0,0,4,1,0,0,1,[ "box go away."]). ! text(white,320,168,0,0,4,1,0,0,1,[ "Select the UnMakeSymbolic item and see the dashed"]). ! text(white,384,144,0,0,4,1,0,0,1,[ "named ``special''."]). ! text(white,384,120,0,0,4,1,0,0,1,[ "the right mouse button, then select the last entry"]). ! text(white,320,96,0,0,4,1,0,0,1,[ "Select one of the NAND gates, pop up the main menu using"]). ! text(white,320,72,0,0,4,1,0,0,1,[ "Make a copy of the NAND gate."]). ! text(white,320,48,0,0,4,1,0,0,1,[ "It is therefore a ``primitive'' building-block object."]). ! text(white,320,24,0,0,4,1,0,0,1,[ "The NAND gate has no implementation part."]). sym([ --- 1,24 ---- ! state(0,7,0,0,0,8,1,8,0,2,0,1,0,0,1,0,0,0,4). ! text(white,320,264,0,0,4,1,0,0,1,428,19,[ "Select a pin icon and type #M to look at the pin attributes."]). ! text(white,320,240,0,0,4,1,0,0,1,436,19,[ "You can actually push into the little squares which are pins."]). ! text(white,320,216,0,0,4,1,0,0,1,377,19,[ "Ungroup the little pieces and see what is it made of."]). ! text(white,384,192,0,0,4,1,0,0,1,94,19,[ "box go away."]). ! text(white,320,168,0,0,4,1,0,0,1,390,19,[ "Select the UnMakeSymbolic item and see the dashed"]). ! text(white,384,144,0,0,4,1,0,0,1,129,19,[ "named ``special''."]). ! text(white,384,120,0,0,4,1,0,0,1,356,19,[ "the right mouse button, then select the last entry"]). ! text(white,320,96,0,0,4,1,0,0,1,438,19,[ "Select one of the NAND gates, pop up the main menu using"]). ! text(white,320,72,0,0,4,1,0,0,1,237,19,[ "Make a copy of the NAND gate."]). ! text(white,320,48,0,0,4,1,0,0,1,374,19,[ "It is therefore a ``primitive'' building-block object."]). ! text(white,320,24,0,0,4,1,0,0,1,338,19,[ "The NAND gate has no implementation part."]). sym([ *************** *** 48,55 **** "pin",17,[ attr("name=", "out", 0, 1, 1, ! text(green,256,104,1,0,4,1,1,0,1,[ "name=out"])), attr("num=", "3", 1, 0, 1, ! text(green,240,112,1,0,4,1,1,0,1,[ "3"])) ]), --- 48,55 ---- "pin",17,[ attr("name=", "out", 0, 1, 1, ! text(green,256,104,1,0,4,1,1,0,1,88,17,[ "name=out"])), attr("num=", "3", 1, 0, 1, ! text(green,240,112,1,0,4,1,1,0,1,11,17,[ "3"])) ]), *************** *** 60,67 **** "pin",18,[ attr("num=", "1", 1, 0, 1, ! text(green,128,88,1,0,4,1,1,0,1,[ "1"])), attr("name=", "in1", 0, 1, 1, ! text(green,112,80,1,0,4,1,1,0,1,[ "name=in1"])) ]), --- 60,67 ---- "pin",18,[ attr("num=", "1", 1, 0, 1, ! text(green,128,88,1,0,4,1,1,0,1,11,17,[ "1"])), attr("name=", "in1", 0, 1, 1, ! text(green,112,80,1,0,4,1,1,0,1,88,17,[ "name=in1"])) ]), *************** *** 72,79 **** "pin",19,[ attr("name=", "in2", 0, 1, 1, ! text(green,112,128,1,0,4,1,1,0,1,[ "name=in2"])), attr("num=", "2", 1, 0, 1, ! text(green,128,136,1,0,4,1,1,0,1,[ "2"])) ]) --- 72,79 ---- "pin",19,[ attr("name=", "in2", 0, 1, 1, ! text(green,112,128,1,0,4,1,1,0,1,88,17,[ "name=in2"])), attr("num=", "2", 1, 0, 1, ! text(green,128,136,1,0,4,1,1,0,1,11,17,[ "2"])) ]) *************** *** 80,84 **** ],[ attr("LOC=", "", 1, 1, 0, ! text(red,172,117,1,0,5,1,1,0,1,[ "LOC="])) ]). --- 80,84 ---- ],[ attr("LOC=", "", 1, 1, 0, ! text(red,172,117,1,0,5,1,1,0,1,60,22,[ "LOC="])) ]). *** pin.sym.orig Wed Jun 27 09:16:36 1990 --- pin.sym Mon Jul 30 17:58:08 1990 *************** *** 1,3 **** ! state(0,6,0,0,0,16,1,4,2,2,0,0,0,0,1,1,1,0,5). sym([ box(yellow,96,96,128,128,0,0,0), --- 1,3 ---- ! state(0,7,0,0,0,16,1,4,2,2,0,0,0,0,1,1,1,0,5). sym([ box(yellow,96,96,128,128,0,0,0), *************** *** 5,12 **** ],[ attr("name=", "", 1, 1, 0, ! text(green,112,88,1,0,4,1,1,0,1,[ "name="])), attr("num=", "", 1, 1, 0, ! text(green,112,72,1,0,4,1,1,0,1,[ "num="])) ]). --- 5,12 ---- ],[ attr("name=", "", 1, 1, 0, ! text(green,112,88,1,0,4,1,1,0,1,55,17,[ "name="])), attr("num=", "", 1, 1, 0, ! text(green,112,72,1,0,4,1,1,0,1,44,17,[ "num="])) ]). *** tangram.sym.orig Wed Jun 27 09:16:38 1990 --- tangram.sym Mon Jul 30 17:58:11 1990 *************** *** 1,18 **** ! state(0,2,0,0,0,16,1,4,1,1,0,1,2,1,0,0,0,7). sym([ ! polygon(yellow,5,[128,96,96,128,128,160,160,128,128,96],0,0,1), ! poly(yellow,2,[96,128,160,128],0,0,1,0,[ ]), ! poly(yellow,2,[112,112,144,112],0,0,1,1,[ ]), ! poly(yellow,2,[128,112,128,160],0,0,1,2,[ ]), ! poly(yellow,2,[112,112,112,128],0,0,1,3,[ ]), ! poly(yellow,2,[128,112,144,128],0,0,1,4,[ ]) ],[ attr("name=", "Tangram", 1, 0, 0, ! text(yellow,128,160,3,2,3,1,1,[ "Tangram"])) ]). --- 1,18 ---- ! state(0,7,0,0,0,16,1,4,1,1,0,0,1,2,1,0,0,0,7). sym([ ! polygon(yellow,5,[128,96,96,128,128,160,160,128,128,96],0,0,1,0), ! poly(yellow,2,[96,128,160,128],0,0,1,0,0,0,[ ]), ! poly(yellow,2,[112,112,144,112],0,0,1,1,0,0,[ ]), ! poly(yellow,2,[128,112,128,160],0,0,1,2,0,0,[ ]), ! poly(yellow,2,[112,112,112,128],0,0,1,3,0,0,[ ]), ! poly(yellow,2,[128,112,144,128],0,0,1,4,0,0,[ ]) ],[ attr("name=", "Tangram", 1, 0, 0, ! text(yellow,128,160,3,2,3,1,1,0,1,65,16,[ "Tangram"])) ]). ---------------------------------> cut here <--------------------------------- -- Bill Cheng // UCLA Computer Science Department // (213) 206-7135 3277 Boelter Hall // Los Angeles, California 90024 // USA william@CS.UCLA.EDU ...!{uunet|ucbvax}!cs.ucla.edu!william -- Dan Heller ------------------------------------------------ O'Reilly && Associates Zyrcom Inc Senior Writer President argv@ora.com argv@zipcode.com