1
% tipasym1.mf: TIPA phonetic symbols (1)
2
% Copyright 1996-2003 FUKUI Rei
4
% This program may be distributed and/or modified under the
5
% conditions of the LaTeX Project Public License, either version 1.2
6
% of this license or (at your option) any later version.
7
% The latest version of this license is in
8
% http://www.latex-project.org/lppl.txt
9
% and version 1.2 or later is part of all distributions of LaTeX
10
% version 1999/12/01 or later.
12
% This program consists of all files listed in Manifest.txt.
14
% Version 1.2 2003/01/01
16
% This font is based on:
17
% Computer Modern font series by D. E. Knuth and
18
% TSIPA by KOBAYASHI Hajime, FUKUI Rei and SHIRAKAWA Shun.
22
beginchar("0",10u#,x_height#,0);
23
italcorr x_height#*slant-serif_fit#+.5stem#-1.5u#;
24
if serifs: adjust_fit(serif_fit#+stem_shift#,serif_fit#-stem_shift#);
25
else: adjust_fit(serif_fit#+stem_shift#+.5u#,serif_fit#-stem_shift#+.5u#); fi
26
numeric light_vair; light_vair=vair if hefty: -vround 2vair_corr fi;
27
if light_vair<fine.breadth: light_vair:=fine.breadth; fi
28
pickup tiny.nib; pos1(stem,0); pos2(stem,0);
29
pos3(stem,0); pos4(stem',0);
30
lft x1l=hround(side_gap-.5stem); x1=x2; x3=w-x1; x3r=x4r;
31
if serifs: top y1=h if Times_Compat: else: +min(oo,serif_drop) fi;
32
bot y4=-min(oo,serif_drop);
33
else: top y1=h; bot y4=0; fi
34
pos0(stem,0); pos0'(stem',0); x0=x3; x0'=x4; y0=y0';
35
penpos2'(stem-fine,-180); z2'=z2; y3=y1; y2=.5bar_height;
36
penpos5(max(eps,light_vair-fine),-90); penpos6(thin_join-fine,0);
38
filldraw stroke z1e--z2e; % left stem
39
filldraw stroke z3e..z0e--z0'e..z4e; % right stem
40
pickup fine.nib; bot y5r=-oo; x5l=.5w-.25u; lft x6l=tiny.lft x0l;
41
(x,y5r)=whatever[z5l,z6l]; x5r:=max(x,.5[x5,x2'r]);
42
filldraw stroke {{interim superness:=hein_super;
43
pulled_arc.e(2',5)}} & z5e{right}...{up}z6e; % arc
44
if serifs: numeric upper_serif_drop, lower_serif_drop;
45
if Times_Compat: upper_serif_drop=0; lower_serif_drop=serif_drop;
46
else: upper_serif_drop=serif_drop; lower_serif_drop=min(oo,serif_drop); fi
47
sloped_serif.l(1,2,a,1/3,jut,upper_serif_drop); % upper left serif
48
sloped_serif.l(3,0,b,1/3,jut,upper_serif_drop); % upper right serif
49
sloped_serif.r(4,0',c,1/3,jut,lower_serif_drop); fi % lower right serif
50
hbar(7,8,lft x1l - hround(1.5u),rt x3r + hround(1.5u),.58x_height);
51
penlabels(1,2,3,4,5); labels(6); endchar;
54
numeric dot_diam#; dot_diam#=max(dot_size#,cap_curve#);
55
beginchar("1",CT(5u#,5.56u#),min(asc_height#,10/7x_height#+.5dot_diam#),0);
56
define_whole_blacker_pixels(dot_diam);
57
italcorr h#*slant-serif_fit# + .5dot_diam# -2u#;
58
if serifs: adjust_fit(serif_fit#+stem_shift#+.3u# if monospace:+.25u#fi,
59
serif_fit#-stem_shift#+.3u#);
60
else: adjust_fit(serif_fit#+stem_shift#+.8u# if monospace:+.25u#fi,
61
serif_fit#-stem_shift#+.8u#); fi
62
pickup tiny.nib; pos1(stem',0); pos2(stem',0);
63
if odd(w-stem'): change_width; fi
64
lft x1l=hround(.5w-.5stem'); x1=x2;
65
top y1=x_height if serifs: +min(oo,serif_drop) fi; bot y2=0;
66
filldraw stroke z1e--z2e; % stem
67
pos3(dot_diam,0); pos4(dot_diam,90);
68
if serifs: x3r=max(x1r,hround(x1+.5dot_diam-.2jut)-.5tiny)
71
if bot y4l-top y1<slab: y4l:=min(y4r-eps,y1+tiny+slab); fi
72
x3=x4; y3=.5[y4l,y4r]; dot(3,4); % dot
73
if serifs: sloped_serif.l(1,2,a,1/3,.95jut,serif_drop); % upper serif
74
dish_serif(2,1,b,1/3,jut,c,1/3,.9jut); fi % lower serif
75
hbar(5,6,lft x1l - hround(1.8u),rt x1r + hround(1.8u),.58x_height);
76
penlabels(1,2,3,4); endchar;
79
beginchar("2",CT(if serifs: 9.5u# else:9u# fi,10u#),x_height#,0);
80
adjust_fit(serif_fit# if monospace:+\\.5u#,.5u#+ else:,fi\\ serif_fit#);
81
numeric left_stem,right_stem,outer_jut,alpha;
82
right_stem=fudged.stem-stem_corr;
83
left_stem=min(fudged.hair if hefty:-2stem_corr fi,right_stem);
85
x1l=w-x4r=l+letter_fit+outer_jut+.25u; y1=y4=0;
86
x2-x1=x4-x3; x2r+apex_corr=x3r; y2=y3=h+apex_oo;
87
alpha=diag_ratio(2,left_stem,y2-y1,x4r-x1l-apex_corr);
88
penpos1(alpha*left_stem,0); penpos2(alpha*left_stem,0);
89
penpos3(alpha*right_stem,0); penpos4(alpha*right_stem,0);
90
z0=whatever[z1r,z2r]=whatever[z3l,z4l];
91
if y0<h-notch_cut: y0:=h-notch_cut;
92
fill z0+.5right{down}...{z4-z3}diag_end(3l,4l,1,1,4r,3r)
93
--diag_end(4r,3r,1,1,2l,1l)--diag_end(2l,1l,1,1,1r,2r){z2-z1}
94
...{up}z0+.5left--cycle; % left and right diagonals
95
else: fill z0--diag_end(0,4l,1,1,4r,3r)--diag_end(4r,3r,1,1,2l,1l)
96
--diag_end(2l,1l,1,1,1r,0)--cycle; fi % left and right diagonals
97
if serifs: numeric inner_jut; pickup tiny.nib;
98
prime_points_inside(1,2); prime_points_inside(4,3);
99
if rt x1'r+jut+.5u+1<=lft x4'l-jut: inner_jut=jut;
100
else: rt x1'r+inner_jut+.5u+1=lft x4'l-inner_jut; fi
101
dish_serif(1',2,a,1/3,outer_jut,b,1/2,inner_jut)(dark); % left serif
102
dish_serif(4',3,c,.6,inner_jut,d,1/2,outer_jut); fi % right serif
103
penlabels(0,1,2,3,4); endchar;
105
cmchar "Reversed epsilon";
106
beginchar("3",CT(8.5u#,8.88u#),x_height#,0);
107
italcorr x_height#*slant-.5u#;
109
epsilon_stroke(true,3.5u);
110
if serifs: numeric bulb_diam;
111
bulb_diam=max(flare-.75(cap_stem-stem),stem);
112
pos0(bulb_diam,180); pos1(hair,180);
113
lft x0r=hround u; y0=min(.9h-.5bulb_diam,.75h+.5bulb_diam);
114
bulb(2,1,0); % upper bulb
115
pos9(bot_thickness,angle(-2u,-h));
116
else: pos1(.47[vair',flare],100); lft x1r = 1u; top y1r = .9h;
117
filldraw stroke term.e(2,1,left,1,4);
118
pos9(.6[vair',flare],-100); fi
119
lft x9r=hround .75u; top y9=vround .25h-o;
120
y9r:=good.y y9r-eps; x9l:=good.x x9l;
121
filldraw stroke term.e(8,9,left,1,4); % lower terminal
122
penlabels(0,1,2,3,4,5,6,7,8,9,10); endchar;
125
beginchar("4",10u#,x_height#,desc_depth#);
126
italcorr x_height#*slant+serif_fit#;
127
adjust_fit(serif_fit#-stem_shift#,serif_fit#+stem_shift#);
128
pickup tiny.nib; pos1(stem,0); pos2(stem,0);
129
pos1'(stem',0); pos2'(stem',0); pos3(stem,0);
130
rt x1r=hround(w-(2.5u-.5stem)); x1r=x1'r=x2r=x2'r; x3=w-x1;
131
bot y1=-d-min(oo,serif_drop); top y2=h; y1=y1'; y2=y2';
132
filldraw stroke z1'e--z2'e; % left stem
133
turned_h_stroke(2,a,3,4); % arch and right stem
134
if serifs: sloped_serif.r(1',2',b,1/3,jut,serif_drop); % upper left serif
135
numeric inner_jut; pickup tiny.nib;
136
if lft x2l-jut-.5u-1>=rt x4r+jut: inner_jut=jut;
137
else: lft x2l-jut-.5u-1=rt x4r+inner_jut; fi
138
dish_serif(2,1,c,1/3,jut,d,1/3,jut); % lower left serif
139
dish_serif(4,3,e,1/3,inner_jut,f,1/3,jut); fi % lower right serif
140
penlabels(1,2,3,4); endchar;
143
beginchar("5",CT(9u#,8.88u#),x_height#,0);
144
if Times_Compat: bh#:=.6x_height#;
145
else: bh#:=min(bar_height#,1.14x_height#-bar_height#); fi
147
italcorr .8x_height#*slant+.5stem#-1u#;
148
adjust_fit(serif_fit# if serifs: if hair#+.5stem#>1.5u#:-.25u# fi\\fi,0);
149
pickup fine.nib; bot y3r=-vround 1.5oo;
150
if serifs: pos1(flare,0); pos2(hair,0); pos3(vair,-90);
151
rt x1r=hround(w-max(u,if Times_Compat:1.5u else:2.1u fi-.5flare));
152
x3=.5w if Times_Compat:+.25u else:+.5u fi;
153
y1=h-(min(bh+.5flare+2vair+2,.9[bh,h]-.5flare));
155
else: pos1(5/7[vair,flare],-85); x1l=good.x(w-1.5u); x1r:=good.x x1r;
156
pos3(1/8[vair,thin_join],-90);
157
x3=.5w+.2u; bot y1r=vround(.18[bot y3r,h-bh]);
158
filldraw stroke term.e(3,1,right,.9,4); fi % terminal
159
pos4(stem,180); lft x4r=hround(side_gap-.5stem);
160
y4=h-if Times_Compat: .5 else: 1/3 fi[bh,h];
161
pos5(stem,180); x5=x4;
162
y5=h-if Times_Compat: max(.45bh,2vair) else: max(.55bh,2vair) fi;
163
filldraw stroke super_arc.e(3,4)&z4e..z5e; % arc and stem
164
pos6(.3[thin_join,vair],-90); x6=x4; top y6=h-if Times_Compat: 1.1 fi bh;
165
pos7(hround(curve-2stem_corr),if Times_Compat: 20 else: 0 fi);
166
rt x7r=hround(w-max(.5u,1.5u-.5curve));
167
if Times_Compat: y7=.3[bot y8l,bot y6r]; pos8(.6[vair,flare],30); x8l=.5w+1u;
168
else: y7=1/3[bot y8l,bot y6r]; pos8(vair,90); x8l=.5w+.75u; fi
169
pos9(thin_join,180); z9l=z5l; top y8r=h+oo;
170
(x,y8r)=whatever[z8l,z9l]; x8r:=min(x,x8+u);
171
{{interim superness:=more_super;
172
filldraw stroke z9e{up}...z8e{right}...{down}z7e &
173
if Times_Compat: z7e{down}...{(-35,-10)}z6e
174
else: super_arc.e(7,6)fi}}; % bowl
175
if serifs: numeric shaved_stem; shaved_stem=hround(stem-3stem_corr);
176
if hair#+.5stem#>1.5u#: pickup tiny.nib;
177
pos5'(shaved_stem,180); lft x5'r=fine.lft x5r; y5'=y5;
178
pos10(shaved_stem,180); x10=x5'; y10=h-.2[.5tiny,bh];
179
pos11(shaved_stem,180); lft x11r=hround .25u; top y11=h;
180
pos12(shaved_stem,180); x11=x12; bot y12=h-(slab+eps);
181
filldraw z5'l---z10l...z11l{left}--z11r
182
--z12r{right}...z10r-.75(z12-z11)---z5'r--cycle; % foot
183
else: pickup crisp.nib; pos5'(shaved_stem,180); lft x5'r=fine.lft x5r; y5'=y5;
184
pos10(shaved_stem,180); x10=x5'; y10=h-1/3bh;
185
pos11(.2[vair,stem],-90); x11r=.5[x10r,x12r]; top y11l=h+vround .5oo;
186
pos12(hair,0); lft x12l=hround(.1u); y12=min(y10,y11-vair);
187
pos13(hair,0); x13=x12; bot y13=min(vround(h-.6bh),bot y12);
188
(x',y11l)=whatever[z11r,z12r]; x11l:=min(x',x10);
189
if Times_Compat: y13l:=.05[y12l,y13l]; y13r:=y13l; fi
190
filldraw stroke z5'e---z10e...z11e{left}...z12e---z13e; fi % hook
191
else: numeric shaved_stem; shaved_stem=hround(stem-stem_corr);
192
pickup tiny.nib; pos5'(shaved_stem,180); lft x5'r=fine.lft x5r; y5'=y5;
193
pos10(shaved_stem,180); x10=x5'; top y10=h;
194
filldraw stroke z5'e--z10e; fi % base of stem
195
penlabels(1,2,3,4,5,6,7,8,9,10,11,12,13); endchar;
197
cmchar "Turned script A";
198
beginchar("6",10u#+serif_fit#,x_height#,0);
199
italcorr .5x_height#*slant+min(.5curve#-u#,-.25u#);
200
adjust_fit(serif_fit#,0);
201
pickup tiny.nib; pos1(stem',0); pos2(stem,0);
202
pos0'(stem',0); pos0(stem,0); z0l=z0'l; x0'=x1; x0=x2;
203
lft x1l=hround(side_gap-.5stem'); top y1=h+min(oo,serif_drop);
204
numeric edge; edge=rt x2r;
205
pickup fine.nib; pos3(if hefty:thin_join else: hair fi,180);
206
pos4(vair,90); pos5(curve,0); pos6(vair,-90); penpos7(x3l-x3r,-180);
207
rt x3l=max(rt x3l-(lft x3r-tiny.lft x2l),1/3[rt x2,edge]);
208
y3=1/8[bar_height,x_height];
209
x4l=w-.5(w-serif_fit)+.5u; top y4r=x_height+oo;
210
rt x5r=hround min(w-1.35u+.5curve,w-.6u); y5=.5x_height;
211
x6l=x4l-.2u; bot y6r=-oo;
212
x7=x3; y7=min(y3,y6+y4-y3+.6vair);
213
(x,y4r)=whatever[z3l,z4l]; x4r:=min(x,.5[x4,x5r]);
214
(x',y6r)=whatever[z7l,z6l]; x6r:=min(x',.5[x6,x5r]);
215
filldraw stroke z3e{up}...pulled_arc.e(4,5)&pulled_arc.e(5,6)...{up}z7e; % bowl
216
y0=ypart(((edge,h)--(edge,0))intersectionpoint(z3l{up}...{right}z4l));
217
y2=ypart(((edge,h)--(edge,0))intersectionpoint(z6l{left}...{up}z7l));
218
pickup tiny.nib; filldraw stroke z1e--z0'e--z0e--z2e; % stem
219
pickup crisp.nib; pos8(hair,0); pos7'(stem,0);
220
z7'=z2; x8l=x7'l; bot y8=0;
221
filldraw stroke z7'e--z8e; % point
222
if serifs: sloped_serif.l(1,0',a,1/3,jut,serif_drop); fi % upper serif
223
penlabels(0,1,2,3,4,5,6,7,8); endchar;
225
cmchar "Ram's horns";
226
beginchar("7",CT(9.5u#,10u#),x_height#,0);
227
italcorr x_height#*slant+.5hair#-.5u#;
228
adjust_fit(0,0); pickup fine.nib;
229
if serifs: pos1(hair,0); pos9(hair,180);
230
else: pos1(fudged.stem,-10); pos9(fudged.stem,190); fi
231
pos2(vair,-90); pos5(vair,90); pos8(vair,-90);
232
lft x1l=w-rt x9l=hround(.5u-.25hair); y1=y9=.9h-.5hair; x5=.5w; bot y5l=-o;
233
x2=w-x8=x1+1u+.15hair; top y2l=top y8l=h+o;
234
if serifs: pos4(stem,180); pos6(hair,0); pos3(stem,180);pos7(hair,0);
235
else: pos4(fudged.stem,180); pos6(fudged.hair,0);
236
pos3(fudged.stem,180);pos7(fudged.hair,0); fi
237
rt x4l=hround(x5+1u+.5stem); lft x6l=hround(x5-1u-.5hair);
238
y4=y6=.25h+.5max(vair,.5stem);
239
rt x3l=lft x7l=.5w+.5(.5stem-.5hair);
240
y3=y7=.55h+1.5max(vair,.5stem);
241
filldraw stroke z3e--z4e{z4-z3}...{left}z5e...{z7-z6}z6e--z7e;
242
filldraw stroke z1e{up}..z2e...{z4-z3}z3e;
243
filldraw stroke z7e{z7-z6}...z8e..{down}z9e;
244
penlabels(1,2,3,4,5,6,7,8,9); endchar;
247
beginchar("8",CT(9u#,10u#),x_height#,0);
248
italcorr .7x_height#*slant;
249
adjust_fit(if monospace: .5u#,.5u# else: 0,0 fi);
250
penpos1(vair,90); penpos3(vair',-90);
251
penpos2(curve,180); penpos4(curve,0);
252
x2r=hround max(.5u,1.25u-.5curve);
253
x4r=w-x2r; x1=x3=.5w; y1r=h+vround 1.5oo; y3r=-oo;
254
y2=y4=.5h-vair_corr; y2l:=y4l:=.52h;
255
penstroke pulled_arc.e(1,2) & pulled_arc.e(2,3)
256
& pulled_arc.e(3,4) & pulled_arc.e(4,1) & cycle; % bowl
257
hbar(5,6,x2,x4,.5x_height+.5bar);
258
penlabels(1,2,3,4); endchar;
261
beginchar("9",CT(7.25u#+max(.75u#,.5curve#),8.88u#),x_height#,0);
262
italcorr .5[bar_height#,x_height#]*slant+.5min(curve#-1.5u#,0);
263
adjust_fit(if monospace: .25u#,.5u# else: 0,0 fi);
264
numeric left_curve,right_curve;
265
left_curve=right_curve+6stem_corr=curve if not serifs: -3stem_corr fi;
266
if right_curve<tiny.breadth: right_curve:=tiny.breadth; fi
267
if left_curve<tiny.breadth: left_curve:=tiny.breadth; fi
268
pickup tiny.nib; pos1(right_curve,180);
269
pos2(vair,90); pos3(left_curve,0);
270
y1=good.y bar_height; top y2r=h+vround 1.5oo; y0l=bot y1;
271
lft x1r=hround max(.5u,u-.5right_curve);
272
rt x3r=hround min(w-.5u,w-(1.25u-.5left_curve)); x2=.5w-.25u;
273
{{interim superness:=more_super;
274
filldraw stroke super_arc.e(1,2)}}; % right bowl
275
y3=.5[y2,y4]; bot y4r=-oo; x4=x2-.25u;
276
if serifs: pos4(vair',-90); pos5(hair,-180);
277
y5=max(good.y(.5bar_height-.9),y4l+vair); x5r=x1r;
278
(x,y4l)=whatever[z4r,z5]; x4l:=max(x,x4l-.5u);
279
filldraw stroke pulled_arc.e(2,3) & pulled_arc.e(3,4)
280
...{x5-x4,5(y5-y4)}z5e; % left bowl, arc, and terminal
281
else: pos4(vair,-90);
282
filldraw stroke super_arc.e(2,3) & super_arc.e(3,4); % left bowl and arc
283
pickup fine.nib; pos4'(vair,-90); z4=z4';
284
pos5(.5[vair,flare],-95); lft x5r=hround(.6u);
285
y5r=good.y(y5r+1/3bar_height-y5); y5l:=good.y y5l; x5l:=good.x x5l;
286
filldraw stroke term.e(4',5,left,1,4); fi % terminal
287
path testpath; testpath=super_arc.r(2,3) & super_arc.r(3,4);
288
y1'r=y0r=y0l+.6[thin_join,vair]; y1'l=y0l; x1'l=x1'r=x1;
290
x0$=xpart(((0,y0$)--(w,y0$)) intersectionpoint testpath); endfor
291
fill stroke z0e--z1'e; % crossbar
292
penlabels(0,1,2,3,4,5); endchar;
295
beginchar("@",CT(7.25u#+max(.75u#,.5curve#),8.88u#),x_height#,0);
296
italcorr .5[bar_height#,x_height#]*slant+.5min(curve#-1.5u#,0);
297
adjust_fit(if monospace: .25u#,.5u# else: 0,0 fi);
298
numeric left_curve,right_curve;
299
left_curve=right_curve+6stem_corr=curve if not serifs: -3stem_corr fi;
300
if right_curve<tiny.breadth: right_curve:=tiny.breadth; fi
301
if left_curve<tiny.breadth: left_curve:=tiny.breadth; fi
302
pickup tiny.nib; pos1(right_curve,180);
303
pos2(vair,-90); pos3(left_curve,0);
304
y1=good.y (h-bar_height); bot y2r=-vround 1.5oo; y0l=top y1;
305
lft x1r=hround min(.5u,u-.5right_curve);
306
rt x3r=hround max(w-.5u,w-1.25u+.5left_curve); x2=.5w-.25u;
307
{{interim superness:=more_super;
308
filldraw stroke super_arc.e(1,2)}}; % right bowl
309
y3=.5[y2,y4]; top y4r=h+oo; x4=x2-.25u;
310
if serifs: pos4(vair',90); pos5(hair,180);
311
y5=min(good.y(h-(.5bar_height-.9)),y4l-vair); x5r=x1r;
312
(x,y4l)=whatever[z4r,z5]; x4l:=max(x,x4l-.5u);
313
filldraw stroke pulled_arc.e(2,3) & pulled_arc.e(3,4)
314
...{x5-x4,5(y5-y4)}z5e; % left bowl, arc, and terminal
316
filldraw stroke super_arc.e(2,3) & super_arc.e(3,4); % left bowl and arc
317
pickup fine.nib; pos4'(vair,90); z4=z4';
318
pos5(.5[vair,flare],95); lft x5r=hround(.6u);
319
y5r=good.y(h-(-y5r+1/3bar_height+y5)); y5l:=good.y y5l; x5l:=good.x x5l;
320
filldraw stroke term.e(4',5,left,1,4); fi % terminal
321
path testpath; testpath=super_arc.r(2,3) & super_arc.r(3,4);
322
y1'r=y0r=y0l-.6[thin_join,vair]; y1'l=y0l; x1'l=x1'r=x1;
324
x0$=xpart(((w,y0$)--(x1,y0$)) intersectionpoint testpath); endfor
325
fill stroke z0e--z1'e; % crossbar
326
penlabels(0,1,1',2,3,4,5); endchar;
329
beginchar("A",10u#+serif_fit#,x_height#,0);
330
italcorr asc_height#*slant-serif_fit#+.5stem#-2.5u#;
331
adjust_fit(0,serif_fit#);
332
pickup tiny.nib; pos1(stem',0); pos2(stem,0);
333
pos0'(stem',0); pos0(stem,0); z0r=z0'r; x0'=x1; x0=x2;
334
rt x1r=hround(w-side_gap+.5stem'); top y1=h+oo;
335
numeric edge; edge=lft x2l;
336
pickup fine.nib; pos3(if hefty:thin_join else: hair fi,0);
337
pos4(vair,90); pos5(curve,180);
338
pos6(vair,270); penpos7(x3r-x3l,360);
339
lft x3l=1/3[lft x2,edge]; y3=1/8[bar_height,x_height];
340
x4l=.5(w-serif_fit)-.3u; top y4r=x_height+oo;
341
lft x5r=hround max(1.35u-.5curve,.6u); y5=.5x_height;
342
x6l=x4l-.2u; bot y6r=-oo;
343
x7=x3; y7=min(y3,y6+y4-y3+.6vair);
344
(x,y4r)=whatever[z3l,z4l]; x4r:=max(x,.5[x5r,x4]);
345
(x',y6r)=whatever[z7l,z6l]; x6r:=max(x',.5[x5r,x6]);
346
filldraw stroke z3e{up}...pulled_arc.e(4,5)
347
& pulled_arc.e(5,6)...{up}z7e; % bowl
348
y0=ypart(((edge,h)--(edge,0))intersectionpoint(z3l{up}...{left}z4l));
349
pickup tiny.nib; bot y2=if serifs:-min(oo,serif_drop) else: 0 fi;
350
filldraw stroke z0'e--z0e--z2e; % stem
352
pos8(hround(hair-stem_corr),0); pos7'(stem',0);
353
z7'=z0'; x8r=x7'r; top y8=h+oo;
354
filldraw stroke z7'e--z8e;
355
if serifs: sloped_serif.r(2,0,b,1/3,jut,serif_drop); fi % lower serif
356
penlabels(0,1,2,3,4,5,6,7,8); endchar;
359
beginchar("B",CT(9.0u#,9.5u#),asc_height#,desc_depth#);
360
italcorr .5[x_height#,asc_height#]*slant-u#;
361
adjust_fit(serif_fit#+.5u#,0); pickup tiny.nib;
362
pos0(stem,180); pos1(stem,180); pos2(vair,90);
363
pos3(stem,0); pos4(vair,-90); pos5(vair,90);
364
pos6(vair,-270); pos7(curve,-360); pos8(vair,-450);
365
if serifs: if monospace: pos9(stem,-540); else: pos9(1.25hair,-540); fi
366
else: pos9(stem,-540); fi
367
pos0'(stem,0); pos1'(stem,0); z0'=z0; z1'=z1;
368
x0=x1=x9; lft x0r=hround u; x4=x6=x8=.5w+.5u-.25curve; x2=.5w;
369
rt x3r=hround(w-1.5u); rt x7r=hround(w-1.5u+.5curve);
370
lft x5r=min(hround(rt x1l+1.2u),hround(x2-.3curve));
371
bot y0'=-d; top y4l=vround(.56asc_height+.5vair);
372
top y2r=h+oo; y1+o=y3=.5[y2,y4];
373
y5=.5[y4,y6]; y4l=y6r; bot y8=-oo; y7=y9=.5[y6,y8];
374
pos4'(vair,-90); pos6'(vair,-270); z4'=z6'=z5;
375
filldraw stroke z0e---z1e...pulled_arc.e(2,3)
376
& pulled_arc.e(3,4)...{left}z4'e; % stem and upper bowl
377
filldraw stroke z6'e{right}...pulled_arc.e(6,7)
378
& pulled_arc.e(7,8)...{up}z9e; % lower bowl
379
if serifs: dish_serif(0',1',a,1/3,jut,b,1/3,jut); fi
380
penlabels(0,1,2,3,4,5,6,7,8,9); endchar;
382
cmchar "Curly-tail C";
383
beginchar("C",CT(8u#,8.88u#),x_height#,desc_depth#);
384
italcorr x_height#*slant-.2u#;
385
adjust_fit(if monospace: .5u#,.5u# else: 0,0 fi);
386
numeric BH; BH=if Times_Compat:.5613h else: bar_height fi;
387
pickup fine.nib; pos2(vair',90); pos4(vair',270);
388
x2=x4=.5(w+u); top y2r=vround(h+1.5oo); bot y4r=-oo;
389
pos3(curve,180); lft x3r=hround max(.6u,1.35u-.5curve); y3=.5h;
390
if serifs: pos1(hair,0); pos0(flare,0);
391
y1=min(BH+.5flare+2vair'+2,.9[BH,h]-.5flare);
392
rt x1r=hround(w-.7u); bulb(2,1,0); % bulb
393
pos5(hair,0); rt x5r=hround(.92w); y5=.16h+.5vair;
394
(x,y4l)=whatever[z4r,z5l]; x4l:=min(x,x4l+.5u);
395
filldraw stroke pulled_super_arc.e(2,3)(.7superpull)
396
& pulled_super_arc.e(3,4)(.5superpull)
397
..tension .9 and 1..{up}z5e; % arc and lower terminal
398
else: pos1(4/7[vair',flare],80);
399
rt x1r=hround(w-.6u); top y1r=vround .82[BH,top y2r];
400
filldraw stroke term.e(2,1,right,.8,4); % upper terminal
401
pos5(.6[vair',flare],0); x5r=hround(w-.4u);
403
filldraw stroke pulled_super_arc.e(2,3)(.7superpull)
404
& pulled_super_arc.e(3,4)(.5superpull) & z4e{right}...{up}z5e; fi
405
pos6(vair,100); x6l=.3[x4,x5]; y6=.3h+.5vair;
406
pos8(vair,180); x8=u; bot y8=-.75d;
407
pos7(vair,160); x7=.65[x3r,x4r]; y7=.4[y4,y6];
408
filldraw stroke z5e{up}...{(-8,-1)}z6e...{z8-z7}z7e...{(-1,-2)}z8e;
409
penlabels(0,1,2,3,4,5,6,7,8); endchar;
412
beginchar("D",CT(9u#,10u#),asc_height#,0);
413
italcorr asc_height#*slant-.5u#;
414
adjust_fit(if monospace: .5u#,.5u# else: 0,0 fi);
415
penpos1(vair,90); penpos3(vair',-90);
416
penpos2(curve,180); penpos4(curve,0);
417
x2r=hround max(.5u,1.25u-.5curve);
418
x4r=w-x2r; x1=x3=.5w; y1r=if serifs:else:.95 fi x_height; y3r=-oo;
419
y2=y4=.5y1r-vair_corr; y2l:=y4l:=.52x_height;
420
penstroke pulled_arc.e(1,2) & pulled_arc.e(2,3)
421
& pulled_arc.e(3,4) & pulled_arc.e(4,1) & cycle; % bowl
422
if serifs and (not monospace): penpos5(hair/(sind 45),45);
423
else: penpos5(vair,80); fi
424
penpos4'(stem,0); x4r=x4'r; y4=y4'; top y5r=h+oo; x5=x2;
425
penstroke pulled_arc.e(4',5);
426
penpos6(bar+stem_corr,120); penpos7(bar+stem_corr,120);
427
y6=.35[y1,y5]; y7r=h+oo; x7r=rt x4; x6l=rt x2l;
428
filldraw stroke z6e--z7e;
429
penlabels(1,2,3,4,5,6,7); endchar;
432
beginchar("E",CT(8.5u#,8.88u#),x_height#,0);
433
italcorr x_height#*slant-.5u#;
435
epsilon_stroke(false,3.5u);
436
if serifs: numeric bulb_diam;
437
bulb_diam=max(flare-.75(cap_stem-stem),stem);
438
pos0(bulb_diam,0); pos1(hair,0);
439
rt x0r=hround (w-u); y0=min(.9h-.5bulb_diam,.75h+.5bulb_diam);
440
bulb(2,1,0); % upper bulb
441
pos9(bot_thickness,angle(2u,-h));
442
else: pos1(.47[vair',flare],80); rt x1r = w-1u; top y1r = .9h;
443
filldraw stroke term.e(2,1,right,1,4);
444
pos9(.6[vair',flare],-80); fi
445
rt x9r=hround (w-.75u); top y9=vround .25h-o;
446
y9r:=good.y y9r-eps; x9l:=good.x x9l;
447
filldraw stroke term.e(8,9,right,1,4); % lower terminal
448
penlabels(0,1,2,3,4,5,6,7,8,9,10); endchar;
451
beginchar("F",11u#,asc_height#,desc_depth#);
452
italcorr .7x_height#*slant+.5curve#-1.25u#;
453
adjust_fit(0,0); pickup tiny.nib;
454
numeric light_curve; light_curve=hround(.5[stem,curve]-2stem_corr);
455
pos1(vair,90); pos2(light_curve,180); pos3(vair,270); pos4(light_curve,360);
456
x1=x3=.5w; lft x2r=hround(1.5u-.5light_curve); x4=w-x2;
457
top y1r=min(.75h,x_height+2oo); bot y3r=h-top y1r-d-oo;
459
filldraw stroke pulled_arc.e(1,2) & pulled_arc.e(2,3)
460
& pulled_arc.e(3,4) & pulled_arc.e(4,1); % bowl
461
pos5(stem,0); pos6(stem,0); x5=x6=.5w; top y5=h; bot y6=-d;
462
filldraw stroke z5e--z6e; % stem
463
if serifs: dish_serif(5,6,a,1/3,jut,b,1/3,jut);
464
dish_serif(6,5,c,1/3,jut,d,1/3,jut); fi
465
penlabels(1,2,3,4,5,6); endchar;
468
beginchar("G",CT(if serifs: 9.5u# else:9u# fi,10u#),x_height#,desc_depth#);
469
italcorr x_height#*slant+.25u#;
470
adjust_fit(serif_fit# if monospace:+\\.5u#,.5u#+ else:,fi\\ serif_fit#);
471
numeric left_stem,right_stem,outer_jut,alpha,raise;
472
left_stem=fudged.stem-stem_corr;
473
right_stem=min(fudged.hair if hefty:-2stem_corr fi,left_stem);
474
outer_jut=.75jut; x1l=w-x4r=l+letter_fit+outer_jut+.25u; y1=y4=h;
475
raise=if serifs: .05x_height; else: .08x_height; fi
476
x2-x1=x4-x3; x2l+apex_corr=x3l; y2=y3=raise;
477
alpha=diag_ratio(2,right_stem,y1-y2,x4r-x1l-apex_corr);
478
penpos1(alpha*left_stem,0); penpos2(alpha*left_stem,0);
479
penpos3(alpha*right_stem,0); penpos4(alpha*right_stem,0);
480
z0=whatever[z1r,z2r]=whatever[z3l,z4l];
481
if y0>notch_cut+raise: y0:=notch_cut+raise;
482
fill z0+.5right{up}...{z4-z3}diag_end(3l,4l,1,1,4r,3r)
483
--diag_end(4r,3r,1,1,2l,1l)--diag_end(2l,1l,1,1,1r,2r){z2-z1}
484
...{down}z0+.5left--cycle; % left and right diagonals
485
else: fill z0--diag_end(0,4l,1,1,4r,3r)--diag_end(4r,3r,1,1,2l,1l)
486
--diag_end(2l,1l,1,1,1r,0)--cycle; fi % left and right diagonals
487
if serifs: numeric inner_jut; pickup tiny.nib;
488
prime_points_inside(1,2); prime_points_inside(4,3);
489
if rt x1'r+jut+.5u+1<=lft x4'l-jut: inner_jut=jut;
490
else: rt x1'r+inner_jut+.5u+1=lft x4'l-inner_jut; fi
491
dish_serif(1',2,a,1/3,outer_jut,b,1/2,inner_jut); % left serif
492
dish_serif(4',3,c,.6,inner_jut,d,1/2,outer_jut)(dark); fi % right serif
494
penpos5(alpha*left_stem,0); penpos7(vair,-90); penpos9(alpha*right_stem,180);
495
y5=y9=y0; z5=whatever[z1,z2]; z9=whatever[z4,z3];
496
y6=y8=-.5d if not serifs:+.5vair fi;
497
z6=whatever[z1,z2]; z8=whatever[z4,z3];
498
bot y7r=-d-o; x7=.5w+.2(left_stem-right_stem);
499
numeric stem_jut[], y_shift, circle_gap;
500
circle_gap=(x6-.5left_stem)-(x8+.5right_stem);
501
stem_jut1=if circle_gap<.5u: .5 else: .15 fi left_stem;
502
stem_jut2=if circle_gap<.5u: .5 else: .15 fi right_stem;
503
y_shift=if (left_stem-1.2right_stem)>0: .25d else: 0 fi;
504
x6:=x6+stem_jut1; x8:=x8-stem_jut2; y8:=y8+y_shift;
505
penpos6(left_stem,0); penpos8(right_stem,180);
506
filldraw stroke z5e{z2-z1}..z6e..{left}z7e..z8e..{z4-z3}z9e; % bottom loop
507
if not serifs: % minor adjustments
508
pos5'(alpha*left_stem,0);pos9'(alpha*right_stem,180);
509
y5'=y9'=0; z5'l=whatever[z1l,z2l]; z9'l=whatever[z4r,z3r];
510
fill z5l--z5'l--z5'--z5--cycle;
511
fill z9l--z9'l--z9'--z9--cycle; fi
512
penlabels(0,1,2,3,4,5,6,7,8,9); endchar;
515
beginchar("H",10u#,asc_height#,0);
516
italcorr .7[x_height#,asc_height#]*slant-serif_fit#+.5stem#-2u#;
517
adjust_fit(serif_fit#+stem_shift#,serif_fit#-stem_shift#);
518
pickup tiny.nib; pos1(stem,0); pos2(stem,0);
519
pos1'(stem',0); pos2'(stem',0); pos3(stem,0);
520
lft x1l=hround(side_gap-.5stem); x1l=x1'l=x2l=x2'l; x3=w-x1;
521
top y1=.25[x_height,h]; bot y2=0; y1=y1'; y2=y2';
522
filldraw stroke z1'e--z2'e; % left stem
523
h_stroke(2,b,3,4); % arch and right stem
524
hooktop(1,9,10,11,stem',hround(w-1.5u),h,.8,.55,.2);
525
if serifs: numeric inner_jut; pickup tiny.nib;
526
if rt x2r+jut+.5u+1<=lft x4l-jut: inner_jut=jut;
527
else: rt x2r+jut+.5u+1=lft x4l-inner_jut; fi
528
dish_serif(2,1,c,1/3,jut,d,1/3,jut); % lower left serif
529
dish_serif(4,3,e,1/3,inner_jut,f,1/3,jut); fi % lower right serif
530
penlabels(1,2,3,4,9,10,11); endchar;
532
cmchar "Curly-tail J";
533
numeric dot_diam#; dot_diam#=max(dot_size#,cap_curve#);
534
beginchar("J",CT(5.5u#,5.56u#),min(asc_height#,10/7x_height#+.5dot_diam#),
536
define_whole_blacker_pixels(dot_diam);
537
italcorr h#*slant-serif_fit#+.5stem#-2u#;
538
adjust_fit(serif_fit#+2stem_shift# if monospace:+\\.5u# fi +.5u#,
539
-2stem_shift# if monospace:-.5u# fi +.3u#);
540
pickup tiny.nib; pos1(stem',0); pos2(stem',0);
541
rt x1r=hround(.5w+.25u+.5stem'); x1=x2;
542
top y1=x_height if serifs: +min(oo,serif_drop) fi; bot y2=-1/3d;
543
filldraw stroke z1e--z2e; % stem
544
pos3(dot_diam,0); pos4(dot_diam,90);
545
x3r=x1r; top y4r=h+1;
546
if bot y4l-top y1<slab: y4l:=min(y4r-eps,y1+tiny+slab); fi
547
x3=x4; y3=.5[y4l,y4r]; dot(3,4); % dot
548
if serifs: sloped_serif.l(1,2,a,1/3,1.1jut,serif_drop); % upper serif
549
pickup tiny.nib; pos5(vair,-90); pos6(hair,-180);
550
pos7(vair,-270); pos8(vair,-270);
551
x5=.5[x2,x6r]; bot y5r=-d-oo; y6=-.6d;
552
if monospace: lft x6r=0 else: x6r=-.3u fi;
553
(x,y5r)=whatever[z5l,z2l]; x5r:=max(x,.5[x6r,x5]);
554
y7r=y8r=0h; x7=x2l-.5u; x8=w-.5u;
555
filldraw stroke z2e{down}...z5e{left}...z6e{up}...z7e{right}---z8e;
556
else: pickup fine.nib; pos2'(stem',0); z2'=z2;
557
pos6(.2[vair,stem'],-90); pos7(vair,-180);
558
pos8(vair,-270); pos9(vair,-270);
559
lft x7r=hround -.75u; y7=-.5d;
560
z5r=z2'r; (x2'l,y5l)=whatever[z7l,z5r]; x5l=x2'l; y5=y5r;
561
x6r=.5[x7r,x5r]; x6l:=.5[x7l,x5l]; bot y6r=-d-oo;
562
bot y8l = bot y9l = vround(-.5vair); x8 = .5[x7,x2]; x9 = w;
563
filldraw stroke z2'e..{down}z5e & super_arc.e(5,6)
564
& z6e{left}..z7e...{right}z8e--z9e; fi % arc and terminal
565
penlabels(1,2,3,4,5,6,7,8); endchar;
568
beginchar("L",CT(if serifs:9.5u# else:9u# fi,10u#),x_height#+desc_depth#,0);
569
italcorr (x_height#+.6desc_depth#)*slant+.25u#;
570
adjust_fit(serif_fit# if monospace:+\\.5u#,.5u#+ else:,fi\\ serif_fit#);
571
numeric left_stem,right_stem,bot_stem,bot_vair,outer_jut;
572
right_stem=fudged.stem-stem_corr;
573
left_stem=fudged.hair if hefty:-2stem_corr fi;
574
bot_stem=fudged.hair if hefty:-8stem_corr fi;
575
bot_vair=Vround(if serifs: vair else:.5[vair,bot_stem] fi);
577
x1l=w-x4r=l+letter_fit+outer_jut+.25u; y1l=y4r=0; y2r=y3=x_height; x2r=x3r;
578
numeric alpha,alpha[]; x9=w-3u; y9=h+oo-bot_vair;
579
alpha1=diag_ratio(2,bot_stem,y3-y1l,x4r-x1l-apex_corr);
580
alpha2=diag_ratio(1,bot_stem,y9-y1l,x4r-x9);
581
if alpha1>=alpha2: x4r-x3r=x2l-x1l+apex_corr; alpha=alpha1;
582
else: alpha=alpha2; z2r=whatever[z9,z1l-(alpha*bot_stem,0)]; fi
583
penpos1(alpha*left_stem,0); penpos2(alpha*bot_stem,0);
584
alpha3=(y3++(x4r-x3r))/y3;
585
penpos3(alpha3*right_stem,0); penpos4(alpha3*right_stem,0);
586
z0=whatever[z4l,z3l]=z1r+whatever*(z2l-z1l);
587
if y0<x_height-notch_cut: y0:=x_height-notch_cut;
588
fill z0+.5right{down}...{z4r-z3r}diag_end(0,4l,1,1,4r,3r)
589
--z3r--z2l--diag_end(2l,1l,1,1,1r,2r){z2-z1}
590
...{up}z0+.5left--cycle; % left and right diagonals
591
else: fill z0--diag_end(0,4l,1,1,4r,3r)--z3r--z2l
592
--diag_end(2l,1l,1,1,1r,0)--cycle; fi % left and right diagonals
593
penpos5(alpha*bot_stem,0); z5r=whatever[z2r,z1r];
594
y5+.5vair=x_height+.5desc_depth;
595
if serifs: numeric light_bulb; light_bulb=hround 7/8[hair,flare]; clearpen;
596
penpos6(vair,-90); penpos7(hair,0); penpos8(light_bulb,0);
597
penpos6'(vair,90);z6'=z6;
598
x6=w-2u; y6l=h+oo; y8+.5light_bulb=x_height+.85desc_depth; x8r=hround(w-.35u);
599
fill stroke z2e---z5e...{right}z6e; bulb(6',7,8); % arc and bulb
600
numeric inner_jut; pickup tiny.nib;
601
prime_points_inside(1,2); prime_points_inside(4,3);
602
if rt x1'r+jut+.5u+1<=lft x4'l-jut: inner_jut=jut;
603
else: rt x1'r+inner_jut+.5u+1=lft x4'l-inner_jut; fi
604
dish_serif(1',2,a,1/2,outer_jut,b,.6,inner_jut)(dark); % left serif
605
dish_serif(4',3,c,1/2,inner_jut,d,1/3,outer_jut); % right serif
606
else: penpos6(bot_vair,-90); x6=w-2.5u; y6l=h+oo;
607
fill stroke z2e---z5e...{right}z6e; % arc
608
pickup fine.nib; pos6'(bot_vair,-90); z6'=z6;
609
pos7(2/3[bot_vair,flare],-85);
610
rt x7r=hround(w-u); top y7l=x_height+vround(.96desc_depth)+oo;y7r:=good.y y7r;
611
filldraw stroke term.e(6',7,right,1,4); fi % arc and terminal
612
penlabels(0,1,2,3,4,5,6,7,8,9); endchar;
614
cmchar "Left-tail M (at right)";
615
beginchar("M",CT(15u#,15.56u#),x_height#,desc_depth#);
616
italcorr .5[bar_height#,x_height#]*slant-serif_fit#+.5stem#-1.75u#;
617
adjust_fit(serif_fit#+stem_shift#,-stem_shift# if serifs:-.5u# fi);
618
numeric shaved_stem; shaved_stem=hround(mfudged.stem-2stem_corr);
619
pickup tiny.nib; pos1(mfudged.stem,0); pos2(mfudged.stem,0);
620
pos1'(shaved_stem,0); pos2'(shaved_stem,0);
621
pos3(mfudged.stem,0); pos5(mfudged.stem,0);
622
lft x1l=hround(side_gap-.5stem); x1l=x1'l=x2l=x2'l;
623
lft x3l=hround(.5w-.5stem); x5-x3=x3-x1;
624
if not monospace: r:=hround(x5+x1)-l; fi % change width for better fit
625
top y1=h+min(oo,serif_drop); bot y2=0; y1=y1'; y2=y2';
626
filldraw stroke z1'e--z2'e; % left stem
627
h_stroke(2,a,3,4); % left arch and middle stem
628
h_stroke(4,b,5,6); % right arch and right stem
629
if serifs: sloped_serif.l(1',2',c,1/3,jut,serif_drop); % upper left serif
630
numeric inner_jut; pickup tiny.nib;
631
if rt x2r+jut+.5u+1<=lft x4l-jut: inner_jut=jut;
632
else: rt x2r+jut+.5u+1=lft x4l-inner_jut; fi
633
dish_serif(2,1,d,1/3,jut,e,1/3,jut); % lower left serif
634
dish_serif(4,3,f,1/3,inner_jut,g,1/3,jut); fi % lower middle serif
635
left_tail(6,7,8,9,mfudged.stem,rt x4r);
636
penlabels(1,2,3,4,5,6,7,8,9); endchar;
639
beginchar("N",10u#,x_height#,desc_depth#);
640
italcorr .5[bar_height#,x_height#]*slant-serif_fit#+.5stem#-1.25u#;
641
adjust_fit(serif_fit#+stem_shift#,-stem_shift# if serifs:-.5u# fi);
642
pickup tiny.nib; pos1(stem,0); pos2(stem,0);
643
numeric shaved_stem; shaved_stem=hround(stem-2stem_corr);
644
pos1'(shaved_stem,0); pos2'(shaved_stem,0); pos3(stem,0);
645
lft x1l=hround(side_gap-.5stem); x1l=x1'l=x2l=x2'l; x3=w-x1;
646
top y1=h+min(oo,serif_drop); bot y2=0; y1=y1'; y2=y2';
647
filldraw stroke z1'e--z2'e; % left stem
648
h_stroke(2,a,3,4); % arch and right stem
649
if serifs: sloped_serif.l(1',2',b,1/3,jut,serif_drop); % upper left serif
650
numeric inner_jut; pickup tiny.nib;
651
if rt x2r+jut+.5u+1<=lft x4l-jut: inner_jut=jut;
652
else: rt x2r+jut+.5u+1=lft x4l-inner_jut; fi
653
dish_serif(2,1,c,1/3,jut,d,1/3,jut); fi % lower left serif
654
left_tail(4,5,6,7,stem,rt x2r);
655
penlabels(1,2,3,4,5,6,7); endchar;
658
beginchar("O",CT(8u#,8.88u#),x_height#,0);
659
italcorr x_height#*slant-.5u#;
660
adjust_fit(if monospace: .5u#,.5u# else: 0,0 fi);
661
numeric BH; BH=if Times_Compat:.5613h else: bar_height fi;
662
pickup fine.nib; pos2(vair',-90); pos4(vair',90);
663
x2=x4=.5(w-u); bot y2r=vround(-1.5oo); top y4r=h+oo;
664
pos3(curve,0); rt x3r=hround min(w-.6u,w-1.35u+.5curve); y3=.5h;
665
if serifs: pos1(hair,-180); pos0(flare,-180);
666
y1=max(h-BH-.5flare-2vair'-2,h-.9[BH,h]+.5flare);
667
lft x1r=hround(.7u); bulb(2,1,0); % bulb
668
pos5(hair,-180); lft x5r=hround(.5u);
669
y5=min(h-good.y(.5BH-.9),y4l-vair');
670
(x,y4l)=whatever[z4r,z5l]; x4l:=x;
671
filldraw stroke pulled_super_arc.e(2,3)(.7superpull)
672
& pulled_super_arc.e(3,4)(.5superpull)
673
..tension .9 and 1..{x5-x4,5(y5-y4)}z5e; % arc and lower terminal
674
else: pos1(4/7[vair',flare],-100);
675
lft x1r=hround(.6u); bot y1r=h-vround .82[BH,top y4r];
676
filldraw stroke term.e(2,1,left,.8,4); % upper terminal
677
pos5(.6[vair',flare],95); lft x5r=hround .5u;
678
y5r=good.y(h+y5r-1/3BH-y5);
679
y5l:=good.y y5l; x5l:=good.x x5l;
680
filldraw stroke pulled_super_arc.e(2,3)(.7superpull)
681
& pulled_super_arc.e(3,4)(.5superpull)
682
..tension .9 and 1..z5e; fi % arc and lower terminal
683
penlabels(0,1,2,3,4,5); endchar;
685
cmchar "Glottal stop";
686
beginchar("P",CT(9u#,10u#),asc_height#,0);
687
italcorr .8asc_height#*slant-.5u#;
689
pickup tiny.nib; pos7(stem,0); bot y7=0; x7=.47w;
690
pos2(vair,90); pos3(curve,0);
691
pos4(vair,-90); pos5(stem,0); pos6(stem,0);
693
rt x3r=hround(w-u); bot y6=.3x_height;
694
top y2r=h+oo; y3=.5[y2,y4]; y4r=.5y2; y5=y4l;
695
{{interim superness:=more_super;
696
filldraw stroke pulled_super_arc.e(2,3)(superpull)
697
& z3e{down}...{(-10,-1)}z4e;
698
filldraw stroke z5e--z7e\\}}; % arc and stem
699
if serifs: pos1(hair,180); pos0(flare,180);
700
lft x1r=hround u; y1=.3[y3,y2]; bulb(2,1,0); % bulb
701
dish_serif(7,5,e,1/3,jut,f,1/3,jut); %serif
702
else: pickup fine.nib; pos2'(vair,90); z2'=z2;
703
pos1(vround 5/7[vair,flare],110);
704
lft x1r=hround u; top y1r=vround .9[y6,top y2r];
705
filldraw stroke term.e(2',1,left,1,4); fi % terminal
706
penlabels(0,1,2,3,4,5,6,7); endchar;
708
cmchar "Reversed glottal stop";
709
beginchar("Q",CT(9u#,10u#),asc_height#,0);
710
italcorr .8asc_height#*slant-.5u#;
712
pickup tiny.nib; pos7(stem,0); bot y7=0; x7=.53w;
713
pos2(vair,90); pos3(curve,180);
714
pos4(vair,-90); pos5(stem,0); pos6(stem,0);
716
lft x3r=hround(u); bot y6=.3x_height;
717
top y2r=h+oo; y3=.5[y2,y4]; y4r=.5y2; y5=y4l;
718
{{interim superness:=more_super;
719
filldraw stroke pulled_super_arc.e(2,3)(superpull)
720
& z3e{down}...{(10,-1)}z4e;
721
filldraw stroke z5e--z7e\\}}; % arc and stem
722
if serifs: pos1(hair,0); pos0(flare,0);
723
rt x1r=hround (w-u); y1=.3[y3,y2]; bulb(2,1,0); % bulb
724
dish_serif(7,5,e,1/3,-jut,f,1/3,-jut); %serif
725
else: pickup fine.nib; pos2'(vair,90); z2'=z2;
726
pos1(vround 5/7[vair,flare],70);
727
rt x1r=hround (w-u); top y1r=vround .9[y6,top y2r];
728
filldraw stroke term.e(2',1,right,1,4); fi % terminal
729
penlabels(0,1,2,3,4,5,6,7); endchar;
731
cmchar "Fish-hook R";
732
numeric r_flare#; r_flare#=.75[if serifs: stem# else: vair# fi,flare#];
733
define_whole_blacker_pixels(r_flare);
734
beginchar("R",CT(if serifs:max(7u#,5.5u#+r_flare#) else:6.5u# fi,6.66u#),
736
italcorr x_height#*slant if not serifs: +.25u# fi;
737
adjust_fit(serif_fit#,0);
738
pickup fine.nib; top y4r=h+oo;
739
if serifs: pos4(vair,90); pos5(hair,0); x4=.5[x6,.5w];
740
rt x5r=hround(w-if Times_Compat: .25u else: .5u fi +.5);
741
y5+.8r_flare=.9[bar_height,h]+oo;
742
pos6(r_flare,0); bulb(4,5,6); % bulb
743
else: pos4(r_flare,90); rt x4=hround(w-.25u); fi
744
pos0'(hround(stem-3stem_corr),180);
745
rt x0'l=hround(side_gap-.5stem')+stem'; top y0'=bar_height+1.8u;
746
filldraw stroke z0'e{up}...{right}z4e; % arc
747
pickup tiny.nib; pos0(stem',0); pos2(stem',0);
748
pos1(hround(stem-3stem_corr),0); top y1=h+min(oo,serif_drop);
750
lft x1l=hround(side_gap-.5stem'); bot y2=0;
751
filldraw stroke z0e--z2e; % stem
752
if serifs: dish_serif(2,0,b,1/3,jut,c,1/3,1.25jut); fi % lower serif
753
penlabels(1,2,0',4,5,6); endchar;
756
beginchar("S",CT(5u#,5.56u#),asc_height#,desc_depth#);
757
italcorr asc_height#*slant+1u#;
758
adjust_fit(.5u# if monospace:+1.5u# fi,.5u# if monospace:+1.5u# fi);
759
pickup tiny.nib; pos1(stem',0); pos2(stem',0);
760
lft x1l=hround(.5w-.5stem'); x2=x1; y2=0; h-y1=d;
761
filldraw stroke z1e--z2e; % stem
762
left_tail(2,3,4,5,stem',-1u);
763
hooktop(1,6,7,8,stem',w+1u,h,.9,.5,1/3);
764
penlabels(1,2,3,4,5,6,7,8); endchar;
767
beginchar("T",CT(8.25u#,8.88u#),asc_height#,0);
768
italcorr .7asc_height#*slant+.5curve#-u#;
769
adjust_fit(0,0); pickup fine.nib;
770
pos1(vair,90); pos2(curve,180); pos3(vair,270); pos4(curve,360);
771
x1=x3=.5w; lft x2r=hround(1.5u-.5curve); x4=w-x2;
772
top y1r=h+oo; y2=y4=.5[y1,y3]; bot y3r=-oo;
773
filldraw stroke pulled_arc.e(1,2) & pulled_arc.e(2,3)
774
& pulled_arc.e(3,4) & pulled_arc.e(4,1); % bowl
775
pos2'(bar,90); pos4'(bar,90); z2'=z2l; z4'=z4l;
776
filldraw stroke z2'e--z4'e; % bar
777
penlabels(1,2,3,4); endchar;
780
beginchar("U",CT(10u#,11u#),x_height#,0);
781
italcorr x_height#*slant;
783
pickup tiny.nib; pos1(vair,-90); pos2(curve,180);
784
pos3(vair,180); pos4(curve,0); pos5(vair,0);
785
x1=.5w; bot y1r=-o; lft x2r=hround 1.25u; y2=y4=.45h; x4=w-x2;
786
rt x3l=hround(1/3(w+.5u)+.25hair); top y3=top y5=h; x5=w-x3;
787
filldraw stroke z3e{down}...{down}z2e
788
& pulled_super_arc.e(2,1)(.5superpull)
789
& pulled_super_arc.e(1,4)(.5superpull)
790
& z4e{up}...{up}z5e; % bowl
791
numeric arm_thickness[]; path p; p=z3{down}...{down}z2;
792
arm_thickness1=vround(if hefty:slab+2stem_corr else: min(1.5slab,vstem) fi);
793
arm_thickness2=if (not serifs) or monospace: arm_thickness1;
794
else: vround(if hefty:.5slab+2stem_corr else: min(slab,.5vstem) fi); fi
795
pickup crisp.nib; pos6(arm_thickness1,90); pos7(arm_thickness2,90);
796
top y6r=top y7r=h; x6=x3; lft x7r=hround 1.0u;
797
(x,y)=p intersectionpoint((0,y6l)--(w,y6l)); x6l:=x;
798
filldraw stroke z6e--z7e;
799
pos8(arm_thickness1,90); pos9(arm_thickness2,90);
800
y8=y6; y9=y7; x8+x6=x9+x7=w; x8l:=w-x6l;
801
filldraw stroke z8e--z9e;
802
penlabels(1,2,3,4,5,6,7,8,9); endchar;
805
beginchar("V",CT(9u#,9u#),x_height#,0);
806
italcorr x_height#*slant-.5u#;
807
adjust_fit(serif_fit#+stem_shift#,stem_shift#);
808
pickup tiny.nib; interim superness:=more_super;
809
pos3(stem,-180); lft x3r=hround(side_gap-.5stem);
810
x0=0; x2=x3; top y2=h+min(oo,serif_drop);
811
pos2'(stem,-180); z2'=z2; pos4(vair,-90); pos5(hair,0);
812
x4=.5w; rt x5r=hround(w-.8u); y3=.5[y4,y5]; bot y4r=-oo; y5=.57h;
813
filldraw stroke z2'e{down}--super_arc.e(3,4)
814
..tension atleast 1.05..{up}z5e; % left stem and arc
815
if serifs: v_bulb(5,6); % closing bulb
816
pos7(stem,0); pos8(stem,0); z7=z2; z8=z3;
817
sloped_serif.l(7,8,a,1/3,jut,serif_drop);
818
else: pos6(hair,15); top y6=h; x6=x5-.5u;
819
filldraw stroke z5e{up}..z6e; fi
820
penlabels(0,1,2,3,4,5,6,7,8); endchar;
823
beginchar("W",CT(15u#,15.56u#),x_height#,0);
824
italcorr x_height#*slant+serif_fit#;
825
adjust_fit(serif_fit#-stem_shift#,serif_fit#+stem_shift#);
826
numeric shaved_stem; shaved_stem=hround(mfudged.stem-2stem_corr);
827
pickup tiny.nib; pos1(mfudged.stem,0); pos2(mfudged.stem,0);
828
pos1'(shaved_stem,0); pos2'(shaved_stem,0);
829
pos3(mfudged.stem,0); pos5(mfudged.stem,0);
830
rt x1r=hround(w-(2.5u-.5stem)); x1r=x1'r=x2r=x2'r;
831
rt x3r=hround(.5w+.5stem); x5-x3=x3-x1;
832
if not monospace: r:=hround(x5+x1)-l; fi % change width for better fit
833
bot y1=-min(oo,serif_drop); top y2=h; y1=y1'; y2=y2';
834
filldraw stroke z1'e--z2'e; % left stem
835
turned_h_stroke(2,a,3,4); % left arch and middle stem
836
turned_h_stroke(4,b,5,6); % right arch and right stem
837
if serifs: sloped_serif.r(1',2',c,1/3,jut,serif_drop); % upper left serif
838
numeric inner_jut; pickup tiny.nib;
839
if lft x2l-jut-.5u-1>=rt x4r+jut: inner_jut=jut;
840
else: lft x2l-jut-.5u-1=rt x4r+inner_jut; fi
841
dish_serif(2,1,d,1/3,jut,e,1/3,jut); % lower left serif
842
dish_serif(4,3,f,1/3,inner_jut,g,1/3,jut); % lower middle serif
843
dish_serif(6,5,h,1/3,inner_jut,i,1/3,jut); fi % lower right serif
844
penlabels(1,2,3,4,5,6); endchar;
847
beginchar("X",CT(9.5u#,10u#),x_height#,desc_depth#);
848
italcorr x_height#*slant+.5hair#-.75u#;
849
adjust_fit(0,0); pickup fine.nib;
850
if serifs: pos1(hair,180); pos6(hair,180);
851
y1=y2l-h/6; y6=y5r+h/6;
852
else: pos1(fudged.hair,130); pos6(fudged.hair,130);
853
y1=y2l-h/8; y6=y5r+h/8; fi
854
pos2(curve,80); pos5(curve,80);
855
x1-.5hair=hround-.5hair+.5u; x6=w-x1; x2=w-x5=2u;
856
top y2r=h+oo; bot y5l=-d-oo;
857
z0=.5[z2,z5]; z2'=z2l+(.5u,0); z5'=z5r-(.5u,0);
858
numeric theta; theta=angle(z5'-z2')+90;
859
if serifs: pos3(hair,theta); pos4(hair,theta);
860
else: pos3(fudged.hair,theta); pos4(fudged.hair,theta); fi
861
y3r=y2r-h/3; y4l=y5l+h/3; %z3l=whatever[z2',z0]; z4r=whatever[z0,z5'];
862
if serifs: x3r+u=x4l-u=.5w;
863
else: x3r+.4u=x4l-.4u=.5w; fi
864
filldraw stroke z1e{up}..z2e{right}..z3e{z4r-z3r}
865
..z4e{z4r-z3r}..{right}z5e..{up}z6e; % major diagonal and hooks
866
x8l=w-x7r=u; top y7=h; bot y8=-d;
867
if serifs: pos7(stem,0); pos8(stem,0);
868
else: pos7(fudged.stem,0); pos8(fudged.stem,0); fi
869
filldraw stroke z7e--z8e; % minor diagonal
870
penlabels(0,1,2,2',3,4,5',5,6,7,8); endchar;
873
beginchar("Z",CT(8u#,8.88u#),x_height#,desc_depth#);
874
italcorr x_height#*slant-.5serif_fit#-.3u#;
875
adjust_fit(0,.5serif_fit#);
876
yogh_stroke(.5u,.3,.75u,false,false);
877
penlabels(1,2,3,4,5,6,7,8,9,10,12); endchar;
880
beginchar("|",CT(5u#,5.56u#),asc_height#,desc_depth#);
881
italcorr asc_height#*slant+.5rule_thickness#-2u#;
883
numeric thickness; thickness=hround.4[hair,stem];
884
pickup tiny.nib; pos1(thickness,0); pos2(thickness,0);
885
lft x1l = lft x2l = hround(.5w-.5thickness);
887
filldraw stroke z1e--z2e;
888
penlabels(1,2); endchar;
890
cmchar "Double pipe";
891
beginchar("{",CT(8u#,8.88u#),asc_height#,desc_depth#);
892
italcorr asc_height#*slant+.5rule_thickness#-2u#;
894
numeric thickness; thickness=hround(.4[hair,stem]-2stem_corr);
895
pickup tiny.nib; pos1(thickness,0); pos2(thickness,0);
896
pos3(thickness,0); pos4(thickness,0);
897
x1=x2; x3=x4=w-x1; lft x1l = hround((w-3.2u-thickness)/2);
898
top y1=top y3=h; bot y2=bot y4=-d;
899
filldraw stroke z1e--z2e; filldraw stroke z3e--z4e;
900
penlabels(1,2,3,4); endchar;
902
cmchar "Double-barred pipe";
903
beginchar("}",10u#,asc_height#,desc_depth#);
904
italcorr asc_height#*slant+.5rule_thickness#-1.5u#;
906
numeric thickness[]; thickness1=hround.4[hair,stem];
907
pickup tiny.nib; pos1(thickness1,0); pos2(thickness1,0);
908
lft x1l = lft x2l = hround(.5w-.5thickness1);
910
filldraw stroke z1e--z2e;
911
thickness2=vround .3[vair,flare];
912
pos3(thickness2,90); pos4(thickness2,90);
913
pos5(thickness2,90); pos6(thickness2,90);
914
lft x3l = lft x5l = hround 1u;
915
rt x4l = rt x6l = hround(w-1u);
916
top y3r = top y4r = h-d-bot y5;
917
bot y5l = bot y6l = vround(.4(h+d)-d-.5thickness2);
918
filldraw stroke z3e--z4e;
919
filldraw stroke z5e--z6e;
920
penlabels(1,2,3,4,5,6); endchar;