]> git.donarmstrong.com Git - lilypond.git/blobdiff - mf/feta-nummer-code.mf
* scm/framework-texstr.scm (header): change extension to .textmetrics
[lilypond.git] / mf / feta-nummer-code.mf
index 28bd3b7a0d60e5b3225a005194edf8f69d69e596..2559e3bf2b14e5ec87456865fc1426ad6d9ddf60 100644 (file)
@@ -4,7 +4,43 @@
 %
 % source file of the Feta (not the Font-En-Tja) music font
 % 
-% (c) 1997--2002 Jan Nieuwenhuizen <janneke@gnu.org>
+% (c) 1997--2004 Jan Nieuwenhuizen <janneke@gnu.org>
+
+
+
+height#:= number_design_size;
+space# := number_design_size/2;
+
+font_x_height height#;
+font_normal_space space#;
+
+
+%
+% DOCME!
+%ugh. b and h are reused.
+%
+
+save b,h; 4h+b=1.15; 10h+b=1;
+fatten:=number_design_size*h+b;
+
+save b,h; 4h+b=1.05; 10h+b=1;
+widen:=number_design_size*h+b;
+
+tense=0.85;
+thick#:=7/30height#*fatten;
+thin#:=thick#/4*fatten  + max(.1 (height# / 10 - 1), 0);
+
+%% sqrt(.8 * blot_diameter#* thin#) ;
+hair#:= thin# * .8 ;
+
+
+flare#:=9/8 thick# + .75 (height# / 10 - 1);
+
+save b,h; 4h+b=1/8; 10h+b=1/6;
+kuulleke#:=thick#*number_design_size*h+b;
+foot_top#:=thick#;
+foot_width#:=9/4thick#;
+
 
 %
 % These numbers were taken from a part that that the EJE violas played
@@ -17,8 +53,6 @@
 % glyph.
 %
 
-fet_begingroup("number")
-
 define_pixels(height,thick,thick,thin,hair,flare);
 define_pixels(foot_top,foot_width);
 define_pixels(kuulleke);
@@ -175,15 +209,15 @@ save dot_diam;
 dot_diam# = 7/8flare#;
 define_pixels(dot_diam);
 
-code := 32;
-fet_beginchar("Space", "space", "space")
+code := 31; % , 32
+fet_beginchar("Space", "space")
        set_char_box(0, space#,  0,height#);
 fet_endchar;
 
 code := 43;  % , = 44 
 
 % urg
-fet_beginchar("Numeral comma", ",", "comma")
+fet_beginchar("Numeral comma", "comma")
        set_char_box(0, dot_diam#, 3/2dot_diam#, dot_diam#);
        pickup pencircle scaled dot_diam;
        draw (dot_diam/2,dot_diam/2);
@@ -198,7 +232,7 @@ fet_beginchar("Numeral comma", ",", "comma")
        penlabels(1);
 fet_endchar;
 
-fet_beginchar("Numeral dash", "-", "dash")
+fet_beginchar("Numeral dash", "hyphen")
        set_char_box(0, height#/3, 0, height#);
        pickup pencircle scaled thin;
        lft x1 = -b;
@@ -207,7 +241,7 @@ fet_beginchar("Numeral dash", "-", "dash")
        draw z1 .. z2;
 fet_endchar;
 
-fet_beginchar("Numeral dot", ".", "dot")
+fet_beginchar("Numeral dot", "period")
        set_char_box(0, dot_diam#, 0, dot_diam#);
        pickup pencircle scaled dot_diam;
        draw (dot_diam/2,dot_diam/2);
@@ -218,7 +252,7 @@ fet_endchar;
 
 code := 47; % 0 = 48
 
-fet_beginchar("Numeral 0", "0", "zero")
+fet_beginchar("Numeral 0", "zero")
        set_char_box(0, 11/15height# * widen, 0, height#);
        message "w:"&decimal w;
        message "h:"&decimal h;
@@ -237,7 +271,7 @@ fet_beginchar("Numeral 0", "0", "zero")
                ..tension t..z4l..tension t..cycle;
 fet_endchar;
        
-fet_beginchar("Numeral 1", "1", "one")
+fet_beginchar("Numeral 1", "one")
 %      set_char_box(0, 19/30height#*widen, 0, height#);
        set_char_box(0, 1/2foot_width#+3/2thick#+1/2hair#, 0, height#);
        message "w:"&decimal w;
@@ -269,7 +303,7 @@ fet_beginchar("Numeral 1", "1", "one")
        draw_foot(x1);
 fet_endchar;
 
-fet_beginchar("Numeral 2", "2", "two")
+fet_beginchar("Numeral 2", "two")
        set_char_box(0, 22/30 height#*widen, 0, height#);
        message "w:"&decimal w;
        message "h:"&decimal h;
@@ -317,7 +351,12 @@ fet_beginchar("Numeral 2", "2", "two")
 
 fet_endchar;
 
-fet_beginchar("Numeral 3", "3", "three")
+
+%%
+% TODO: should widen a bit. The right edge of the 3 bumps into next glyph in
+% combinations 
+%
+fet_beginchar("Numeral 3", "three")
        set_char_box(0, 2/3height#*widen, 0, height#);
        message "w:"&decimal w;
        message "h:"&decimal h;
@@ -382,7 +421,7 @@ fet_endchar;
 
 
        
-fet_beginchar("Numeral 4", "4", "four")
+fet_beginchar("Numeral 4", "four")
        set_char_box(0, 4/5height#*widen, 0, height#);
        message "w:"&decimal w;
        message "h:"&decimal h;
@@ -424,7 +463,7 @@ fet_beginchar("Numeral 4", "4", "four")
        draw_foot(x5);
 fet_endchar;
 
-fet_beginchar("Numeral 5", "5", "five")
+fet_beginchar("Numeral 5", "five")
        set_char_box(0, 27/40 height#*widen, 0, height#);
        message "w:"&decimal w;
        message "h:"&decimal h;
@@ -477,11 +516,11 @@ fet_beginchar("Numeral 5", "5", "five")
 
 fet_endchar;
 
-fet_beginchar("Numeral 6", "6", "six")
+fet_beginchar("Numeral 6", "six")
        draw_six;
 fet_endchar;
 
-fet_beginchar("Numeral 7", "7", "seven")
+fet_beginchar("Numeral 7", "seven")
        set_char_box(0, 11/15height#*widen, 0, height#);
        message "w:"&decimal w;
        message "h:"&decimal h;
@@ -536,7 +575,7 @@ fi
        penlabels(1,2,3,4,5,6);
 fet_endchar;
 
-fet_beginchar("Numeral 8", "8", "eight")
+fet_beginchar("Numeral 8", "eight")
        set_char_box(0, 11/15height#*widen, 0, height#);
        message "w:"&decimal w;
        message "h:"&decimal h;
@@ -570,12 +609,13 @@ fet_beginchar("Numeral 8", "8", "eight")
                ..z2l{dir(beta)}..cycle;
 fet_endchar;
 
-fet_beginchar("Numeral 9", "9", "nine")
+fet_beginchar("Numeral 9", "nine")
        draw_six;
 %      xy_mirror_char;
        currentpicture := currentpicture scaled -1;
        currentpicture := currentpicture shifted (w,h);
 fet_endchar;
 
-fet_endgroup("number")
+ligtable "3" : "3" kern 0.1 space#,  "0" kern 0.1 space#; 
+ligtable "2" : "7" kern 0.15 space#;