home *** CD-ROM | disk | FTP | other *** search
/ Amiga Elysian Archive / AmigaElysianArchive.iso / prog / c / post17s.lha / postop4.c < prev    next >
Text File  |  1992-03-10  |  38KB  |  1,339 lines

  1. /* PostScript interpreter file "postop4.c" - operators (4)
  2.  * (C) Adrian Aylward 1989, 1992
  3.  * V1.6 First source release
  4.  * V1.7 Fix oparc and oparcn to allow arcs of zero radius
  5.  * V1.7 Fix image and kshow procs not observing stack discipline
  6.  */
  7.  
  8. # include "post.h"
  9.  
  10. /* arc */
  11.  
  12. void oparc(void)
  13. {   struct object *token1;
  14.     struct point centre, beg, end;
  15.     float radaa[3];
  16.     if (opernest < 5) error(errstackunderflow);
  17.     token1 = &operstack[opernest - 5];
  18.     centre.type = 0;
  19.     if      (token1->type == typeint)
  20.         centre.x = token1->value.ival;
  21.     else if (token1->type == typereal)
  22.         centre.x = token1->value.rval;
  23.     else
  24.         error(errtypecheck);
  25.     token1++;
  26.     if      (token1->type == typeint)
  27.         centre.y = token1->value.ival;
  28.     else if (token1->type == typereal)
  29.         centre.y = token1->value.rval;
  30.     else
  31.         error(errtypecheck);
  32.     token1++;
  33.     if      (token1->type == typeint)
  34.         radaa[0] = token1->value.ival;
  35.     else if (token1->type == typereal)
  36.         radaa[0] = token1->value.rval;
  37.     else
  38.         error(errtypecheck);
  39.     token1++;
  40.     if      (token1->type == typeint)
  41.         radaa[1] = token1->value.ival;
  42.     else if (token1->type == typereal)
  43.         radaa[1] = token1->value.rval;
  44.     else
  45.         error(errtypecheck);
  46.     token1++;
  47.     if      (token1->type == typeint)
  48.         radaa[2] = token1->value.ival;
  49.     else if (token1->type == typereal)
  50.         radaa[2] = token1->value.rval;
  51.     else
  52.         error(errtypecheck);
  53.     if (radaa[0] < 0.0) error(errrangecheck);
  54.     radaa[1] *= degtorad;
  55.     radaa[2] *= degtorad;
  56.     arc(1, radaa, ¢re, &beg, &end);
  57.     opernest -= 5;
  58. }
  59.  
  60. /* arcn */
  61.  
  62. void oparcn(void)
  63. {   struct object *token1;
  64.     struct point centre, beg, end;
  65.     float radaa[3];
  66.     if (opernest < 5) error(errstackunderflow);
  67.     token1 = &operstack[opernest - 5];
  68.     centre.type = 0;
  69.     if      (token1->type == typeint)
  70.         centre.x = token1->value.ival;
  71.     else if (token1->type == typereal)
  72.         centre.x = token1->value.rval;
  73.     else
  74.         error(errtypecheck);
  75.     token1++;
  76.     if      (token1->type == typeint)
  77.         centre.y = token1->value.ival;
  78.     else if (token1->type == typereal)
  79.         centre.y = token1->value.rval;
  80.     else
  81.         error(errtypecheck);
  82.     token1++;
  83.     if      (token1->type == typeint)
  84.         radaa[0] = token1->value.ival;
  85.     else if (token1->type == typereal)
  86.         radaa[0] = token1->value.rval;
  87.     else
  88.         error(errtypecheck);
  89.     token1++;
  90.     if      (token1->type == typeint)
  91.         radaa[1] = token1->value.ival;
  92.     else if (token1->type == typereal)
  93.         radaa[1] = token1->value.rval;
  94.     else
  95.         error(errtypecheck);
  96.     token1++;
  97.     if      (token1->type == typeint)
  98.         radaa[2] = token1->value.ival;
  99.     else if (token1->type == typereal)
  100.         radaa[2] = token1->value.rval;
  101.     else
  102.         error(errtypecheck);
  103.     if (radaa[0] < 0.0) error(errrangecheck);
  104.     radaa[1] *= degtorad;
  105.     radaa[2] *= degtorad;
  106.     arc(-1, radaa, ¢re, &beg, &end);
  107.     opernest -= 5;
  108. }
  109.  
  110. /* arcto */
  111.  
  112. void oparcto(void)
  113. {   struct object token, *token1;
  114.     struct point beg, mid, end;
  115.     float radaa[3], angs, angd, radx;
  116.     if (opernest < 5) error(errstackunderflow);
  117.     token1 = &operstack[opernest - 5];
  118.     if (gstate.pathbeg == gstate.pathend) error(errnocurrentpoint);
  119.     beg = patharray[gstate.pathend - 1];
  120.     itransform(&beg, gstate.ctm);
  121.     mid.type = ptline;
  122.     if      (token1->type == typeint)
  123.         mid.x = token1->value.ival;
  124.     else if (token1->type == typereal)
  125.         mid.x = token1->value.rval;
  126.     else
  127.         error(errtypecheck);
  128.     token1++;
  129.     if      (token1->type == typeint)
  130.         mid.y = token1->value.ival;
  131.     else if (token1->type == typereal)
  132.         mid.y = token1->value.rval;
  133.     else
  134.         error(errtypecheck);
  135.     token1++;
  136.     end.type = 0;
  137.     if      (token1->type == typeint)
  138.         end.x = token1->value.ival;
  139.     else if (token1->type == typereal)
  140.         end.x = token1->value.rval;
  141.     else
  142.         error(errtypecheck);
  143.     token1++;
  144.     if      (token1->type == typeint)
  145.         end.y = token1->value.ival;
  146.     else if (token1->type == typereal)
  147.         end.y = token1->value.rval;
  148.     else
  149.         error(errtypecheck);
  150.     token1++;
  151.     if      (token1->type == typeint)
  152.         radaa[0] = token1->value.ival;
  153.     else if (token1->type == typereal)
  154.         radaa[0] = token1->value.rval;
  155.     else
  156.         error(errtypecheck);
  157.     if (radaa[0] <= 0.0) error(errrangecheck);
  158.     radaa[1] = atan2(beg.y - mid.y, beg.x - mid.x);
  159.     radaa[2] = atan2(end.y - mid.y, end.x - mid.x);
  160.     angs = (radaa[2] + radaa[1]) / 2.0;
  161.     angd = (radaa[2] - radaa[1]) / 2.0;
  162.     radx = radaa[0] / sin(angd);
  163.     if (angd < 0) angd += pi;
  164.     if (angd < pi2)
  165.     {   radaa[1] -= pi2;
  166.         radaa[2] += pi2;
  167.     }
  168.     else
  169.     {   radx = -radx;
  170.         radaa[1] += pi2;
  171.         radaa[2] -= pi2;
  172.     }
  173.     mid.x += radx * cos(angs);
  174.     mid.y += radx * sin(angs);
  175.     arc(0, radaa, &mid, &beg, &end);
  176.     token1 -= 4;
  177.     token.type = typereal;
  178.     token.flags = 0;
  179.     token.length = 0;
  180.     token.value.rval = beg.x;
  181.     token1[0] = token;
  182.     token.value.rval = beg.y;
  183.     token1[1] = token;
  184.     token.value.rval = end.x;
  185.     token1[2] = token;
  186.     token.value.rval = end.y;
  187.     token1[3] = token;
  188.     opernest -= 1;
  189. }
  190.  
  191. /* ashow */
  192.  
  193. void opashow(void)
  194. {   struct object *token1, *token2, *token3;
  195.     struct point width[2];
  196.     if (opernest < 3) error(errstackunderflow);
  197.     token3 = &operstack[opernest - 1];
  198.     token2 = token3 - 1;
  199.     token1 = token2 - 1;
  200.     width[0].x = width[0].y = 0.0;
  201.     if      (token1->type == typeint)
  202.         width[1].x = token1->value.ival;
  203.     else if (token1->type == typereal)
  204.         width[1].x = token1->value.rval;
  205.     else
  206.         error(errtypecheck);
  207.     if      (token2->type == typeint)
  208.         width[1].y = token2->value.ival;
  209.     else if (token2->type == typereal)
  210.         width[1].y = token2->value.rval;
  211.     else
  212.         error(errtypecheck);
  213.     dtransform(&width[1], gstate.ctm);
  214.     if (token3->type != typestring) error(errtypecheck);
  215.     if (token3->flags & flagrprot) error(errinvalidaccess);
  216.     show(token3, 3, width, -1, NULL);
  217.     opernest -= 3;
  218. }
  219.  
  220. /* awidthshow */
  221.  
  222. void opawidthshow(void)
  223. {   struct object *token1, *token2, *token3, *token4, *token5, *token6;
  224.     struct point width[2];
  225.     int wchar;
  226.     if (opernest < 6) error(errstackunderflow);
  227.     token6 = &operstack[opernest - 1];
  228.     token5 = token6 - 1;
  229.     token4 = token5 - 1;
  230.     token3 = token4 - 1;
  231.     token2 = token3 - 1;
  232.     token1 = token2 - 1;
  233.     if      (token1->type == typeint)
  234.         width[0].x = token1->value.ival;
  235.     else if (token1->type == typereal)
  236.         width[0].x = token1->value.rval;
  237.     else
  238.         error(errtypecheck);
  239.     if      (token2->type == typeint)
  240.         width[0].y = token2->value.ival;
  241.     else if (token2->type == typereal)
  242.         width[0].y = token2->value.rval;
  243.     else
  244.         error(errtypecheck);
  245.     dtransform(&width[0], gstate.ctm);
  246.     if (token3->type != typeint) error(errtypecheck);
  247.     wchar = token3->value.ival;
  248.     if (wchar < 0 || wchar > 255) error(errrangecheck);
  249.     if      (token4->type == typeint)
  250.         width[1].x = token4->value.ival;
  251.     else if (token4->type == typereal)
  252.         width[1].x = token4->value.rval;
  253.     else
  254.         error(errtypecheck);
  255.     if      (token5->type == typeint)
  256.         width[1].y = token5->value.ival;
  257.     else if (token5->type == typereal)
  258.         width[1].y = token5->value.rval;
  259.     else
  260.         error(errtypecheck);
  261.     dtransform(&width[1], gstate.ctm);
  262.     if (token6->type != typestring) error(errtypecheck);
  263.     if (token6->flags & flagrprot) error(errinvalidaccess);
  264.     show(token6, 3, width, wchar, NULL);
  265.     opernest -= 6;
  266. }
  267.  
  268. /* cachestatus */
  269.  
  270. void opcachestatus(void)
  271. {   struct object token, *token1;
  272.     int status[7], i;
  273.     if (opernest + 7 > operstacksize) error(errstackoverflow);
  274.     token1 = &operstack[opernest];
  275.     cachestatus(status);
  276.     token.type = typeint;
  277.     token.flags = 0;
  278.     token.length = 0;
  279.     for (i = 0; i < 7; i++)
  280.     {   token.value.ival = status[i];
  281.         *token1++ = token;
  282.     }
  283.     opernest += 7;
  284. }
  285.  
  286. /* charpath */
  287.  
  288. void opcharpath(void)
  289. {   struct object *token1, *token2;
  290.     if (opernest < 2) error(errstackunderflow);
  291.     token2 = &operstack[opernest - 1];
  292.     token1 = token2 - 1;
  293.     if (token1->type != typestring) error(errtypecheck);
  294.     if (token1->flags & flagrprot) error(errinvalidaccess);
  295.     if (token2->type != typebool) error(errtypecheck);
  296.     show(token1, token2->value.ival, NULL, -1, NULL);
  297.     opernest -= 2;
  298. }
  299.  
  300. /* clip */
  301.  
  302. void opclip(void)
  303. {   closepath(ptclosei);
  304.     flattenpath();
  305.     clip(-1);
  306. }
  307.  
  308. /* clippath */
  309.  
  310. void opclippath(void)
  311. {   clippath();
  312. }
  313.  
  314. /* closepath */
  315.  
  316. void opclosepath(void)
  317. {   closepath(ptclosex);
  318. }
  319.  
  320. /* colorimage */
  321.  
  322. void opcolorimage(void)
  323. {   struct object *token1, *token2, *token3, *token4,
  324.                   *token5, *token6, *token7, *aptr, procs[4];
  325.     float matrix[6];
  326.     int ncol, multi, width, height, bps;
  327.     int nproc, i;
  328.     if (gstate.cacheflag) error(errundefined);
  329.     if (opernest < 2) error(errstackunderflow);
  330.     token7 = &operstack[opernest - 1];
  331.     token6 = token7 - 1;
  332.     if (token6->type != typebool) error(errtypecheck);
  333.     multi = token6->value.ival;
  334.     if (token7->type != typeint) error(errtypecheck);
  335.     ncol = token7->value.ival;
  336.     if (ncol != 1 && ncol != 3 && ncol != 4) error(errrangecheck);
  337.     nproc = multi ? ncol : 1;
  338.     if (opernest < nproc + 6) error(errstackunderflow);
  339.     token5 = token6 - nproc;
  340.     aptr = token5;
  341.     for (i = 0; i < nproc; i++)
  342.     {   if (aptr->type != typearray && aptr->type != typepacked)
  343.             error(errtypecheck);
  344.         aptr++;
  345.     }
  346.     token4 = token5 - 1;
  347.     token3 = token4 - 1;
  348.     token2 = token3 - 1;
  349.     token1 = token2 - 1;
  350.     if (token1->type != typeint) error(errtypecheck);
  351.     width = token1->value.ival;
  352.     if (width <= 0) error(errrangecheck);
  353.     if (token2->type != typeint) error(errtypecheck);
  354.     height = token2->value.ival;
  355.     if (height <= 0) error(errrangecheck);
  356.     if (token3->type != typeint) error(errtypecheck);
  357.     bps = token3->value.ival;
  358.     if (bps != 1 && bps != 2 && bps != 4 && bps != 8) error(errrangecheck);
  359.     if (token4->type != typearray) error(errtypecheck);
  360.     if (token4->length != 6) error(errrangecheck);
  361.     if (token4->flags & flagrprot) error(errinvalidaccess);
  362.     getmatrix(token4->value.vref, matrix);
  363.     arraycopy(token5, procs, nproc);
  364.     opernest -= nproc + 6;
  365.     image(width, height, bps, matrix, -1, ncol, multi, procs);
  366. }
  367.  
  368. /* copypage */
  369.  
  370. void opcopypage(void)
  371. {   struct object token;
  372.     int num = 1;
  373.     if (istate.flags & intgraph) error(errundefined);
  374.     if (gstate.dev.depth != 0)
  375.     {   if (dictfind(&copies, &token) != -1)
  376.         {   if (token.type != typeint) error(errtypecheck);
  377.             num = token.value.ival;
  378.             if (num < 0) error(errrangecheck);
  379.         }
  380.         copypage(num);
  381.     }
  382. }
  383.  
  384. /* currentband */
  385.  
  386. void opcurrentband(void)
  387. {   struct object token, *token1;
  388.     if (opernest + 3 > operstacksize) error(errstackoverflow);
  389.     token1 = &operstack[opernest];
  390.     token.type = typeint;
  391.     token.flags = 0;
  392.     token.length = 0;
  393.     token.value.ival = page.ybase;
  394.     token1[0] = token;
  395.     token.value.ival = page.ysize;
  396.     token1[1] = token;
  397.     token.value.ival = page.yheight;
  398.     token1[2] = token;
  399.     opernest += 3;
  400. }
  401.  
  402. /* currentfont */
  403.  
  404. void opcurrentfont(void)
  405. {   if (opernest + 1 > operstacksize) error(errstackoverflow);
  406.     operstack[opernest++] = gstate.font;
  407. }
  408.  
  409. /* currentpoint */
  410.  
  411. void opcurrentpoint(void)
  412. {   struct object token, *token1;
  413.     struct point point;
  414.     if (opernest + 2 > operstacksize) error(errstackoverflow);
  415.     token1 = &operstack[opernest];
  416.     if (gstate.pathbeg == gstate.pathend) error(errnocurrentpoint);
  417.     point = patharray[gstate.pathend - 1];
  418.     itransform(&point, gstate.ctm);
  419.     token.type = typereal;
  420.     token.flags = 0;
  421.     token.length = 0;
  422.     token.value.rval = point.x;
  423.     token1[0] = token;
  424.     token.value.rval = point.y;
  425.     token1[1] = token;
  426.     opernest += 2;
  427. }
  428.  
  429. /* curveto */
  430.  
  431. void opcurveto(void)
  432. {   struct object *token1;
  433.     struct point point[3], *ppoint;
  434.     int i;
  435.     if (opernest < 6) error(errstackunderflow);
  436.     token1 = &operstack[opernest - 6];
  437.     if (gstate.pathbeg == gstate.pathend) error(errnocurrentpoint);
  438.     ppoint = &point[0];
  439.     i = 3;
  440.     while (i--)
  441.     {   ppoint->type = ptcurve;
  442.         if      (token1->type == typeint)
  443.             ppoint->x = token1->value.ival;
  444.         else if (token1->type == typereal)
  445.             ppoint->x = token1->value.rval;
  446.         else
  447.             error(errtypecheck);
  448.         token1++;
  449.         if      (token1->type == typeint)
  450.             ppoint->y = token1->value.ival;
  451.         else if (token1->type == typereal)
  452.             ppoint->y = token1->value.rval;
  453.         else
  454.             error(errtypecheck);
  455.         token1++;
  456.         transform(ppoint, gstate.ctm);
  457.         ppoint++;
  458.     }
  459.     checkpathsize(gstate.pathend + 3);
  460.     ppoint = &patharray[gstate.pathend];
  461.     ppoint[0] = point[0];
  462.     ppoint[1] = point[1];
  463.     ppoint[2] = point[2];
  464.     gstate.pathend += 3;
  465.     opernest -= 6;
  466. }
  467.  
  468. /* definefont */
  469.  
  470. void opdefinefont(void)
  471. {   struct object *token1, *token2;
  472.     if (opernest < 2) error(errstackunderflow);
  473.     token2 = &operstack[opernest - 1];
  474.     token1 = token2 - 1;
  475.     if (token2->type != typedict) error(errtypecheck);
  476.     definefont(token1, token2);
  477.     *token1 = *token2;
  478.     opernest -= 1;
  479. }
  480.  
  481. /* eoclip */
  482.  
  483. void opeoclip(void)
  484. {   closepath(ptclosei);
  485.     flattenpath();
  486.     clip(1);
  487. }
  488.  
  489. /* eofill */
  490.  
  491. void opeofill(void)
  492. {   if (istate.flags & intchar)
  493.     {   if      (istate.type < 2)
  494.         {   charpath();
  495.             return;
  496.         }
  497.         else if (istate.type == 2 && !gstate.cacheflag)
  498.         {   gstate.pathend = gstate.pathbeg;
  499.             return;
  500.         }
  501.     }
  502.     closepath(ptclosei);
  503.     flattenpath();
  504.     setupfill();
  505.     fill(gstate.pathbeg, gstate.pathend, 1);
  506.     gstate.pathend = gstate.pathbeg;
  507. }
  508.  
  509. /* erasepage */
  510.  
  511. void operasepage(void)
  512. {   erasepage();
  513. }
  514.  
  515. /* findfont */
  516.  
  517. void opfindfont(void)
  518. {   struct object token, *token1;
  519.     if (opernest < 1) error(errstackunderflow);
  520.     token1 = &operstack[opernest - 1];
  521.     findfont(token1, &token);
  522.     *token1 = token;
  523. }
  524.  
  525. /* fill */
  526.  
  527. void opfill(void)
  528. {   if (istate.flags & intchar)
  529.     {   if      (istate.type < 2)
  530.         {   charpath();
  531.             return;
  532.         }
  533.         else if (istate.type == 2 && !gstate.cacheflag)
  534.         {   gstate.pathend = gstate.pathbeg;
  535.             return;
  536.         }
  537.     }
  538.     closepath(ptclosei);
  539.     flattenpath();
  540.     setupfill();
  541.     fill(gstate.pathbeg, gstate.pathend, -1);
  542.     gstate.pathend = gstate.pathbeg;
  543. }
  544.  
  545. /* flattenpath */
  546.  
  547. void opflattenpath(void)
  548. {   flattenpath();
  549. }
  550.  
  551. /* image */
  552.  
  553. void opimage(void)
  554. {   struct object *token1, *token2, *token3, *token4, *token5, proc;
  555.     float matrix[6];
  556.     int width, height, bps;
  557.     if (gstate.cacheflag) error(errundefined);
  558.     if (opernest < 5) error(errstackunderflow);
  559.     token5 = &operstack[opernest - 1];
  560.     token4 = token5 - 1;
  561.     token3 = token4 - 1;
  562.     token2 = token3 - 1;
  563.     token1 = token2 - 1;
  564.     if (token1->type != typeint) error(errtypecheck);
  565.     width = token1->value.ival;
  566.     if (width <= 0) error(errrangecheck);
  567.     if (token2->type != typeint) error(errtypecheck);
  568.     height = token2->value.ival;
  569.     if (height <= 0) error(errrangecheck);
  570.     if (token3->type != typeint) error(errtypecheck);
  571.     bps = token3->value.ival;
  572.     if (bps != 1 && bps != 2 && bps != 4 && bps != 8) error(errrangecheck);
  573.     if (token4->type != typearray) error(errtypecheck);
  574.     if (token4->length != 6) error(errrangecheck);
  575.     if (token4->flags & flagrprot) error(errinvalidaccess);
  576.     getmatrix(token4->value.vref, matrix);
  577.     if (token5->type != typearray && token5->type != typepacked)
  578.         error(errtypecheck);
  579.     proc = *token5;
  580.     opernest -= 5;
  581.     image(width, height, bps, matrix, -1, 1, 1, &proc);
  582. }
  583.  
  584. /* imagemask */
  585.  
  586. void opimagemask(void)
  587. {   struct object *token1, *token2, *token3, *token4, *token5, proc;
  588.     float matrix[6];
  589.     int width, height, mode;
  590.     if (opernest < 5) error(errstackunderflow);
  591.     token5 = &operstack[opernest - 1];
  592.     token4 = token5 - 1;
  593.     token3 = token4 - 1;
  594.     token2 = token3 - 1;
  595.     token1 = token2 - 1;
  596.     if (token1->type != typeint) error(errtypecheck);
  597.     width = token1->value.ival;
  598.     if (width <= 0) error(errrangecheck);
  599.     if (token2->type != typeint) error(errtypecheck);
  600.     height = token2->value.ival;
  601.     if (height <= 0) error(errrangecheck);
  602.     if (token3->type != typebool) error(errtypecheck);
  603.     mode = token3->value.ival;
  604.     if (token4->type != typearray) error(errtypecheck);
  605.     if (token4->length != 6) error(errrangecheck);
  606.     if (token4->flags & flagrprot) error(errinvalidaccess);
  607.     getmatrix(token4->value.vref, matrix);
  608.     if (token5->type != typearray && token5->type != typepacked)
  609.         error(errtypecheck);
  610.     proc = *token5;
  611.     opernest -= 5;
  612.     image(width, height, 1, matrix, mode, 1, 1, &proc);
  613. }
  614.  
  615. /* initclip */
  616.  
  617. void opinitclip(void)
  618. {   cliplength(0);
  619.     gstate.clipflag = 0;
  620. }
  621.  
  622. /* kshow */
  623.  
  624. void opkshow(void)
  625. {   struct object *token1, *token2, kproc;
  626.     if (opernest < 2) error(errstackunderflow);
  627.     token2 = &operstack[opernest - 1];
  628.     token1 = token2 - 1;
  629.     if (token1->type != typearray && token1->type != typepacked)
  630.         error(errtypecheck);
  631.     if (token2->type != typestring) error(errtypecheck);
  632.     if (token2->flags & flagrprot) error(errinvalidaccess);
  633.     kproc = *token1;
  634.     opernest -= 2;
  635.     show(token2, 3, NULL, -1, &kproc);
  636. }
  637.  
  638. /* lineto */
  639.  
  640. void oplineto(void)
  641. {   struct object *token1, *token2;
  642.     struct point point;
  643.     if (opernest < 2) error(errstackunderflow);
  644.     token2 = &operstack[opernest - 1];
  645.     token1 = token2 - 1;
  646.     point.type = ptline;
  647.     if      (token1->type == typeint)
  648.         point.x = token1->value.ival;
  649.     else if (token1->type == typereal)
  650.         point.x = token1->value.rval;
  651.     else
  652.         error(errtypecheck);
  653.     if      (token2->type == typeint)
  654.         point.y = token2->value.ival;
  655.     else if (token2->type == typereal)
  656.         point.y = token2->value.rval;
  657.     else
  658.         error(errtypecheck);
  659.     transform(&point, gstate.ctm);
  660.     if (gstate.pathbeg == gstate.pathend) error(errnocurrentpoint);
  661.     checkpathsize(gstate.pathend + 1);
  662.     patharray[gstate.pathend++] = point;
  663.     opernest -= 2;
  664. }
  665.  
  666. /* makefont */
  667.  
  668. void opmakefont(void)
  669. {   struct object *token1, *token2;
  670.     float matrix[6];
  671.     if (opernest < 2) error(errstackunderflow);
  672.     token2 = &operstack[opernest - 1];
  673.     token1 = token2 - 1;
  674.     if (token1->type != typedict) error(errtypecheck);
  675.     if (token2->type != typearray) error(errtypecheck);
  676.     if (token2->length != 6) error(errrangecheck);
  677.     if (token2->flags & flagrprot) error(errinvalidaccess);
  678.     getmatrix(token2->value.vref, matrix);
  679.     makefont(token1, matrix);
  680.     opernest -= 1;
  681. }
  682.  
  683. /* moveto */
  684.  
  685. void opmoveto(void)
  686. {   struct object *token1, *token2;
  687.     struct point point;
  688.     if (opernest < 2) error(errstackunderflow);
  689.     token2 = &operstack[opernest - 1];
  690.     token1 = token2 - 1;
  691.     point.type = ptmove;
  692.     if      (token1->type == typeint)
  693.         point.x = token1->value.ival;
  694.     else if (token1->type == typereal)
  695.         point.x = token1->value.rval;
  696.     else
  697.         error(errtypecheck);
  698.     if      (token2->type == typeint)
  699.         point.y = token2->value.ival;
  700.     else if (token2->type == typereal)
  701.         point.y = token2->value.rval;
  702.     else
  703.         error(errtypecheck);
  704.     transform(&point, gstate.ctm);
  705.     closepath(ptclosei);
  706.     if (gstate.pathbeg == gstate.pathend ||
  707.         patharray[gstate.pathend - 1].type != ptmove)
  708.         checkpathsize(gstate.pathend + 1);
  709.     else
  710.         gstate.pathend--;
  711.     patharray[gstate.pathend++] = point;
  712.     opernest -= 2;
  713. }
  714.  
  715. /* newpath */
  716.  
  717. void opnewpath(void)
  718. {   gstate.pathend = gstate.pathbeg;
  719. }
  720.  
  721. /* nulldevice */
  722.  
  723. void opnulldevice(void)
  724. {   nulldevice();
  725. }
  726.  
  727. /* pathbbox */
  728.  
  729. void oppathbbox(void)
  730. {   struct object token, *token1;
  731.     struct point point, *ppoint, box[4], ll, ur;
  732.     int len;
  733.     if (opernest + 4 > operstacksize) error(errstackoverflow);
  734.     token1 = &operstack[opernest];
  735.     len = gstate.pathend - gstate.pathbeg;
  736.     if (len == 0) error(errnocurrentpoint);
  737.     len--;
  738.     ppoint = &patharray[gstate.pathbeg];
  739.     ll = ur = *ppoint++;
  740.     while (len--)
  741.     {   point = *ppoint++;
  742.         if (len != 0 || point.type != ptmove)
  743.         {   if (point.x < ll.x) ll.x = point.x;
  744.             if (point.x > ur.x) ur.x = point.x;
  745.             if (point.y < ll.y) ll.y = point.y;
  746.             if (point.y > ur.y) ur.y = point.y;
  747.         }
  748.     }
  749.     itransform(&ll, gstate.ctm);
  750.     itransform(&ur, gstate.ctm);
  751.     box[0].x = box[3].x = ll.x;
  752.     box[1].x = box[2].x = ur.x;
  753.     box[0].y = box[1].y = ll.y;
  754.     box[2].y = box[3].y = ur.y;
  755.     ll = ur = box[0];
  756.     ppoint = &box[1];
  757.     len = 4;
  758.     while (--len)
  759.     {   point = *ppoint++;
  760.         if (point.x < ll.x) ll.x = point.x;
  761.         if (point.x > ur.x) ur.x = point.x;
  762.         if (point.y < ll.y) ll.y = point.y;
  763.         if (point.y > ur.y) ur.y = point.y;
  764.     }
  765.     token.type = typereal;
  766.     token.flags = 0;
  767.     token.length = 0;
  768.     token.value.rval = ll.x;
  769.     token1[0] = token;
  770.     token.value.rval = ll.y;
  771.     token1[1] = token;
  772.     token.value.rval = ur.x;
  773.     token1[2] = token;
  774.     token.value.rval = ur.y;
  775.     token1[3] = token;
  776.     opernest += 4;
  777. }
  778.  
  779. /* pathforall */
  780.  
  781. void oppathforall(void)
  782. {   struct object token, *token1, *tokenx;
  783.     struct point point, *ppoint;
  784.     int i, p;
  785.     if (currtoken->flags & flagctrl)
  786.     {   tokenx = &execstack[execnest - 2];
  787.         for (;;)
  788.         {   p = gstate.pathbeg + tokenx->value.ival;
  789.             if (p >= gstate.pathend)
  790.             {   execnest -= 6;
  791.                 return;
  792.             }
  793.             ppoint = &patharray[p];
  794.             if (ppoint->type != ptclosei) break;
  795.             tokenx->value.ival++;
  796.         }
  797.         if      (ppoint->type == ptmove)
  798.         {   i = 1;
  799.             tokenx->value.ival += 1;
  800.             tokenx -= 4;
  801.         }
  802.         else if (ppoint->type == ptline)
  803.         {   i = 1;
  804.             tokenx->value.ival += 1;
  805.             tokenx -= 3;
  806.         }
  807.         else if (ppoint->type == ptcurve)
  808.         {   i = 3;
  809.             tokenx->value.ival += 3;
  810.             tokenx -= 2;
  811.         }
  812.         else
  813.         {   i = 0;
  814.             tokenx->value.ival += 1;
  815.             tokenx -= 1;
  816.         }
  817.         if (opernest + i + i > operstacksize) error(errstackoverflow);
  818.         token1 = &operstack[opernest];
  819.         token.type = typereal;
  820.         token.flags = 0;
  821.         token.length = 0;
  822.         while (i--)
  823.         {   point = *ppoint++;
  824.             itransform(&point, gstate.ctm);
  825.             token.value.rval = point.x;
  826.             token1[0] = token;
  827.             token.value.rval = point.y;
  828.             token1[1] = token;
  829.             token1 += 2;
  830.             opernest += 2;
  831.         }
  832.         execstack[execnest++] = *tokenx;
  833.     }
  834.     else
  835.     {   if (opernest < 4) error(errstackunderflow);
  836.         token1 = &operstack[opernest];
  837.         i = 4;
  838.         while (i--)
  839.         {   token1--;
  840.             if (token1->type != typearray && token1->type != typepacked)
  841.                 error(errtypecheck);
  842.         }
  843.         if (execnest + 7 > execstacksize) error(errexecstackoverflow);
  844.         tokenx = &execstack[execnest];
  845.         tokenx[0] = *token1++;
  846.         tokenx[1] = *token1++;
  847.         tokenx[2] = *token1++;
  848.         tokenx[3] = *token1;
  849.         token.type = typeint;
  850.         token.flags = 0;
  851.         token.length = 0;
  852.         token.value.ival = 0;
  853.         tokenx[4] = token;
  854.         token = *currtoken;
  855.         token.flags &= ~flagexec;
  856.         token.flags |= flagctrl | flagloop;
  857.         token.length = 6;
  858.         tokenx[5] = token;
  859.         execnest += 6;
  860.         opernest -= 4;
  861.     }
  862. }
  863.  
  864. /* rcurveto */
  865.  
  866. void oprcurveto(void)
  867. {   struct object *token1;
  868.     struct point point[3], *ppoint;
  869.     float x, y;
  870.     int i;
  871.     if (opernest < 6) error(errstackunderflow);
  872.     token1 = &operstack[opernest - 6];
  873.     if (gstate.pathbeg == gstate.pathend) error(errnocurrentpoint);
  874.     ppoint = &patharray[gstate.pathend - 1];
  875.     x = ppoint->x;
  876.     y = ppoint->y;
  877.     ppoint = &point[0];
  878.     i = 3;
  879.     while (i--)
  880.     {   ppoint->type = ptcurve;
  881.         if      (token1->type == typeint)
  882.             ppoint->x = token1->value.ival;
  883.         else if (token1->type == typereal)
  884.             ppoint->x = token1->value.rval;
  885.         else
  886.             error(errtypecheck);
  887.         token1++;
  888.         if      (token1->type == typeint)
  889.             ppoint->y = token1->value.ival;
  890.         else if (token1->type == typereal)
  891.             ppoint->y = token1->value.rval;
  892.         else
  893.             error(errtypecheck);
  894.         dtransform(ppoint, gstate.ctm);
  895.         ppoint->x += x;
  896.         ppoint->y += y;
  897.         token1++;
  898.         ppoint++;
  899.     }
  900.     checkpathsize(gstate.pathend + 3);
  901.     ppoint = &patharray[gstate.pathend];
  902.     ppoint[0] = point[0];
  903.     ppoint[1] = point[1];
  904.     ppoint[2] = point[2];
  905.     gstate.pathend += 3;
  906.     opernest -= 6;
  907. }
  908.  
  909. /* reversepath */
  910.  
  911. void opreversepath(void)
  912. {   struct point point, *ppoint1, *ppoint2, *ppoint3;
  913.     int len;
  914.     len = gstate.pathend - gstate.pathbeg;
  915.     ppoint1 = &patharray[gstate.pathbeg];
  916.  
  917.     /* While we have any subpaths left ... */
  918.  
  919.     while (len != 0)
  920.     {   ppoint2 = ppoint1;
  921.  
  922.         /* Scan to the end of the subpath.  If we get to a close then reset
  923.          * its coordinates to the end of the path.  For other cases we copy
  924.          * the type to the previous point - as the type is at the END of
  925.          * the line or curve. */
  926.  
  927.         for (;;)
  928.         {   len--;
  929.             if (ppoint1->type == ptclosex || ppoint1->type == ptclosei)
  930.             {   ppoint1->x = (ppoint1 - 1)->x;
  931.                 ppoint1->y = (ppoint1 - 1)->y;
  932.                 break;
  933.             }
  934.             if (ppoint1 != ppoint2)
  935.                 (ppoint1 - 1)->type = ppoint1->type;
  936.             ppoint1++;
  937.             if (len == 0)
  938.                 break;
  939.         }
  940.  
  941.         /* Now reverse the contents of the subpath.  Make the (new) first
  942.          * element a move. */
  943.  
  944.         ppoint3 = ppoint1 - 1;
  945.         ppoint3->type = ptmove;
  946.         while (ppoint2 < ppoint3)
  947.         {   point = *ppoint2;
  948.             *ppoint2 = *ppoint3;
  949.             *ppoint3 = point;
  950.             ppoint2++;
  951.             ppoint3--;
  952.         }
  953.  
  954.         /* Continue with next subpath. */
  955.  
  956.         ppoint1++;
  957.     }
  958. }
  959.  
  960. /* rlineto */
  961.  
  962. void oprlineto(void)
  963. {   struct object *token1, *token2;
  964.     struct point point, *ppoint;
  965.     if (opernest < 2) error(errstackunderflow);
  966.     token2 = &operstack[opernest - 1];
  967.     token1 = token2 - 1;
  968.     point.type = ptline;
  969.     if      (token1->type == typeint)
  970.         point.x = token1->value.ival;
  971.     else if (token1->type == typereal)
  972.         point.x = token1->value.rval;
  973.     else
  974.         error(errtypecheck);
  975.     if      (token2->type == typeint)
  976.         point.y = token2->value.ival;
  977.     else if (token2->type == typereal)
  978.         point.y = token2->value.rval;
  979.     else
  980.         error(errtypecheck);
  981.     dtransform(&point, gstate.ctm);
  982.     if (gstate.pathbeg == gstate.pathend) error(errnocurrentpoint);
  983.     ppoint = &patharray[gstate.pathend - 1];
  984.     point.x += ppoint->x;
  985.     point.y += ppoint->y;
  986.     checkpathsize(gstate.pathend + 1);
  987.     patharray[gstate.pathend++] = point;
  988.     opernest -= 2;
  989. }
  990.  
  991. /* rmoveto */
  992.  
  993. void oprmoveto(void)
  994. {   struct object *token1, *token2;
  995.     struct point point, *ppoint;
  996.     if (opernest < 2) error(errstackunderflow);
  997.     token2 = &operstack[opernest - 1];
  998.     token1 = token2 - 1;
  999.     point.type = ptmove;
  1000.     if      (token1->type == typeint)
  1001.         point.x = token1->value.ival;
  1002.     else if (token1->type == typereal)
  1003.         point.x = token1->value.rval;
  1004.     else
  1005.         error(errtypecheck);
  1006.     if      (token2->type == typeint)
  1007.         point.y = token2->value.ival;
  1008.     else if (token2->type == typereal)
  1009.         point.y = token2->value.rval;
  1010.     else
  1011.         error(errtypecheck);
  1012.     dtransform(&point, gstate.ctm);
  1013.     if (gstate.pathbeg == gstate.pathend) error(errnocurrentpoint);
  1014.     ppoint = &patharray[gstate.pathend - 1];
  1015.     point.x += ppoint->x;
  1016.     point.y += ppoint->y;
  1017.     closepath(ptclosei);
  1018.     if (patharray[gstate.pathend - 1].type != ptmove)
  1019.         checkpathsize(gstate.pathend + 1);
  1020.     else
  1021.         gstate.pathend--;
  1022.     patharray[gstate.pathend++] = point;
  1023.     opernest -= 2;
  1024. }
  1025.  
  1026. /* scalefont */
  1027.  
  1028. void opscalefont(void)
  1029. {   struct object *token1, *token2;
  1030.     float matrix[6], scale;
  1031.     if (opernest < 2) error(errstackunderflow);
  1032.     token2 = &operstack[opernest - 1];
  1033.     token1 = token2 - 1;
  1034.     if (token1->type != typedict) error(errtypecheck);
  1035.     if      (token2->type == typeint)
  1036.         scale = token2->value.ival;
  1037.     else if (token2->type == typereal)
  1038.         scale = token2->value.rval;
  1039.     else
  1040.         error(errtypecheck);
  1041.     matrix[1] = matrix[2] = matrix[4] = matrix[5] = 0.0;
  1042.     matrix[0] = matrix[3] = scale;
  1043.     makefont(token1, matrix);
  1044.     opernest -= 1;
  1045. }
  1046.  
  1047. /* setband */
  1048.  
  1049. void opsetband(void)
  1050. {   struct object *token1;
  1051.     int base;
  1052.     if (opernest < 1) error(errstackunderflow);
  1053.     token1 = &operstack[opernest - 1];
  1054.     if (token1->type != typeint) error(errtypecheck);
  1055.     base = token1->value.ival;
  1056.     if (base < 0 || base >= page.yheight)
  1057.         error(errrangecheck);
  1058.     page.ybase = base;
  1059.     setdevice(&page);
  1060.     opernest--;
  1061. }
  1062.  
  1063. /* setcachedevice */
  1064.  
  1065. void opsetcachedevice(void)
  1066. {   struct object *token1;
  1067.     struct point point, width[5], ll, ur;
  1068.     int i;
  1069.     if (opernest < 6) error(errstackunderflow);
  1070.     token1 = &operstack[opernest - 6];
  1071.     for (i = 0; i < 3; i++)
  1072.     {   if      (token1->type == typeint)
  1073.             width[i].x = token1->value.ival;
  1074.         else if (token1->type == typereal)
  1075.             width[i].x = token1->value.rval;
  1076.         else
  1077.             error(errtypecheck);
  1078.         token1++;
  1079.         if      (token1->type == typeint)
  1080.             width[i].y = token1->value.ival;
  1081.         else if (token1->type == typereal)
  1082.             width[i].y = token1->value.rval;
  1083.         else
  1084.             error(errtypecheck);
  1085.         token1++;
  1086.     }
  1087.     width[3].x = width[1].x;
  1088.     width[3].y = width[2].y;
  1089.     width[4].x = width[2].x;
  1090.     width[4].y = width[1].y;
  1091.     for (i = 0; i < 5; i++)
  1092.         dtransform(&width[i], gstate.ctm);
  1093.     setcharwidth(&width[0]);
  1094.     if (istate.type >= 2)
  1095.     {   ll = ur = width[1];
  1096.         for (i = 2; i < 5; i++)
  1097.         {   point = width[i];
  1098.             if (point.x < ll.x) ll.x = point.x;
  1099.             if (point.x > ur.x) ur.x = point.x;
  1100.             if (point.y < ll.y) ll.y = point.y;
  1101.             if (point.y > ur.y) ur.y = point.y;
  1102.         }
  1103.         setcachedevice(&ll, &ur, 3);
  1104.     }
  1105.     opernest -= 6;
  1106. }
  1107.  
  1108. /* setcachelimit */
  1109.  
  1110. void opsetcachelimit(void)
  1111. {   struct object *token1;
  1112.     int limit;
  1113.     if (opernest < 1) error(errstackunderflow);
  1114.     token1 = &operstack[opernest - 1];
  1115.     if      (token1->type == typeint)
  1116.         limit = token1->value.ival;
  1117.     else if (token1->type == typereal)
  1118.         limit = itrunc(token1->value.rval);
  1119.     else
  1120.         error(errtypecheck);
  1121.     if (limit > fclen)
  1122.         fclimit = fclen;
  1123.     else
  1124.         fclimit = limit;
  1125.     opernest -= 1;
  1126. }
  1127.  
  1128. /* setcharwidth */
  1129.  
  1130. void opsetcharwidth(void)
  1131. {   struct object *token1, *token2;
  1132.     struct point width;
  1133.     if (opernest < 2) error(errstackunderflow);
  1134.     token2 = &operstack[opernest - 1];
  1135.     token1 = token2 - 1;
  1136.     if      (token1->type == typeint)
  1137.         width.x = token1->value.ival;
  1138.     else if (token1->type == typereal)
  1139.         width.x = token1->value.rval;
  1140.     else
  1141.         error(errtypecheck);
  1142.     token1++;
  1143.     if      (token1->type == typeint)
  1144.         width.y = token1->value.ival;
  1145.     else if (token1->type == typereal)
  1146.         width.y = token1->value.rval;
  1147.     else
  1148.         error(errtypecheck);
  1149.     dtransform(&width, gstate.ctm);
  1150.     setcharwidth(&width);
  1151.     opernest -= 2;
  1152. }
  1153.  
  1154. /* setfont */
  1155.  
  1156. void opsetfont(void)
  1157. {   struct object *token1;
  1158.     if (opernest < 1) error(errstackunderflow);
  1159.     token1 = &operstack[opernest - 1];
  1160.     if (token1->type != typedict) error(errtypecheck);
  1161.     setfont(token1);
  1162.     opernest -= 1;
  1163. }
  1164.  
  1165. /* show */
  1166.  
  1167. void opshow(void)
  1168. {   struct object *token1;
  1169.     if (opernest < 1) error(errstackunderflow);
  1170.     token1 = &operstack[opernest - 1];
  1171.     if (token1->type != typestring) error(errtypecheck);
  1172.     if (token1->flags & flagrprot) error(errinvalidaccess);
  1173.     show(token1, 3, NULL, -1, NULL);
  1174.     opernest -= 1;
  1175. }
  1176.  
  1177. /* showpage */
  1178.  
  1179. void opshowpage(void)
  1180. {   struct object token;
  1181.     int num = 1;
  1182.     if (istate.flags & intgraph) error(errundefined);
  1183.     if (gstate.dev.depth != 0)
  1184.     {   if (dictfind(&copies, &token) != -1)
  1185.         {   if (token.type != typeint) error(errtypecheck);
  1186.             num = token.value.ival;
  1187.             if (num < 0) error(errrangecheck);
  1188.         }
  1189.         copypage(num);
  1190.         erasepage();
  1191.     }
  1192.     initgraphics();
  1193. }
  1194.  
  1195. /* stringwidth */
  1196.  
  1197. void opstringwidth(void)
  1198. {   struct object token, *token1;
  1199.     struct point width;
  1200.     if (opernest < 1) error(errstackunderflow);
  1201.     if (opernest + 1 > operstacksize) error(errstackoverflow);
  1202.     token1 = &operstack[opernest - 1];
  1203.     if (token1->type != typestring) error(errtypecheck);
  1204.     if (token1->flags & flagrprot) error(errinvalidaccess);
  1205.     show(token1, 2, &width, -1, NULL);
  1206.     idtransform(&width, gstate.ctm);
  1207.     token.type = typereal;
  1208.     token.flags = 0;
  1209.     token.length = 0;
  1210.     token.value.rval = width.x;
  1211.     token1[0] = token;
  1212.     token.value.rval = width.y;
  1213.     token1[1] = token;
  1214.     opernest += 1;
  1215. }
  1216.  
  1217. /* stroke */
  1218.  
  1219. void opstroke(void)
  1220. {   if (istate.flags & intchar)
  1221.     {   if      (istate.type == 0)
  1222.         {   charpath();
  1223.             return;
  1224.         }
  1225.         else if (istate.type == 1)
  1226.         {   flattenpath();
  1227.             strokepath(0);
  1228.             charpath();
  1229.             return;
  1230.         }
  1231.         else if (istate.type == 2 && !gstate.cacheflag)
  1232.         {   gstate.pathend = gstate.pathbeg;
  1233.             return;
  1234.         }
  1235.     }
  1236.     flattenpath();
  1237.     setupfill();
  1238.     strokepath(1);
  1239.     gstate.pathend = gstate.pathbeg;
  1240. }
  1241.  
  1242. /* strokepath */
  1243.  
  1244. void opstrokepath(void)
  1245. {   flattenpath();
  1246.     strokepath(0);
  1247. }
  1248.  
  1249. /* widthshow */
  1250.  
  1251. void opwidthshow(void)
  1252. {   struct object *token1, *token2, *token3, *token4;
  1253.     struct point width[2];
  1254.     int wchar;
  1255.     if (opernest < 4) error(errstackunderflow);
  1256.     token4 = &operstack[opernest - 1];
  1257.     token3 = token4 - 1;
  1258.     token2 = token3 - 1;
  1259.     token1 = token2 - 1;
  1260.     if      (token1->type == typeint)
  1261.         width[0].x = token1->value.ival;
  1262.     else if (token1->type == typereal)
  1263.         width[0].x = token1->value.rval;
  1264.     else
  1265.         error(errtypecheck);
  1266.     if      (token2->type == typeint)
  1267.         width[0].y = token2->value.ival;
  1268.     else if (token2->type == typereal)
  1269.         width[0].y = token2->value.rval;
  1270.     else
  1271.         error(errtypecheck);
  1272.     dtransform(&width[0], gstate.ctm);
  1273.     if (token3->type != typeint) error(errtypecheck);
  1274.     wchar = token3->value.ival;
  1275.     if (wchar < 0 || wchar > 255) error(errrangecheck);
  1276.     width[1].x = width[1].y = 0.0;
  1277.     if (token4->type != typestring) error(errtypecheck);
  1278.     if (token4->flags & flagrprot) error(errinvalidaccess);
  1279.     show(token4, 3, width, wchar, NULL);
  1280.     opernest -= 4;
  1281. }
  1282.  
  1283. /* Initialise the operators (4) */
  1284.  
  1285. void initop4(void)
  1286. {   systemop(oparc,              "arc");
  1287.     systemop(oparcn,             "arcn");
  1288.     systemop(oparcto,            "arcto");
  1289.     systemop(opashow,            "ashow");
  1290.     systemop(opawidthshow,       "awidthshow");
  1291.     systemop(opcachestatus,      "cachestatus");
  1292.     systemop(opcharpath,         "charpath");
  1293.     systemop(opclip,             "clip");
  1294.     systemop(opclippath,         "clippath");
  1295.     systemop(opclosepath,        "closepath");
  1296.     systemop(opcolorimage,       "colorimage");
  1297.     systemop(opcopypage,         "copypage");
  1298.     systemop(opcurrentband,      "currentband");
  1299.     systemop(opcurrentfont,      "currentfont");
  1300.     systemop(opcurrentpoint,     "currentpoint");
  1301.     systemop(opcurveto,          "curveto");
  1302.     systemop(opdefinefont,       "definefont");
  1303.     systemop(opeoclip,           "eoclip");
  1304.     systemop(opeofill,           "eofill");
  1305.     systemop(operasepage,        "erasepage");
  1306.     systemop(opfill,             "fill");
  1307.     systemop(opfindfont,         "findfont");
  1308.     systemop(opflattenpath,      "flattenpath");
  1309.     systemop(opimage,            "image");
  1310.     systemop(opimagemask,        "imagemask");
  1311.     systemop(opinitclip,         "initclip");
  1312.     systemop(opkshow,            "kshow");
  1313.     systemop(oplineto,           "lineto");
  1314.     systemop(opmakefont,         "makefont");
  1315.     systemop(opmoveto,           "moveto");
  1316.     systemop(opnewpath,          "newpath");
  1317.     systemop(opnulldevice,       "nulldevice");
  1318.     systemop(oppathbbox,         "pathbbox");
  1319.     systemop(oppathforall,       "pathforall");
  1320.     systemop(oprcurveto,         "rcurveto");
  1321.     systemop(opreversepath,      "reversepath");
  1322.     systemop(oprlineto,          "rlineto");
  1323.     systemop(oprmoveto,          "rmoveto");
  1324.     systemop(opscalefont,        "scalefont");
  1325.     systemop(opsetband,          "setband");
  1326.     systemop(opsetcachedevice,   "setcachedevice");
  1327.     systemop(opsetcachelimit,    "setcachelimit");
  1328.     systemop(opsetcharwidth,     "setcharwidth");
  1329.     systemop(opsetfont,          "setfont");
  1330.     systemop(opshow,             "show");
  1331.     systemop(opshowpage,         "showpage");
  1332.     systemop(opstringwidth,      "stringwidth");
  1333.     systemop(opstroke,           "stroke");
  1334.     systemop(opstrokepath,       "strokepath");
  1335.     systemop(opwidthshow,        "widthshow");
  1336. }
  1337.  
  1338. /* End of file "postop4.c" */
  1339.