home *** CD-ROM | disk | FTP | other *** search
/ Otherware / Otherware_1_SB_Development.iso / mac / util / print / draw2ps.pit / PostScript from Mac.pit / PostScript from Mac.rsrc / STR#_1101.txt < prev    next >
Encoding:
Text File  |  1987-05-20  |  569 b   |  19 lines

  1. /ar {newpath gsave translate /dy xd /dx xd 1 setlinecap
  2.  
  3.   /ds dx dup mul dy dup mul add sqrt def /co dx ds div def /si dy ds div def
  4.  
  5.   /ay currentlinewidth 5 mul def /ax ay 2 mul def
  6.  
  7.   dup 2 and 0 eq {0 0} {0 0 arrow} ifelse moveto /co co neg def /si si neg def
  8.  
  9.   1 and 0 eq {dx dy} {dx dy arrow} ifelse lineto dostroke grestore} def
  10.  
  11. /arrow {/y xd /x xd gsave newpath x y moveto
  12.  
  13.   ax co mul ay si mul sub ax si mul ay co mul add rlineto
  14.  
  15.   ay si mul dup add ay co mul dup add neg rlineto
  16.  
  17.   closepath 0 setgray fill grestore ax co mul x add ax si mul y add} def
  18.  
  19.