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
|
%
% lgrlig.mf
%
%% Cyrillic font container with T2 encoding beta-support
%
% This file is future part of lxfonts package
% Version 3.4 // Patchlevel=0
% (c) O.Lapko
%
% This package belongs to the public domain under conditions similar to
% those of D. E. Knuth specified for the Computer Modern family of fonts.
% In particular, only the authors are entitled to modify this file
% and to save it under the same name.
%
% Content:
%
% roman dotless i,j
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Special letters
%
% ff-ligs
%
LHver_check(3,4); % like |version_check| in ec
numeric itc#; % modified italic correction on `f' and `ff'
itc#=if serifs: max(0,flare#-.25u#) else: 1.25u# fi;
lhchar "The ligature fi";
beginchar(oct"034",10u#+2letter_fit#,asc_height#,0);
italcorr asc_height#*slant-serif_fit#+.5if serifs:stem# else:dot_size# fi-2u#;
normal_adjust_fit(0,serif_fit#);
pickup tiny.nib; pos1(stem',0); lft x1l=hround(2.5u-.5stem');
pos11(stem',0); rt x11r=hround(w-2.5u+.5stem');
pos12(stem',0); x11=x12; bot y12=0;
pickup fine.nib; numeric bulb_diam, inner_jut;
if serifs: bulb_diam=hround 1/4[.8[stem,flare],dot_size];
pos2(bulb_diam,0); x2r=x12r;
y2+.5bulb_diam=.8[x_height,h+oo]; top y11=x_height+min(oo,serif_drop);
if rt x1r+jut+.5u+2<=lft x11l-jut: inner_jut=jut;
else: rt x1r+inner_jut+.5u+2=lft x11l-inner_jut; fi
else: bulb_diam=max(stem,dot_size);
pos2(6/7[vair,flare],90); top y2r=h; rt x2=hround 5.3u;
pickup tiny.nib; pos13(bulb_diam,0); pos14(bulb_diam,90);
x13=x11-.5; top y14r=min(2x_height,h+1); top y11=x_height;
if bot y14l-x_height<tiny: y14l:=min(y14r-eps,y11+2tiny); fi
x13=x14; y13=.5[y14l,y14r]; dot(13,14); % dot
fi; % this is the ligature we're drawing
f_stroke(1,2,a,b,c,jut,inner_jut); % left stem, arc, terminal, serif
pickup tiny.nib; filldraw stroke z11e--z12e; % right stem
pickup crisp.nib; top y3r=top y4r=x_height; lft x3=hround .5u-1;
pos3(bar,90); pos4(bar,90);
if serifs: x4=x11; % bar will overlap upper right serif
sloped_serif.l(11,12,d,1/3,jut,min(oo,serif_drop)); % upper right serif
dish_serif(12,11,e,1/3,inner_jut,f,1/3,jut); % lower right serif
else: rt x4= hround 5.3u; fi
pickup crisp.nib; filldraw stroke z3e--z4e; % bar
penlabels(1,2,3,4,11,12,13,14); endchar;
lhchar "The ligature ff";
beginchar(oct"033",10.5u#+2letter_fit#,asc_height#,0);
italcorr asc_height#*slant+if serifs:flare#-.25u# else: 1.25u# fi;
normal_adjust_fit(0,0);
pickup tiny.nib; pos1(stem',0); lft x1l=hround(2.5u-.5stem');
pos11(stem',0); rt x11r=hround(w-3u+.5stem');
pickup fine.nib; numeric bulb_diam, inner_jut;
if serifs: bulb_diam=hround .8[stem,flare];
pos2(bulb_diam,0); pos12(bulb_diam,0);
rt x2r=hround(rt x11r-stem_corr); lft x12l=hround(w-.75u+.5);
y2+.5bulb_diam=.85[x_height,h+oo]; y12+.5bulb_diam=.9[x_height,h+oo];
if rt x1r+jut+.5u+2<=lft x11l-jut: inner_jut=jut;
else: rt x1r+inner_jut+.5u+2=lft x11l-inner_jut; fi
else: pos2(5/7[vair,flare],90); top y2r=h; rt x2=hround 6.25u;
pos12(5/7[vair,flare],90); y12=y2; rt x12=hround(w+.75u); fi
f_stroke(1,2,a,b,c,jut,inner_jut); % left stem, arc, terminal, serif
f_stroke(11,12,d,e,f,inner_jut,1.25jut); % right stem, arc, terminal, serif
pickup crisp.nib; top y3r=top y4r=x_height; lft x3=hround .5u-1;
pos3(bar,90); pos4(bar,90);
rt x4=hround(w-1/3u);
if hefty: pos3'(bar,90); x3'-x1=x4-x11; y3'=y3;
pos4'(bar,90); x4'=x11; y4'=y4;
filldraw stroke z3e--z3'e; filldraw stroke z4'e--z4e; % bars
else: filldraw stroke z3e--z4e; fi % bar
penlabels(1,2,3,4,11,12); endchar;
lhchar "The ligature fl";
beginchar(oct"035",10u#+2letter_fit#,asc_height#,0);
italcorr asc_height#*slant-serif_fit#+.5stem#-2u#;
normal_adjust_fit(0,serif_fit#);
pickup tiny.nib; pos1(stem',0); lft x1l=hround(2.5u-.5stem');
pos11(stem',0); rt x11r=hround(w-2.5u+.5stem');
pos12(stem',0); x11=x12; bot y12=0; top y11=h;
filldraw stroke z11e--z12e; % right stem
pickup fine.nib; numeric bulb_diam, inner_jut;
if serifs: bulb_diam=hround .8[stem,flare];
pos2(bulb_diam,0); x2r=x11r-stem_corr;
y2+.5bulb_diam=.9[x_height,h+oo];
sloped_serif.l(11,12,d,1/3,eps,max(serif_drop,oo)); % erase excess at top
if rt x1r+jut+.5u+2<=lft x11l-jut: inner_jut=jut;
else: rt x1r+inner_jut+.5u+2=lft x11l-inner_jut; fi
else: pos2(5/7[vair,flare],90); top y2r=h; rt x2=hround 5.3u; fi
f_stroke(1,2,a,b,c,jut,inner_jut); % left stem, arc, terminal, serif
pickup crisp.nib; top y3r=top y4r=x_height; lft x3=hround .5u-1;
pos3(bar,90); pos4(bar,90);
if serifs: x4=x11;
dish_serif(12,11,e,1/3,inner_jut,f,1/3,jut); % lower right serif
else: rt x4= hround 5.3u; fi
pickup crisp.nib; filldraw stroke z3e--z4e; % bar
penlabels(1,2,3,4,11,12); endchar;
lhchar "The ligature ffi";
beginchar(oct"036",15u#+4letter_fit#,asc_height#,0);
italcorr asc_height#*slant-serif_fit#+.5if serifs:stem# else:dot_size# fi-2u#;
normal_adjust_fit(0,serif_fit#);
pickup tiny.nib; pos1(stem',0); lft x1l=hround(2.5u-.5stem');
pos11(stem',0); lft x11l=hround(.5w-.5stem');
pos21(stem',0); rt x21r=hround(w-2.5u+.5stem');
pos22(stem',0); x21=x22; bot y22=0;
pickup fine.nib; numeric bulb_diam, inner_jut;
if serifs: bulb_diam=hround 1/4[.8[stem,flare],dot_size];
pos2(bulb_diam,0); x2r=x11r-stem_corr;
pos12(bulb_diam,0); x12r=x21r;
top y21=x_height+min(oo,serif_drop);
y2+.5bulb_diam=.8[x_height,h+oo]; y12=y2;
if rt x1r+jut+.5u+2<=lft x11l-jut: inner_jut=jut;
else: rt x1r+inner_jut+.5u+2=lft x11l-inner_jut; fi
else: bulb_diam=max(stem,dot_size);
pos2(5/7[vair,flare],90); top y2r=h; rt x2=hround 5.75u;
pos12(6/7[vair,flare],90); y12=y2; rt x12=hround(.5w+2.8u);
pickup tiny.nib; pos23(bulb_diam,0); pos24(bulb_diam,90);
x23=x21-.5; top y24r=min(2x_height,h+1); top y21=x_height;
if bot y24l-x_height<tiny: y24l:=min(y24r-eps,y21+2tiny); fi
x23=x24; y23=.5[y24l,y24r]; dot(23,24); fi % dot
f_stroke(1,2,a,b,c,jut,inner_jut); % left stem, arc, terminal, serif
f_stroke(11,12,d,e,f,inner_jut,inner_jut); % middle ditto
pickup tiny.nib; filldraw stroke z21e--z22e; % right stem
pickup crisp.nib; top y3r=top y4r=x_height; lft x3=hround.5u-1;
pos3(bar,90); pos4(bar,90);
if serifs: x4=x21; % bar will overlap upper right serif
sloped_serif.l(21,22,g,1/3,jut,min(oo,serif_drop)); % upper right serif
dish_serif(22,21,h,1/3,inner_jut,i,1/3,jut); % lower right serif
else: rt x4=hround(.5w+2.8u); fi
pickup crisp.nib;
if hefty: pos3'(bar,90); x3'-x1=x4-x11; y3'=y3;
pos4'(bar,90); x4'=x11; y4'=y4;
filldraw stroke z3e--z3'e; filldraw stroke z4'e--z4e; % bars
else: filldraw stroke z3e--z4e; fi % bar
penlabels(1,2,3,4,11,12,21,22,23,24); endchar;
lhchar "The ligature ffl";
beginchar(oct"037",15u#+4letter_fit#,asc_height#,0);
italcorr asc_height#*slant-serif_fit#+.5stem#-2u#;
normal_adjust_fit(0,serif_fit#);
pickup tiny.nib; pos1(stem',0); lft x1l=hround(2.5u-.5stem');
pos11(stem',0); lft x11l=hround(.5w-.5stem');
pos21(stem',0); rt x21r=hround(w-2.5u+.5stem');
pos22(stem',0); x21=x22; bot y22=0; top y21=h;
filldraw stroke z21e--z22e; % right stem
pickup fine.nib; numeric bulb_diam, inner_jut;
if serifs: bulb_diam=hround .8[stem,flare];
pos2(bulb_diam,0); x2r=x11r-stem_corr;
pos12(bulb_diam,0); x12r=x21r-stem_corr;
y2+.5bulb_diam=.85[x_height,h+oo]; y12+.5bulb_diam=.9[x_height,h+oo];
sloped_serif.l(21,22,g,1/3,eps,max(serif_drop,oo)); % erase excess at top
if rt x1r+jut+.5u+2<=lft x11l-jut: inner_jut=jut;
else: rt x1r+inner_jut+.5u+2=lft x11l-inner_jut; fi
else: pos2(5/7[vair,flare],90); top y2r=h; rt x2=hround 5.75u;
pos12(5/7[vair,flare],90); y12=y2; rt x12=hround(.5w+2.8u); fi
f_stroke(1,2,a,b,c,jut,inner_jut); % left stem, arc, terminal, serif
f_stroke(11,12,d,e,f,inner_jut,inner_jut); % middle ditto
pickup crisp.nib; top y3r=top y4r=x_height; lft x3=hround.5u-1;
pos3(bar,90); pos4(bar,90);
if serifs: dish_serif(22,21,h,1/3,inner_jut,i,1/3,jut); % lower right serif
pickup crisp.nib; x4=x21;
else: rt x4=hround(.5w+2.8u); fi
if hefty: pos3'(bar,90); x3'-x1=x4-x11; y3'=y3;
pos4'(bar,90); x4'=x11; y4'=y4;
filldraw stroke z3e--z3'e; filldraw stroke z4'e--z4e; % bars
else: filldraw stroke z3e--z4e; fi % bar
penlabels(1,2,3,4,11,12,21,22); endchar;
endinput;
|