| 1 |
.cmchar "The Fraktur comma"; |
| 2 |
.beginchar(",",5u#,x_height#,0); |
| 3 |
.adjust_fit(usual_left#,usual_right#); |
| 4 |
penpos1(0.23570*(x_height+2apex_o),45); |
| 5 |
penpos2(0.23570*(x_height+2apex_o),45); |
| 6 |
penpos3(0.23570*(x_height+2apex_o),45); |
| 7 |
penpos4(0.23570*(x_height+2apex_o),45); |
| 8 |
penpos5(0.23570*(x_height+2apex_o),45); |
| 9 |
penpos6(0.23570*(x_height+2apex_o),45); |
| 10 |
x1l=x3l=x5l=0.5w; |
| 11 |
z2r=z3l; z4r=z5l; |
| 12 |
z2-z1=whatever*dir135; |
| 13 |
z4-z3=whatever*dir135; |
| 14 |
z6-z5=whatever*dir135; |
| 15 |
y1l=-apex_o; y6r=x_height+apex_o; |
| 16 |
%penstroke z1e--z2e; |
| 17 |
penpos10(0.11785*(x_height+2apex_o),-30); |
| 18 |
z10l=(x2l-apex_o,-1.3y2r); |
| 19 |
filldraw z10l--z2l+(2hair,0){up}..{down} |
| 20 |
z1r--z10r--z10l & cycle; |
| 21 |
last_char:=currentpicture; |
| 22 |
.endchar; |
| 23 |
|
| 24 |
|
| 25 |
.cmchar "Apostrophe"; |
| 26 |
.beginchar("'",3.5u#,asc_height#,0); |
| 27 |
currentpicture:=last_char |
| 28 |
shifted (0,1.2x_height); |
| 29 |
.endchar; |
| 30 |
|
| 31 |
.cmchar "Opening Gaensefuesschen"; |
| 32 |
.beginchar(open_gaens,9u#,x_height#,0); |
| 33 |
currentpicture:=last_char; |
| 34 |
addto currentpicture also last_char shifted (4u,0); |
| 35 |
.endchar; |
| 36 |
|
| 37 |
.cmchar "Closing Gaensefuesschen"; |
| 38 |
.beginchar(oct"042",9u#,asc_height#,0); |
| 39 |
currentpicture:=(last_char rotatedaround((3u,0),180)) |
| 40 |
shifted (0,1.2x_height); |
| 41 |
addto currentpicture also (last_char rotatedaround((3u,0),180)) |
| 42 |
shifted (4u,1.2x_height); |
| 43 |
.endchar; |
| 44 |
|
| 45 |
.cmchar "Reverse apostrophe"; |
| 46 |
.beginchar("`",5u#,asc_height#,0); |
| 47 |
currentpicture:=(last_char rotatedaround((3u,0),180)) |
| 48 |
shifted (0,1.2x_height); |
| 49 |
.endchar; |
| 50 |
|
| 51 |
.cmchar "The Fraktur colon"; |
| 52 |
.beginchar(":",5u#,x_height#,0); |
| 53 |
.adjust_fit(usual_left#,usual_right#); |
| 54 |
penpos1(0.23570*(x_height+2apex_o),45); |
| 55 |
penpos2(0.23570*(x_height+2apex_o),45); |
| 56 |
penpos3(0.23570*(x_height+2apex_o),45); |
| 57 |
penpos4(0.23570*(x_height+2apex_o),45); |
| 58 |
penpos5(0.23570*(x_height+2apex_o),45); |
| 59 |
penpos6(0.23570*(x_height+2apex_o),45); |
| 60 |
x1l=x3l=x5l=0.5w; |
| 61 |
z2r=z3l; z4r=z5l; |
| 62 |
z2-z1=whatever*dir135; |
| 63 |
z4-z3=whatever*dir135; |
| 64 |
z6-z5=whatever*dir135; |
| 65 |
y1l=-apex_o; y6r=x_height+apex_o; |
| 66 |
penstroke z1e--z2e; |
| 67 |
penstroke z5e--z6e; |
| 68 |
.endchar; |
| 69 |
|
| 70 |
.cmchar "The Fraktur semicolon"; |
| 71 |
.beginchar(";",5u#,x_height#,0); |
| 72 |
.adjust_fit(usual_left#,usual_right#); |
| 73 |
penpos1(0.23570*(x_height+2apex_o),45); |
| 74 |
penpos2(0.23570*(x_height+2apex_o),45); |
| 75 |
penpos3(0.23570*(x_height+2apex_o),45); |
| 76 |
penpos4(0.23570*(x_height+2apex_o),45); |
| 77 |
penpos5(0.23570*(x_height+2apex_o),45); |
| 78 |
penpos6(0.23570*(x_height+2apex_o),45); |
| 79 |
x1l=x3l=x5l=0.5w; |
| 80 |
z2r=z3l; z4r=z5l; |
| 81 |
z2-z1=whatever*dir135; |
| 82 |
z4-z3=whatever*dir135; |
| 83 |
z6-z5=whatever*dir135; |
| 84 |
y1l=-apex_o; y6r=x_height+apex_o; |
| 85 |
penstroke z1e--z2e; |
| 86 |
penstroke z5e--z6e; |
| 87 |
penpos10(hair,-30); z10l=(x2l,-y2r); |
| 88 |
filldraw z10l{z1r-z10r}..z2l{z2-z1} |
| 89 |
& z2l--z1r--z10r--z10l & cycle; |
| 90 |
.endchar; |
| 91 |
|
| 92 |
.cmchar "The Fraktur point"; |
| 93 |
.beginchar(".",5u#,x_height#,0); |
| 94 |
.adjust_fit(usual_left#,usual_right#); |
| 95 |
pointpoint; |
| 96 |
.endchar; |
| 97 |
|
| 98 |
|
| 99 |
.cmchar "Hachek (check) accent"; |
| 100 |
if (dc_layout>0): xchar_code:=oct"007"; |
| 101 |
else: xchar_code:=oct"024"; |
| 102 |
fi; |
| 103 |
.beginchar(xchar_code,9u#,.75[x_height#,min(asc_height#,2x_height#)],0); |
| 104 |
z100=(0.5w,x_height); hacek(100); |
| 105 |
.endchar; |
| 106 |
|
| 107 |
.cmchar "Breve accent"; |
| 108 |
if (dc_layout>0): xchar_code:=oct"010"; |
| 109 |
else: xchar_code:=oct"025"; |
| 110 |
fi; |
| 111 |
.beginchar(xchar_code,9u#,min(asc_height#,2x_height#),0); |
| 112 |
z100=(0.5w,x_height); breve(100); |
| 113 |
.endchar; |
| 114 |
|
| 115 |
.cmchar "Macron (bar) accent"; |
| 116 |
if (dc_layout>0): xchar_code:=oct"011"; |
| 117 |
else: xchar_code:=oct"026"; |
| 118 |
fi; |
| 119 |
numeric macron_breadth#; macron_breadth#=.2[vair#,stem#]; |
| 120 |
.beginchar(xchar_code,6u#,.4[x_height#,asc_height#]+macron_breadth#,0); |
| 121 |
italcorr h#*slant-.75u#; |
| 122 |
.adjust_fit(0,0); |
| 123 |
numeric macron_breadth; macron_breadth:=Vround .2[vair,stem]; |
| 124 |
pickup if serifs: crisp.nib else: fine.nib fi; |
| 125 |
pos1(2/3stem,70); pos2(2/3stem,70); |
| 126 |
top y1r=top y2r=h+o; lft x1r=w-rt x2l=hround 1.25u; |
| 127 |
filldraw stroke z1e--z2e; % bar |
| 128 |
penlabels(1,2); .endchar; |
| 129 |
|
| 130 |
.cmchar "Cedilla accent"; |
| 131 |
if (dc_layout>0): xchar_code:=oct"013"; |
| 132 |
else: xchar_code:=oct"030"; |
| 133 |
fi; |
| 134 |
.beginchar(xchar_code,9u#,0,.875desc_depth#); |
| 135 |
z100=(0.5w,0); cedilla(100); |
| 136 |
.endchar; |
| 137 |
|
| 138 |
.cmchar "Ogonek accent"; |
| 139 |
if (dc_layout>0): xchar_code:=oct"014"; |
| 140 |
beginchar(xchar_code,9u#,0,.875desc_depth#); |
| 141 |
z100=(0.5w,0); ogonek(100); |
| 142 |
endchar; |
| 143 |
fi; |
| 144 |
|
| 145 |
.cmchar "L-bar accent"; |
| 146 |
if unknown l_width#: |
| 147 |
l_width#:=3lower_u#; fi % nominal width of `l' |
| 148 |
ligtable oct"040": "l" kern -l_width#, |
| 149 |
"L" kern -l_width#; |
| 150 |
.beginchar(oct"040",l_width#,x_height#,0); |
| 151 |
z100=(0,0.5cap_height); ellbar(100); |
| 152 |
.endchar; |
| 153 |
|
| 154 |
if (dc_layout>0): xchar_code:=oct"012"; |
| 155 |
else: xchar_code:=oct"137"; |
| 156 |
fi; |
| 157 |
iff ligs>0: .cmchar "Dot accent"; |
| 158 |
.beginchar(xchar_code,5u#,2x_height#,0); |
| 159 |
z100=(0.5w,x_height); |
| 160 |
pointaccent(100); |
| 161 |
.endchar; |
| 162 |
|
| 163 |
if (dc_layout>0): xchar_code:=oct"005"; |
| 164 |
else: xchar_code:=oct"175"; |
| 165 |
fi; |
| 166 |
iff ligs>0: .cmchar "Long Hungarian umlaut accent"; |
| 167 |
.beginchar(xchar_code,9u#,min(asc_height#,2x_height#),0); |
| 168 |
z100=(0.5w,x_height); hungarum(100); |
| 169 |
.endchar; |
| 170 |
|
| 171 |
if (dc_layout>0): xchar_code:=oct"004"; |
| 172 |
else: xchar_code:=oct"177"; |
| 173 |
fi; |
| 174 |
iff ligs>0: .cmchar "umlaut accent"; |
| 175 |
.beginchar(xchar_code,9u#,min(asc_height#,2x_height#),0); |
| 176 |
z100=(0.5w, x_height); |
| 177 |
umlaut(100); |
| 178 |
.endchar; |
| 179 |
|
| 180 |
if (dc_layout>0): xchar_code:=oct"000"; |
| 181 |
else: xchar_code:=oct"022"; |
| 182 |
fi; |
| 183 |
iff ligs>0: .cmchar "grave accent"; |
| 184 |
.beginchar(xchar_code,9u#,min(asc_height#,2x_height#),0); |
| 185 |
z100=(0.5w, x_height); |
| 186 |
grave(100); |
| 187 |
.endchar; |
| 188 |
|
| 189 |
if (dc_layout>0): xchar_code:=oct"001"; |
| 190 |
else: xchar_code:=oct"023"; |
| 191 |
fi; |
| 192 |
iff ligs>0: .cmchar "acute accent"; |
| 193 |
.beginchar(xchar_code,9u#,min(asc_height#,2x_height#),0); |
| 194 |
z100=(0.5w, x_height); |
| 195 |
acute(100); |
| 196 |
.endchar; |
| 197 |
|
| 198 |
if (dc_layout>0): xchar_code:=oct"002"; |
| 199 |
else: xchar_code:=oct"136"; |
| 200 |
fi; |
| 201 |
iff ligs>0: .cmchar "hat accent"; |
| 202 |
.beginchar(xchar_code,9u#,min(asc_height#,2x_height#),0); |
| 203 |
z100=(0.5w, x_height); |
| 204 |
hat(100); |
| 205 |
.endchar; |
| 206 |
|
| 207 |
.cmchar "Tilde (squiggle) accent"; |
| 208 |
if (dc_layout>0): xchar_code:=oct"003"; |
| 209 |
else: xchar_code:=oct"176"; |
| 210 |
fi; |
| 211 |
.beginchar(xchar_code,9u#,min(asc_height#,10/7x_height#+.5dot_size#),0); |
| 212 |
z100=(0.5w,x_height); tilde(100); |
| 213 |
.endchar; |
| 214 |
|
| 215 |
|
| 216 |
|
| 217 |
.cmchar "En dash"; |
| 218 |
.beginchar(en_dash,9u#,x_height#,0); |
| 219 |
italcorr .61803x_height#*slant+.5u#; |
| 220 |
.adjust_fit(0,0); |
| 221 |
pickup rule.nib; |
| 222 |
pos1(vair,90); pos2(vair,90); |
| 223 |
top y1r=top y2r=vround(.61803h+.5vair); lft x1=-eps; rt x2=w+eps; |
| 224 |
filldraw stroke z1e--z2e; % bar |
| 225 |
penlabels(1,2); .endchar; |
| 226 |
|
| 227 |
.cmchar "Em dash"; |
| 228 |
.beginchar(em_dash,18u#,x_height#,0); |
| 229 |
italcorr .61803x_height#*slant+.5u#; |
| 230 |
.adjust_fit(letter_fit#,letter_fit#); |
| 231 |
pickup rule.nib; pos1(vair,90); pos2(vair,90); |
| 232 |
top y1r=top y2r=vround(.61803h+.5vair); lft x1=-eps; rt x2=w+eps; |
| 233 |
filldraw stroke z1e--z2e; % bar |
| 234 |
penlabels(1,2); .endchar; |
| 235 |
|
| 236 |
.cmchar "Hash mark (number sign)"; |
| 237 |
if monospace: compute_spread(.6x_height#,.7x_height#); |
| 238 |
else: compute_spread(.45x_height#,.55x_height#); fi |
| 239 |
.beginchar("#",15u#,asc_height#,asc_depth#); |
| 240 |
italcorr (math_axis#+.5(spread#+rule_thickness#))*slant-.5u#; |
| 241 |
.adjust_fit(0,0); |
| 242 |
pickup rule.nib; lft x1=hround u-eps; x3=x1; x2=x4=w-x1; |
| 243 |
y1=y2; y3=y4; y1-y3=spread; .5[y1,y3]=math_axis; |
| 244 |
draw z1--z2; % upper bar |
| 245 |
draw z3--z4; % lower bar |
| 246 |
lft x6=hround 3u; rt x7=hround(w-3u); x5-x6=x7-x8; |
| 247 |
x8=good.x if monospace: .6 else: .5 fi\\w; |
| 248 |
top y5=top y7=h+eps; bot y6=bot y8=-d-eps; |
| 249 |
y15=y1; z15=whatever[z5,z6]; y36=y3; z36=whatever[z5,z6]; |
| 250 |
y27=y2; z27=whatever[z7,z8]; y48=y4; z48=whatever[z7,z8]; |
| 251 |
draw z5--if x5>x6+1:(good.x(x15+.5),y1)--(good.x(x15-.5),y1) |
| 252 |
--(good.x(x36+.5),y3)--(good.x(x36-.5),y3)--fi\\z6; % left diagonal |
| 253 |
draw z7--if x7>x8+1:(good.x(x27+.5),y2)--(good.x(x27-.5),y2) |
| 254 |
--(good.x(x48+.5),y4)--(good.x(x48-.5),y4)--fi\\z8; % right diagonal |
| 255 |
labels(1,2,3,4,5,6,7,8,15,27,36,48); .endchar; |
| 256 |
|
| 257 |
.cmchar "Per cent sign"; |
| 258 |
.beginchar("%",15u#, |
| 259 |
body_height#,body_height#-asc_height#); |
| 260 |
italcorr if hefty: .4asc_height#*slant-.5u# else: h#*slant-u# fi; |
| 261 |
.adjust_fit(0,0); pickup fine.nib; |
| 262 |
numeric left_curve,right_curve; |
| 263 |
left_curve=hround 5/6[fudged.hair,fudged.stem]; |
| 264 |
right_curve=max(fine.breadth,hround(fudged.hair if hefty:-2stem_corr fi)); |
| 265 |
pos1(vair,90); pos2(left_curve,180); pos3(vair,270); pos4(right_curve,360); |
| 266 |
top y1r=h; lft x2r=hround u; rt x4r=hround(.5w-1.5u); |
| 267 |
bot y3r=floor(if monospace: .7 else: .5 fi\\ asc_height); |
| 268 |
x1=x3=.5[x2,x4]; y2=y4=.5[y1,y3]; |
| 269 |
filldraw stroke pulled_super_arc.e(1,2)(superpull) |
| 270 |
& pulled_super_arc.e(2,3)(superpull); % left half of upper bowl |
| 271 |
filldraw stroke super_arc.e(3,4) & super_arc.e(4,1); % right half of upper bowl |
| 272 |
pos5(vair,90); pos6(left_curve,180); pos7(vair,270); pos8(right_curve,360); |
| 273 |
bot y7r=-d; rt x8r=hround(w-u); lft x6r=hround(.5w+1.5u); |
| 274 |
top y5r=vround(if monospace: .3 else: .5 fi\\ asc_height); |
| 275 |
x5=x7=.5[x6,x8]; y6=y8=.5[y5,y7]; |
| 276 |
filldraw stroke pulled_super_arc.e(5,6)(superpull) |
| 277 |
& pulled_super_arc.e(6,7)(superpull); % left half of lower bowl |
| 278 |
filldraw stroke super_arc.e(7,8) & super_arc.e(8,5); % right half of lower bowl |
| 279 |
pickup rule.nib; top y9=h; bot y10=-d; |
| 280 |
if hefty: x9=good.x(x5-eps); x10=good.x(x1+eps); |
| 281 |
draw z9--z10; % diagonal |
| 282 |
else: rt x9=hround(w-2.5u); lft x10=hround 2.5u; draw z9--z10; % diagonal |
| 283 |
pickup fine.nib; pos9(rule_thickness,angle(z9-z10)+90); |
| 284 |
pos11(vair,angle(z1r-z4r)-90); pos12(vair,angle(z9-z10)+90); |
| 285 |
path p; p=super_arc.r(1,4); z11r=point 2/3 of p; z12r=z9r; |
| 286 |
filldraw stroke z11e{direction 2/3 of p}...{z9-z10}z12e; fi % link |
| 287 |
penlabels(1,2,3,4,5,6,7,8,9,10,11,12); .endchar; |
| 288 |
|
| 289 |
.cmchar "Left parenthesis"; |
| 290 |
.beginchar("(",7u# if monospace: -u# fi,body_height#,paren_depth#); |
| 291 |
italcorr body_height#*slant-.5u#; |
| 292 |
.adjust_fit(0,0); pickup fine.nib; |
| 293 |
pos1(vair,0); pos2(.75[hair,stem],0); pos3(vair,0); |
| 294 |
rt x1r=rt x3r=hround(w-u); lft x2l=hround(x1-4u if monospace: +4/3u fi); |
| 295 |
top y1=h; y2=.5[y1,y3]=math_axis; |
| 296 |
filldraw stroke z1e{3(x2e-x1e),y2-y1}...z2e |
| 297 |
...{3(x3e-x2e),y3-y2}z3e; % arc |
| 298 |
penlabels(1,2,3); .endchar; |
| 299 |
|
| 300 |
.cmchar "Right parenthesis"; |
| 301 |
.beginchar(")",7u# if monospace: -u# fi,body_height#,paren_depth#); |
| 302 |
italcorr math_axis#*slant-.5u#; |
| 303 |
.adjust_fit(0,0); pickup fine.nib; |
| 304 |
pos1(vair,0); pos2(.75[hair,stem],0); pos3(vair,0); |
| 305 |
lft x1l=lft x3l=hround u; rt x2r=hround(x1+4u if monospace: -4/3u fi); |
| 306 |
top y1=h; y2=.5[y1,y3]=math_axis; |
| 307 |
filldraw stroke z1e{3(x2e-x1e),y2-y1}...z2e |
| 308 |
...{3(x3e-x2e),y3-y2}z3e; % arc |
| 309 |
penlabels(1,2,3); .endchar; |
| 310 |
|
| 311 |
.cmchar "Asterisk"; |
| 312 |
.beginchar("*",9u#, |
| 313 |
if low_asterisk:math_axis#+.5x_height# else: body_height# fi,0); |
| 314 |
italcorr h#*slant-.75u#; |
| 315 |
.adjust_fit(0,0); |
| 316 |
numeric ast_flare; ast_flare=hround .7[thin_join,stem]; |
| 317 |
x0=.5w; y0=h-.5x_height; |
| 318 |
for d=-150 step 60 until 150: z[d]=z0+.5dir d xscaled 7.5u yscaled x_height; |
| 319 |
numeric theta; theta=angle(z[d]-z0); |
| 320 |
fill z0+.5(0,-thin_join)rotated theta |
| 321 |
---z[d]+.5(-ast_flare,-ast_flare)rotated theta |
| 322 |
..z[d]..z[d]+.5(-ast_flare,ast_flare)rotated theta |
| 323 |
---z0+.5(0,thin_join)rotated theta--cycle; endfor % diagonal at angle |d| |
| 324 |
labels(0,[-150],[-90],[-30],30,90,150); .endchar; |
| 325 |
|
| 326 |
.cmchar "Plus sign"; |
| 327 |
beginarithchar("+"); pickup rule.nib; |
| 328 |
x1=x2=good.x .5w; top y1=h+eps; .5[y1,y2]=math_axis; |
| 329 |
lft x3=hround u-eps; x4=w-x3; y3=y4=math_axis; |
| 330 |
draw z1--z2; % stem |
| 331 |
draw z3--z4; % crossbar |
| 332 |
labels(1,2,3,4); .endchar; |
| 333 |
|
| 334 |
.cmchar "Virgule (slash)"; |
| 335 |
.beginchar("/",9u#,body_height#,paren_depth#); |
| 336 |
italcorr body_height#*slant-.5u#; |
| 337 |
.adjust_fit(0,0); pickup rule.nib; |
| 338 |
rt x1=hround(w-u)+eps; top y1=h+eps; |
| 339 |
lft x2=hround u-eps; bot y2=-d-eps; |
| 340 |
draw z1--z2; % diagonal |
| 341 |
penlabels(1,2); .endchar; |
| 342 |
|
| 343 |
.cmchar "Backslash"; |
| 344 |
.beginchar("\",9u#,body_height#,paren_depth#); |
| 345 |
italcorr body_height#*slant-.5u#; |
| 346 |
.adjust_fit(0,0); pickup rule.nib; |
| 347 |
rt x1=hround(w-u)+eps; top y1=h+eps; |
| 348 |
lft x2=hround u-eps; bot y2=-d-eps; |
| 349 |
draw (z1--z2) reflectedabout ((4.5u,0),(4.5u,u)); % diagonal |
| 350 |
penlabels(1,2); .endchar; |
| 351 |
|
| 352 |
.cmchar "Equals sign"; |
| 353 |
compute_spread(.45x_height#,.55x_height#); |
| 354 |
.beginchar("=",14u#,v_center(spread#+rule_thickness#)); |
| 355 |
italcorr h#*slant-.5u#; |
| 356 |
.adjust_fit(0,0); pickup rule.nib; |
| 357 |
lft x1=hround u-eps; x3=x1; x2=x4=w-x1; |
| 358 |
y1=y2; y3=y4; y1-y3=spread; .5[y1,y3]=math_axis; |
| 359 |
draw z1--z2; % upper bar |
| 360 |
draw z3--z4; % lower bar |
| 361 |
labels(1,2,3,4); .endchar; |
| 362 |
|
| 363 |
.cmchar "Left bracket"; |
| 364 |
numeric wd#; wd#=max(5u#,6u#); |
| 365 |
.beginchar("[",wd#,body_height#,paren_depth#); |
| 366 |
italcorr body_height#*slant; |
| 367 |
.adjust_fit(0,0); |
| 368 |
numeric top_thickness,side_thickness; |
| 369 |
if hefty: top_thickness=vair; |
| 370 |
side_thickness=max(crisp.breadth,stem-2stem_corr); |
| 371 |
else: top_thickness=side_thickness=rule_thickness; fi; |
| 372 |
pickup crisp.nib; pos1(side_thickness,0); pos2(side_thickness,0); |
| 373 |
top y1=h; bot y2=-d; lft x1l=lft x2l=hround(2.5u-.5side_thickness)-1-eps; |
| 374 |
filldraw stroke z1e--z2e; % stem |
| 375 |
pos3(top_thickness,90); pos4(top_thickness,90); |
| 376 |
pos5(top_thickness,90); pos6(top_thickness,90); |
| 377 |
x3=x5=x1l; rt x4=rt x6=ceiling(w-.4u)+eps; y3r=y4r=y1; y5l=y6l=y2; |
| 378 |
filldraw stroke z3e--z4e; % upper bar |
| 379 |
filldraw stroke z5e--z6e; % lower bar |
| 380 |
penlabels(1,2,3,4,5,6); .endchar; |
| 381 |
|
| 382 |
.cmchar "Right bracket"; |
| 383 |
numeric wd#; wd#=max(5u#,6u#); |
| 384 |
.beginchar("]",wd#,body_height#,paren_depth#); |
| 385 |
italcorr body_height#*slant-2u#+.5if hefty:stem# else:rule_thickness# fi; |
| 386 |
.adjust_fit(0,0); |
| 387 |
numeric top_thickness,side_thickness; |
| 388 |
if hefty: top_thickness=vair; |
| 389 |
side_thickness=max(crisp.breadth,stem-2stem_corr); |
| 390 |
else: top_thickness=side_thickness=rule_thickness; fi; |
| 391 |
pickup crisp.nib; pos1(side_thickness,0); pos2(side_thickness,0); |
| 392 |
top y1=h; bot y2=-d; rt x1r=rt x2r=hround(w-2.5u+.5side_thickness)+1+eps; |
| 393 |
filldraw stroke z1e--z2e; % stem |
| 394 |
pos3(top_thickness,90); pos4(top_thickness,90); |
| 395 |
pos5(top_thickness,90); pos6(top_thickness,90); |
| 396 |
x3=x5=x1r; lft x4=lft x6=floor .4u-eps; y3r=y4r=y1; y5l=y6l=y2; |
| 397 |
filldraw stroke z3e--z4e; % upper bar |
| 398 |
filldraw stroke z5e--z6e; % lower bar |
| 399 |
penlabels(1,2,3,4,5,6); .endchar; |
| 400 |
|
| 401 |
|
| 402 |
cmchar "Exclamation point"; |
| 403 |
beginchar("!",5u#,asc_height#,0); |
| 404 |
italcorr asc_height#*slant-2u#-.5width_adj#+.5dot_size#; |
| 405 |
adjust_fit(0,0); |
| 406 |
pointpoint; |
| 407 |
pickup tiny.nib; pos103(dot_size,0); pos104(dot_size,90); |
| 408 |
lft x103l=hround(.5w-.5dot_size); bot y104l=0; z103=z104; % dot |
| 409 |
numeric bot_width; |
| 410 |
bot_width=if hefty:max(hround .8dot_size,fine.breadth) else: hair fi; |
| 411 |
pickup fine.nib; pos101(dot_size,0); pos102(bot_width,0); |
| 412 |
x101=x102=x103; bot y102=.25[top y104r,x_height]+1; |
| 413 |
if square_dots: top y101=h; |
| 414 |
filldraw stroke z101e--z102e; % stem |
| 415 |
else: top z100=(x101,h+o); y101+.5dot_size=h+o; |
| 416 |
filldraw z101r...z100...z101l---z102l--z102r---cycle; fi % stem and bulb |
| 417 |
penlabels(0,1,2,3,4); endchar; |
| 418 |
|
| 419 |
cmchar "Question mark"; |
| 420 |
beginchar("?",8.5u#,asc_height#,0); |
| 421 |
italcorr .8asc_height#*slant; |
| 422 |
adjust_fit(0,0); |
| 423 |
pointpoint; |
| 424 |
pickup tiny.nib; pos107(dot_size,0); pos108(dot_size,90); |
| 425 |
lft x107l=hround(.5w-.25u-.5dot_size); bot y108l=0; z107=z108; % dot |
| 426 |
numeric bot_width; |
| 427 |
bot_width=if hefty:max(hround .8dot_size,fine.breadth) else: hair fi; |
| 428 |
pickup fine.nib; pos102(vair,90); pos103(curve,0); |
| 429 |
pos104(vair,-90); pos105(bot_width,0); pos106(bot_width,0); |
| 430 |
x102=x104=x105=x106=x107; rt x103r=hround(w-u); bot y106=1+.25[top y108r,x_height]; |
| 431 |
top y102r=h+oo; y103=.75[y106,y102]; y104=.5[y106,y102]; y105=.1[y106,y102]; |
| 432 |
{{interim superness:=more_super; |
| 433 |
filldraw stroke pulled_super_arc.e(102,103)(superpull) |
| 434 |
& subpath (0,1) of super_arc.e(103,104) .. z105e---z106e\\}}; % arc and stem |
| 435 |
if serifs: pos101(hair,180); pos100(flare,180); |
| 436 |
lft x101r=hround u; y101=y103; bulb(102,101,100); % bulb |
| 437 |
else: pos101(Vround 5/7[vair,flare],110); |
| 438 |
lft x101r=hround u; top y101r=vround .9[y106,top y102r]; |
| 439 |
filldraw stroke term.e(102,101,left,101,104); fi % terminal |
| 440 |
penlabels(0,1,2,3,4,5,6,7,8); endchar; |
| 441 |
|
| 442 |
|
| 443 |
cmchar "Ampersand"; |
| 444 |
beginchar("&",14u#,asc_height#,0); |
| 445 |
italcorr x_height#*slant-serif_fit# - if serifs: .4u# else: 1.5u# fi; |
| 446 |
adjust_fit(0,serif_fit#); |
| 447 |
pickup tiny.nib; pos2(slab,-90); x2=4u; bot y2r=-o; |
| 448 |
if not hefty:(x,y2l)=whatever[z2r,(w-5u,x_height)]; x2l:=x; fi |
| 449 |
if serifs: pos0(fudged.hair,0); |
| 450 |
rt x0r+jut=hround(w-.9u); top y0=x_height; |
| 451 |
pos1(fudged.hair,0); z1=whatever[z0,(.6[x0,x2],0)]; |
| 452 |
y1=max(y0-1.5bracket-.2x_height,2/3x_height); |
| 453 |
filldraw stroke z0e---z1e...{left}z2e; % short diagonal |
| 454 |
else: pickup fine.nib; pos1(.25[slab,flare],-15); rt x1r=hround(w-2u); |
| 455 |
y1r=good.y .75[bar_height,x_height]; x1l:=good.x x1l; y1l:=good.y y1l; |
| 456 |
top z2'l=(x2l,tiny.top y2l); bot z2'r=(x2r,tiny.bot y2r); |
| 457 |
filldraw stroke term.e(2',1,right,1,4); fi % short diagonal and terminal |
| 458 |
pickup tiny.nib; numeric slope,theta,reduced_hair; |
| 459 |
slope=(h-2vair-slab)/10.5u; theta=angle(-slope,1); |
| 460 |
reduced_hair=max(tiny.breadth,hround(fudged.hair if hefty:-2stem_corr fi)); |
| 461 |
lft x3r=hround .75u; x5=.5[x3r,x6l]; lft x6r=hround .5(w-u); |
| 462 |
x3l-x3r=curve-tiny; pos6(reduced_hair,180); |
| 463 |
pos5(vair,theta); y5=.5h; |
| 464 |
ellipse_set(2l,3l,4l,5l); ellipse_set(2r,3r,4r,5r); |
| 465 |
pos7(vair,270); top y7l=h+o; x7=.45[x6r,x8r]; |
| 466 |
pos8(fudged.stem,30); x8l=good.x(x8l+3.5u-x8); y8r=y6; |
| 467 |
ellipse_set(7l,6l,5',5l); |
| 468 |
filldraw stroke z2e{left}...z3e{up}...z4e---z5e...{up}z6e |
| 469 |
...z7e{left}...z8e{down}; % bowls |
| 470 |
pos10(slab,90); x10=w-3.5u; bot y10l=-o; |
| 471 |
pos9(fudged.stem,angle(z8-z10)-90); |
| 472 |
z9=.5[z8,z10]+(1.75u,0) rotated(angle(z8-z10)+90); |
| 473 |
filldraw stroke z8e{down}...z9e{z10-z8}...{right}z10e; % long diagonal |
| 474 |
if serifs: pickup crisp.nib; pos10'(slab,90); z10'=z10; |
| 475 |
pos11(fudged.hair,180); rt x11l=hround(w-u); y11=.5bar_height; |
| 476 |
filldraw stroke z10'e{right}...{up}z11e; % terminal |
| 477 |
numeric inner_jut; if rt x6l+.5u<lft x0l-1.5jut: inner_jut=1.5jut; |
| 478 |
else: rt x6l+.5u=lft x0l-inner_jut; fi |
| 479 |
dish_serif(0,1,a,.6,inner_jut,b,.5,jut)(dark); % serif |
| 480 |
else: pickup fine.nib; pos10'(slab,90); z10'=z10; |
| 481 |
pos11(Vround .5[slab,flare],90); |
| 482 |
rt x11=hround(r-letter_fit-u); bot y11l=vround .07bar_height-o; |
| 483 |
filldraw stroke term.e(10',11,right,1,4); fi % terminal |
| 484 |
penlabels(0,1,2,3,4,5,6,7,8,9,10,11); endchar; |
| 485 |
|
| 486 |
|
| 487 |
cmchar "Left curly brace"; |
| 488 |
beginchar(oct"173",9u#,body_height#,paren_depth#); |
| 489 |
italcorr body_height#*slant+.5vair#-u#; |
| 490 |
adjust_fit(0,0); pickup fine.nib; |
| 491 |
forsuffixes $=1,1',4,4',7,7': pos$(vair,0); endfor |
| 492 |
forsuffixes $=2,3,5,6: pos$(stem,0); endfor |
| 493 |
x2=x3=x5=x6; x1=x1'=x7=x7'=w-x4=w-x4'; |
| 494 |
lft x4l=hround(1.5u-.5vair); lft x2l=hround(.5w-.5stem); |
| 495 |
top y1=h; bot y7=-d; .5[y4,y4']=.5[y1,y7]=.5[y2,y6]=.5[y3,y5]; |
| 496 |
y1-y2=y3-y4=(y1-y4)/4; y1-y1'=y4-y4'=y7'-y7=vair-fine; |
| 497 |
filldraw z1l{left}...z2l---z3l...{left}z4l |
| 498 |
--z4'l{right}...z5l---z6l...{right}z7l |
| 499 |
--z7r--z7'r{left}...z6r---z5r...{left}.5[z4r,z4'r]{right} |
| 500 |
...z3r---z2r...{right}z1'r--z1r--cycle; % stroke |
| 501 |
penlabels(1,2,3,4,5,6,7); endchar; |
| 502 |
|
| 503 |
|
| 504 |
cmchar "Right curly brace"; |
| 505 |
beginchar(oct"175",9u#,body_height#,paren_depth#); |
| 506 |
italcorr math_axis#*slant+.5vair#-u#; |
| 507 |
adjust_fit(0,0); pickup fine.nib; |
| 508 |
forsuffixes $=1,1',4,4',7,7': pos$(vair,0); endfor |
| 509 |
forsuffixes $=2,3,5,6: pos$(stem,0); endfor |
| 510 |
x2=x3=x5=x6; x1=x1'=x7=x7'=w-x4=w-x4'; |
| 511 |
rt x4r=hround(w-1.5u+.5vair); rt x2r=hround(.5w+.5stem); |
| 512 |
top y1=h; bot y7=-d; .5[y4,y4']=.5[y1,y7]=.5[y2,y6]=.5[y3,y5]; |
| 513 |
y1-y2=y3-y4=(y1-y4)/4; y1-y1'=y4-y4'=y7'-y7=vair-fine; |
| 514 |
filldraw z1r{right}...z2r---z3r...{right}z4r |
| 515 |
--z4'r{left}...z5r---z6r...{left}z7r |
| 516 |
--z7l--z7'l{right}...z6l---z5l...{right}.5[z4l,z4'l]{left} |
| 517 |
...z3l---z2l...{left}z1'l--z1l--cycle; % stroke |
| 518 |
penlabels(1,2,3,4,5,6,7); endchar; |
| 519 |
|
| 520 |
|
| 521 |
cmchar "Vertical line"; |
| 522 |
beginchar(oct"174",5u#,body_height#,paren_depth#); |
| 523 |
italcorr body_height#*slant+.5rule_thickness#-2u#; |
| 524 |
adjust_fit(0,0); pickup rule.nib; |
| 525 |
x1=x2=good.x .5w; top y1=h+eps; bot y2=-d-eps; |
| 526 |
draw z1--z2; % stem |
| 527 |
labels(1,2); endchar; |
| 528 |
|
| 529 |
|
| 530 |
|
| 531 |
cmchar "Sterling sign"; |
| 532 |
beginchar(oct"277",12u#,asc_height#,0); |
| 533 |
adjust_fit(0,.75asc_height#*slant-.5u#); pickup fine.nib; |
| 534 |
pos0(flare,0); pos1(hair,0); pos2(vair,90); pos3(stem,180); |
| 535 |
pos4(stem,180); pos4'(stem,0); pos5(vair,-90); z4'=z4; |
| 536 |
x2=2/3w-.5u; rt x3l=rt x4l=hround(.5w-u+.5stem); x5=2.5u; |
| 537 |
y1=y3=.75h; top y2=h+oo; y4=.25h; bot y5r=-oo; |
| 538 |
rt x1r=hround(w-1.5u); bulb(2,1,0); % bulb |
| 539 |
filldraw stroke pulled_arc.e(2,3)..z4e; % stem |
| 540 |
numeric light_stem; light_stem=2/3[vair,vstem]; |
| 541 |
pos6(.5[hair,light_stem],-180); pos7(light_stem,-300); |
| 542 |
pos8(light_stem,-300); pos9(hair,-180); |
| 543 |
lft x6r=hround u; x7=3u; x8=w-3.5u; rt x9r=hround(w-u); |
| 544 |
y6=.4[y5,y7]; top y7r=vround .2h; bot y8l=-oo; y9=good.y .2h; |
| 545 |
filldraw stroke pulled_arc.e(4',5)...z6e{up}...z7e{right} |
| 546 |
..{right}z8e...{up}z9e; % loop and arm |
| 547 |
pos10(bar,90); pos11(bar,90); x10=3u; x11=w-4.5u; |
| 548 |
top y10r=top y11r=vround(.5h+.5bar); filldraw stroke z10e--z11e; % bar |
| 549 |
penlabels(1,2,3,4,5,6,7,8,9,10,11); endchar; |
| 550 |
|
| 551 |
|