summaryrefslogtreecommitdiff
path: root/fonts/fge/fgeit.mf
blob: 74620e52799d465f8706495be9feae9bf91eefdf (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
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
% fgeit.mf : fge italic characters
% J.J. Green 2006

mode_setup;
font_setup;

proofing := 2;

slantfont slantfge;

% This is an inverted f, but an italic f with a straight
% descending stem rather than the more usual tail.
% As with the inverted d (below) a hook is attached to
% the left.   

cmchar "inverted f with hook";
beginchar("f", 7.5u#, asc_height#, desc_depth#); 
  italcorr h#*slant + 0.5stem# - 2.5u#;
  adjust_fit(serif_fit# + 2stem_shift#, serif_fit# - 2stem_shift#);

  pickup tiny.nib;

  % stem
  
  pos1(stem', 0); pos2(stem', 0);

  rt.x1r = hround(w/2 + 5u/4 + stem'/2);
  x1 = x2;
  top y1 = h;
  bot y2 = -1/3d;

  filldraw stroke z1e--z2e;

  % bar
  
  pos3(bar, 90);
  pos4(bar, 90);
  bot y3l = bot y4l = 0;

  rt x4 = hround(w - 1/3u);
  x2 - x3 = x4 - x2;
  
  filldraw stroke z3e--z4e;
  
  % arc and bulb

  pos5(vair', -90);
  pos6(hair, -180);
  pos7(flare, -180);

  x5 = 1/2[x2, x6r];
  bot y5r = -d-oo;
  y6 = 1/2flair = -0.88d;
  z6r = z7r;
  rt x7l = floor 11/4u;

  (x, y5r) = whatever[z5l, z2l];
  x5r := max(x, 1/2[x6r, x5]);
  
  filldraw stroke z2e{down}...z5e{left};
  bulb(5, 6, 7);

  % hook

  pos8(0.5[hair, curve], 0);
  rt x8r = lft x1l;
  y8 = 0.5x_height;

  pos9(curve, 90);
  top y9r = x_height + oo;
  x9 = 0.4[0, x8l];

  pos10(hair, 180);
  pos11(hair, -90);

  z9 - z10 = 2.0u*dir(45);
  z8 - z11 = 2.0u*dir(55);
  
  filldraw stroke z11e{right}...z8e{up}...{left}z9e...{down}z10e;
  
  penlabels(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11);

endchar;

% I'm convinced this is a rotated d, which would explain the
% right serif on the stem. I take the code from itall.mf's p
% but replace the flat serif with the slanted serif of the d.
% This looks a little different to the original, but then the
% d's of the original *do* have a flat serif -- so this is
% needed for consistency with computer modern's d. 

cmchar "inverted d with hook";
beginchar("p", 13u#, asc_height#, desc_depth#);
  italcorr 0.7x_height#*slant - u# + 0.5curve#;
  adjust_fit(0, 0);
  
  numeric hook_jut;
  hook_jut = w - 9u;
  
  pickup fine.nib;
  x0 = hook_jut;
  x2 - 0.5stem - hook_jut = hround(2.5u-.5stem);
  hook_in(0, 1, 2);  % opening hook

  pos4(hair, -180);
  pos5(vair, -90);
  pos6(curve, 0);
  pos7(vair, 90);
  x4=x2;
  rt x6r=hround(w-1.5u+.5curve);
  x5=x7=.5[x4, x6];
  bot y5r=-oo;
  top y7r=x_height+oo;
  y4=y6=.5[y5, y7];

  filldraw stroke super_arc.e(4, 5) & pulled_arc.e(5, 6)
  & pulled_arc.e(6, 7) & super_arc.e(7, 4);  % bowl

  pickup tiny.nib;
  pos2'(stem, 0);
  pos3(stem, 0);
  z2=z2';
  x3=x2;
  bot y3=-d;

  filldraw stroke z2'e--z3e;  % stem
  sloped_serif.r(3, 2', a, 1/3, jut, serif_drop);  % serif

  math_fit(-min(2/3x_height#*slant-.5hair#-.5u#, 
      2u#-.5stem#-desc_depth#*slant), ic#);

  % bit ad-hoc this
  
  pos8(hair, 0);
  z8r=z0l;

  pos9(curve, 90);
  pos10(hair, 180);
  
  x9   = 1/2[x8, x10];
  y9r  = 1/2[x_height, h];
  y10r = 1/4[y9l, y8];
  x8l - lft x10r = hook_jut;

  % filldraw stroke z8e{up}...{left}z9e...{down}z10e;
  filldraw stroke super_arc.e(8, 9) & super_arc.e(9, 10);
  
  penlabels(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10);

endchar;

cmchar "Overturned lb ligature";
beginchar(oct "021", 12u#, x_height#, desc_depth#); 
  italcorr 0.7x_height#*slant - 0.5u#;
  adjust_fit(0, 0);
  
  pickup crisp.nib;
  
  slope  := 20;
  obstem := stem/cosd(slope);
  tsep   := 3.75*stem;
  thair  := 0.3[hair, obstem];
  
  % 1-2-11-4-5-6 is the left trunk and flourish, 3 is a utility point
  
  pos1(stem, 0);
  pos2(obstem, 0);
  pos4(hair, 180-slope);
  pos5(hair, -slope);
  pos11(thair, 90);
  
  %x1l = 0.5u;
  x2  = x1;
  bot y1  = y3 = -d;
  y2  = 0.70*x_height;

  z2-z3 = whatever*dir(180-slope);

  z4 = 1.13[z3, z2];
  z5 = whatever[z3, z2];

  x5r = w-0.5u;
  x4r = 0.5u;
  
  % z11 lifts the left stroke

  z11  = 0.5[z2, z4] + whatever*dir(90);
  top y11r = x_height + o;
  
  % z6 might be better half-way between the trunks

  z6 = 0.89[z3, z2];
  pos6(hair, angle(z6-z1)+90);
    
  filldraw stroke z1e--z2e{z2-z1}..z11e..{z1-z2}z4e..tension(1.0)..z5e{z2-z1}..z6e{z1-z6};
  
  penlabels(1, 2, 3, 11, 4, 5, 6);
  
  % the right trunk with foot

  pos7(stem, 0);
  pos8(hair, 90);
  pos9(obstem, 0);
  pos10(hair, 180-slope);

  x7-x1 = x9-x2 = tsep;
  y7 = y1;
  y9 = y2;

  % the vertical lift point
  
  x8  = 0.3[x9, x2];
  top y8r = x_height + o;
  
  z10l = 0.8[z1r, z2r];
  
  filldraw stroke z7e--z9e{z9-z7}...z8e{left}..tension(2.0)..{z7-z9}z10e;

  % serif(7, 9, a, 1/3, cap_jut);
  sloped_serif.r(7, 9, a, 1/3, jut, serif_drop);  % serif
  
  penlabels(7, 8, 9, 10);
  
endchar;

cmchar "inverted F";
beginchar("F", 11.5u#-width_adj#, x_height#, desc_depth#);
  italcorr x_height#*slant-cap_jut#+0.5u#;
  adjust_fit(0, cap_serif_fit#);

  h := vround(h-stem_corr);
  
  pickup tiny.nib;

  pos1(cap_stem, 0);
  pos2(cap_stem, 0);

  rt x1r = rt x2r = hround w - max(2u, 3u-0.5cap_stem);
  top y1 = x_height;
  bot y2 = -desc_depth;
  
  filldraw stroke z1e--z2e; % stem
  
  pickup crisp.nib;
  
  pos3(slab, -90);
  pos4(hair, 180);
  
  bot y3r = -desc_depth;
  x3 = x1;
  rt x4r = hround(0.75u);
  y4 = good.y(y3r+beak)-eps;
  
  arm(3, 4, e, beak_darkness, beak_jut);  % upper arm and beak

  pos5(cap_bar, -90);
  pos6(hair, 180);
  
  top y5l = vround(.5[y2, y1]+.5cap_bar);
  x5 = x1;
  pos0(cap_bar, 90);
  
  pos7(hair, 180);
  z0 = z5;
  x6 = x7;
  y6-y5l = y0l-y7;
  
  rt x6r = hround(4u-.5hair);
  y6 = good.y(y5l+.6beak) + eps;
  rt x9r = hround(w-.5u);

  arm(5, 6, f, beak_darkness, 0);
  arm(0, 7, g, beak_darkness, 0);  % middle arm and serif
  
  nodish_serif(1, 2, a, 1/3, cap_jut, b, 1/3, .5cap_jut);  % upper serif
  dish_serif(2, 1, c, 1/3, cap_jut, d, 1/3, 1.25cap_jut);  % lower serif
  
  math_fit(0, ic#-2.5u#);
  penlabels(0, 1, 2, 3, 4, 5, 6, 7);

endchar;

end