summaryrefslogtreecommitdiff
path: root/fonts/utilities/mf2ps/doc/fig9.ps
blob: f2934f6579516cce95f27e0c5eb7b9eb21b8a631 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
%! Simon font
%%BoundingBox: 0 0 40 52
%%Was: 0 0 40 40
%0 serverdict begin exitserver
/TBuildCharDict 10 dict def
/SimonFont 10 dict def
/fudge 110 def
SimonFont begin
%%
  /FontType 3 def
  /FontMatrix [0.001 0 0 0.001 0 0] def
  /Encoding 256 array def

  0 1 255 {Encoding exch /.notdef put} for

% Character definitions

/Metrics 130 dict def

/CharDefs 130 dict def
  
CharDefs begin

/.notdef
 () def


/The_square
(
 gsave
 initclip
 newpath

 0 0 moveto
 0 1000 lineto
 1000 1000 lineto
 1000 0 lineto
 0 0 lineto

 300 100 moveto
 700 100 lineto
 700 300 lineto
 300 300 lineto
 300 100 lineto

 700 900 moveto
 300 900 lineto
 300 700 lineto
 700 700 lineto
 700 900 lineto

 eoclip

 newpath
 100 100 moveto
 900 100 lineto
 900 900 lineto
 100 900 lineto
 100 100 lineto
 fill
 grestore
) def

end % of CharDefs dictionary

Encoding        120 /The_square put

Metrics
 begin
/The_square 1000 fudge add  def
/.notdef 0 def
  end

   /BuildChar
     { TBuildCharDict begin
 %%
         /char exch def
         /fontdict exch def

        /M {moveto} def
        /L {lineto} def
        /l {rlineto} def
        /C {curveto} def
        /c {rcurveto} def

         /charname fontdict /Encoding get
           char get def
 %%
         /charproc fontdict /CharDefs get
           charname get def
 	  
 	/charwdth fontdict /Metrics get charname get def
 %%
 	gsave
	        1.3       1.3 scale
 		0.2 setflat
 		0.2 setlinewidth
 		charwdth 0
 		0 -180
 		charwdth 1000
 		setcachedevice
                -186 fudge add 0 translate
         	charproc cvx exec
 	grestore
       end
     } def
   /FontBBox [186 fudge sub 180 552 490] def

 end 

 /Simon SimonFont definefont pop

 /Simon findfont 40 scalefont setfont
 0 0 moveto (x) show