|
|
1.1 root 1: static char *PS_head[] = {
2: "%ps_include: begin",
3: "save",
4: "/ed {exch def} def",
5: "{} /showpage ed",
6: "{} /copypage ed",
7: "{} /erasepage ed",
8: "{} /letter ed",
9: "currentdict /findfont known systemdict /findfont known and {",
10: " /findfont systemdict /findfont get def",
11: "} if",
12: "36 dict dup /PS-include-dict-dw ed begin",
13: "/context ed",
14: "count array astore /o-stack ed",
15: "%ps_include: variables begin",
16: 0
17: };
18:
19: static char *PS_setup[] = {
20: "%ps_include: variables end",
21: "{llx lly urx ury} /bbox ed",
22: "{newpath 2 index exch 2 index exch dup 6 index exch",
23: " moveto 3 {lineto} repeat closepath} /boxpath ed",
24: "{dup mul exch dup mul add sqrt} /len ed",
25: "{2 copy gt {exch} if pop} /min ed",
26: "{2 copy lt {exch} if pop} /max ed",
27: "{transform round exch round exch A itransform} /nice ed",
28: "{6 array} /n ed",
29: "n defaultmatrix n currentmatrix n invertmatrix n concatmatrix /A ed",
30: "urx llx sub 0 A dtransform len /Sx ed",
31: "0 ury lly sub A dtransform len /Sy ed",
32: "llx urx add 2 div lly ury add 2 div A transform /Cy ed /Cx ed",
33: "rot dup sin abs /S ed cos abs /C ed",
34: "Sx S mul Sy C mul add /H ed",
35: "Sx C mul Sy S mul add /W ed",
36: "sy H div /Scaley ed",
37: "sx W div /Scalex ed",
38: "s 0 eq {Scalex Scaley min dup /Scalex ed /Scaley ed} if",
39: "sx Scalex W mul sub 0 max ax 0.5 sub mul cx add /cx ed",
40: "sy Scaley H mul sub 0 max ay 0.5 sub mul cy add /cy ed",
41: "urx llx sub 0 A dtransform exch atan rot exch sub /rot ed",
42: "n currentmatrix initgraphics setmatrix",
43: "cx cy translate",
44: "Scalex Scaley scale",
45: "rot rotate",
46: "Cx neg Cy neg translate",
47: "A concat",
48: "bbox boxpath clip newpath",
49: "w 0 ne {gsave bbox boxpath 1 setgray fill grestore} if",
50: "end",
51: "gsave",
52: "%ps_include: inclusion begin",
53: 0
54: };
55:
56: static char *PS_tail[] = {
57: "%ps_include: inclusion end",
58: "grestore",
59: "PS-include-dict-dw begin",
60: "o 0 ne {gsave A defaultmatrix /A ed llx lly nice urx ury nice",
61: " initgraphics 0.1 setlinewidth boxpath stroke grestore} if",
62: "clear o-stack aload pop",
63: "context end restore",
64: "%ps_include: end",
65: 0
66: };
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.