home *** CD-ROM | disk | FTP | other *** search
/ Fresh Fish 8 / FreshFishVol8-CD2.bin / bbs / text / pastex-1.3-7of9.lha / PasTeX / MF / inputs / amsfonts / serb.mf < prev    next >
Text File  |  1991-07-03  |  26KB  |  546 lines

  1. %% @metafontfile{
  2. %%     filename="serb.mf",
  3. %%     version="2.1",
  4. %%     date="30-MAY-1991",
  5. %%     filetype="Metafont: driver",
  6. %%     copyright="Copyright (C) Humanities and Arts Computing Center,
  7. %%            University of Washington;
  8. %%            all rights reserved.  Copying of this file is
  9. %%            authorized only if either:
  10. %%            (1) you make absolutely no changes to your copy
  11. %%                including name; OR
  12. %%            (2) if you do make changes, you first rename it to some
  13. %%                other name.",
  14. %%     author="American Mathematical Society",
  15. %%     address="American Mathematical Society,
  16. %%            Technical Support Group,
  17. %%            P. O. Box 6248,
  18. %%            Providence, RI 02940,
  19. %%            USA",
  20. %%     telephone="401-455-4080 or (in the USA) 800-321-4AMS",
  21. %%     email="Internet: Tech-Support@Math.AMS.com",
  22. %%     codetable="ISO/ASCII",
  23. %%     checksumtype="line count",
  24. %%     checksum="546",
  25. %%     keywords="amsfonts, tex, metafont , cyrillic ",
  26. %%     abstract="This is the driver file for use with 
  27. %%            the cyrillic fonts in AMSFonts 2.1."
  28. %%     }
  29. %
  30. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  31. %This is serb.mf containing serbian and other letters with offsets
  32. %of 8 between upper and lower case
  33.  
  34. %  The letter "ZHE" is first in this file because it uses the picture "K"
  35. %  saved from the end of the previous file.
  36. cmchar "The Russian letter ZHE";
  37. beginchar(oct"021",12u#,cap_height#,0);
  38. italcorr cap_height#*slant+.25u#;
  39. adjust_fit(6u#+cap_serif_fit#,cap_serif_fit#); slantswitch;
  40. pickup tiny.nib; pos1(fudged.cap_stem,0); pos2(fudged.cap_stem,0);
  41. lft x1l=lft x2l=hround max(2u,3u-.5fudged.cap_stem); top y1=h; bot y2=0;
  42. filldraw stroke z1e--z2e; % stem
  43. if serifs:  dish_serif(1,2,a,1/3,cap_jut,b,1/3,cap_jut); % upper stem serif
  44.  dish_serif(2,1,c,1/3,cap_jut,d,1/3,cap_jut);  % lower stem serif
  45. % pickup fine.nib; pos3(vair,90); x3=x1; y3=.55h; z3'=z3; pos3'(slab,90);
  46.  pickup fine.nib; pos3(vair,90); x3=x1; y3=.55h; z3'=z3; pos3'(varwid,90);
  47. % pos4(vair,90); x4=w-2u; top y4r=h+oo;
  48.  pos4(varwid,90); x4=w-.75flare-.125u; top y4r=h+oo;
  49. % filldraw stroke z3'e{right}..{right}z4e;  % upper diagonal
  50.  x41=x4; y41=y3'; x42=x4-2u; y42=y4;
  51.  filldraw stroke z3'e..controls z41 and z42..z4e;  % upper diagonal
  52.  pos5(hair,0); pos6(flare,0);
  53.  rt x5r=hround(w-.125u); y5+.5flare=vround(top y4r-hair)+1;
  54.  top y4'r=top y4r; x4'=x4; pos4'(hair,90);
  55.  bulb(4',5,6); % bulb
  56. % pos7(stem,0); pos8(vair,90); pos9(hair,180);
  57.  pos7(stem,0); pos8(varwid,90); pos9(hair,180);
  58.  x9+.5hair=hround(w+.5hair-eps); y9=1/3x_height;
  59.  lft x7l=hround(w-2.75u-.5stem); y7=1/2y3; x8=w-1.2u; bot y8l=-oo;
  60.  filldraw stroke z3e{right}...z7e{down}
  61.  ...z8e{right}...{up}z9e;  % lower diagonal
  62. else:
  63.  numeric right_jut,stem[],alpha[];
  64.  right_jut=.4tiny; 
  65.  pickup tiny.nib; 
  66.  stem2=max(tiny.breadth,fudged.cap_stem-3stem_corr);
  67.  stem1=max(tiny.breadth,fudged.hair if hefty:-3stem_corr fi);
  68.  top y3=h; rt x3r=hround(r-letter_fit-u-right_jut);
  69.  bot y6=0; rt x6r=hround(r-letter_fit-.75u-right_jut);
  70.  x4=x1; y4=1/3h;
  71.  alpha1=diag_ratio(1,.5(stem1-tiny),y3-y4,x3r-x4);
  72.  penpos3(alpha1*(stem1-tiny),0); penpos4(whatever,-90);
  73.  alpha2=diag_ratio(1,.5(stem2-tiny),y1-y6,x6r-x1);
  74.  penpos6(alpha2*(stem2-tiny),0);
  75.  forsuffixes $=l,r: y3'$=h; y6'$=0; z4$=z3'$+whatever*(z3-z4);
  76.   z5$=z6'$+whatever*(z1-z6)=whatever[z3,z4]; endfor
  77.  z5=.5[z5l,z5r];
  78.  z3'r=z3r+penoffset z3-z4 of currentpen+whatever*(z3-z4);
  79.  % we have also |z3'l=z3l+penoffset z4-z3 of currentpen+whatever*(z3-z4)|;\]
  80.  z6'r=z6r+penoffset z1-z6 of currentpen+whatever*(z1-z6);
  81.  z6'l=z6l+penoffset z6-z1 of currentpen+whatever*(z1-z6);
  82.  fill z4r--diag_end(4r,3'r,1,.5,3'l,4l)--z4l--cycle;  % upper diagonal
  83.  fill z5l--diag_end(5l,6'l,.5,1,6'r,5r)--z5r--cycle;  % lower diagonal
  84. fi
  85. picture V; %transform t;
  86. %t=identity reflectedabout(z1,z2);
  87. %V=currentpicture transformed t;
  88. %addto currentpicture also V;
  89. mirror(x1);
  90. addto currentpicture also K_pic;
  91. %  !!!!! note that this requires K_pic be set as current by previous K definition
  92. %  
  93. picture K_pic; %release resources held by K_pic
  94. endchar;
  95.  
  96. cmchar "The Serbian letter Soft N (looks like Hb)";
  97. beginchar(oct"000",19u#,cap_height#,0);
  98. italcorr cap_height#*slant-cap_serif_fit#+cap_jut#-2.5u#+min(.5cap_stem#,u#);
  99. adjust_fit(cap_serif_fit#,0);
  100. w:=13u;
  101. pickup tiny.nib; pos1(cap_stem,0); pos2(cap_stem,0);
  102. pos3(cap_stem,0); pos4(cap_stem,0);
  103. lft x1l=lft x2l=hround max(2u,3u-.5cap_stem); x3=x4=w-x1;
  104. top y1=top y3=h; bot y2=bot y4=0;
  105. filldraw stroke z1e--z2e; % left stem
  106. filldraw stroke z3e--z4e; % right stem
  107. penpos5(cap_bar,90); penpos6(cap_bar,90);
  108. x5=x1; x6=x3; y5=y6=.52h;
  109. fill stroke z5e--z6e;  % bar
  110. if serifs: numeric inner_jut;
  111.  if rt x1r+cap_jut+.5u+1<=lft x3l-cap_jut: inner_jut=cap_jut;
  112.  else: rt x1r+inner_jut+.5u+1=lft x3l-inner_jut; fi
  113.  dish_serif(1,2,a,1/3,cap_jut,b,1/3,inner_jut);  % upper left serif
  114.  dish_serif(2,1,c,1/3,cap_jut,d,1/3,inner_jut); % lower left serif
  115.  dish_serif(3,4,e,1/3,inner_jut,f,1/3,cap_jut);  % upper rt serif
  116.  nodish_serif(4,3,g,1/3,inner_jut,h,1/3,cap_jut); fi  % lower rt serif
  117. % now the b part
  118. w:=19u; numeric middle_weight;
  119.   middle_weight=if serifs: .6vair+.5 else: cap_bar fi;
  120. z88=z6; penpos88(middle_weight,90); penpos89(middle_weight,90);
  121. y89=y88; x89=x91= if serifs: .5[x3,w-1.5u]+.5u else: .5[x3,w-2.5u] +.5u fi;
  122. numeric right_curve; 
  123. if serifs: right_curve=cap_curve-stem_corr;
  124. else: right_curve=cap_curve-3stem_corr; fi
  125. x89l:=x89-.25u; penpos90(right_curve,0); y90=.5[y89,y91]; x90r=hround(w-u);
  126. bot y92r=0; x92=x4; penpos92(cap_band,-90); y91=y92; penpos91(cap_band,-90);
  127. filldraw stroke z88e..super_arc.e(89,90)&super_arc.e(90,91)..z92e;
  128. math_fit(0,.5ic#); penlabels(1,2,3,4,5,6); endchar;
  129.  
  130. cmchar "The Serbian letter Soft L";
  131. beginchar(oct"001",19u#,cap_height#,0);
  132. adjust_fit(0,0); w:=13u;
  133. pickup tiny.nib; pos1(cap_stem,0); pos2(cap_stem,0);
  134. lft x1l=lft x2l=hround(w-3u); top y1=h; bot y2=0;
  135. filldraw stroke z1e--z2e;
  136. if serifs:
  137.   numeric inner_jut; inner_jut=.5(x1-x5);
  138.   x4=u+.5dot_size; x3=x4+.5dot_size; bot y3r=0; pos3(1.5cap_hair,-90); 
  139.   x5=.42[x4,x1]; top y5=h; pos5(1.5cap_hair,0); pos4(dot_size,-180);
  140.   pos10(hair,-180);
  141.   filldraw stroke z3e{right}...{up}z5e;
  142.   y4=dot_size; bulb(3,10,4);
  143.   nodish_serif(2,1,a,1/3,cap_jut,b,1/3,cap_jut);
  144.   nodish_serif(1,2,c,1/3,inner_jut,d,1/3,cap_jut);
  145. %  pickup crisp.nib; 
  146.   top y6=h;  x6-.75cap_jut=rt x1r; pos6(slab,90);
  147.   x5'+.5cap_jut=lft x5l; top y5'=h; pos5'(slab,90);
  148. %  filldraw stroke z5'e--z6e;
  149.   x9=x5; bot y9=0; pos9(cap_hair,0);
  150.   nodish_serif(5,9,aa,1/3,cap_jut,ab,1/3,inner_jut);  % upper left serif
  151. else:
  152.   x5r=hround u; bot y5r=vround(.06h-o); bot y4r=-o; x4r=.35[x5,x3r];
  153.   x3=x5+3flare; top y3=h; lft x3'=lft x3l; top y3'r=h; rt x1'r=rt x1r;
  154.   top y1'r=h; pos3'(slab,90); pos1'(slab,90); pos5(flare,-120); pos4(vair,-90);
  155.   pos3(hair,0);
  156.   filldraw stroke z5e...{right}z4e...{up}z3e;
  157.   filldraw stroke z3'e--z1'e;
  158. fi
  159. % now the b part
  160. w:=19u; numeric middle_weight; middle_weight=.6vair+.5;
  161. x88=x1; y88=.52h; penpos88(middle_weight,90); penpos89(middle_weight,90);
  162. y89=y88; x89=x91= if serifs: .5[x1,w-1.5u]+.5u else: .5[x1,w-2.5u] +.5u fi;
  163. numeric right_curve; 
  164. if serifs: right_curve=cap_curve-stem_corr; else: right_curve=cap_curve-3stem_corr; fi
  165. x89l:=x89-.25u; penpos90(right_curve,0); y90=.5[y89,y91]; x90r=hround(w-u);
  166. x92=x2; bot y92r=0; penpos92(cap_band,-90); y91=y92; penpos91(cap_band,-90);
  167. filldraw stroke z88e..super_arc.e(89,90)&super_arc.e(90,91)..z92e;
  168. endchar;
  169.  
  170. cmchar "The Serbian letter Hard DJ";
  171. beginchar(oct"002",13u#+width_adj#,cap_height#,if serifs: 1.75cap_stem#
  172.   else: .5desc_depth# fi);
  173. italcorr cap_height#*slant-cap_serif_fit#+cap_jut#-2.5u#+min(.5cap_stem#,u#);
  174. adjust_fit(cap_serif_fit#,cap_serif_fit#);
  175. pickup tiny.nib; pos1(cap_stem,0); pos2(cap_stem,0);
  176. pos3(cap_stem,0); pos4(cap_stem,0);
  177. lft x1l=lft x2l=hround max(2u,3u-.5cap_stem); x3=x4=w-x1;
  178. top y1=top y3=h; bot y2=bot y4=0;
  179. filldraw stroke z1e--z2e; % left stem
  180. filldraw stroke z3e--z4e; % right stem
  181. if serifs: numeric inner_jut;
  182.  if rt x1r+cap_jut+.5u+1<=lft x3l-cap_jut: inner_jut=cap_jut;
  183.  else: rt x1r+inner_jut+.5u+1=lft x3l-inner_jut; fi
  184.  dish_serif(1,2,c,1/3,cap_jut,d,1/3,inner_jut); % u