X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=mf%2Ffeta-schrift.mf;h=6c003c4685ba09ccbe5ca3490dcb167ef40e0759;hb=5b4b0d6e9a197e8f9eb085b7c2ad78b8be3e5cfc;hp=60470d5a9689154923199616fe326a2d197e7c08;hpb=be9804f8347b5e8c9394136e64851a458ac1d09d;p=lilypond.git diff --git a/mf/feta-schrift.mf b/mf/feta-schrift.mf index 60470d5a96..6c003c4685 100644 --- a/mf/feta-schrift.mf +++ b/mf/feta-schrift.mf @@ -4,7 +4,7 @@ % source file of the Feta (defintively not an abbreviation for Font-En-Tja) % music font % -% (c) 1997--2004 Han-Wen Nienhuys +% (c) 1997--2008 Han-Wen Nienhuys % Jan Nieuwenhuizen % @@ -114,7 +114,8 @@ def draw_short_fermata = pickup pencircle scaled dot_size; - x1 - 2x6 = x2; + x1 - 2 x6 = x2; + x6 := vround (x6); bot y6 = -d; drawdot z6; @@ -327,13 +328,13 @@ fet_beginchar ("Thumb", "thumb"); fet_endchar; -% -% FIXME: rounded endings % % `\accent' is TeX reserved. % def draw_accent (expr bottom_left, top_right, thickness, diminish) = + save thinning_start; + thinning_start = 0.4; pickup pencircle scaled thickness; lft x1 = xpart bottom_left; @@ -342,7 +343,7 @@ def draw_accent (expr bottom_left, top_right, thickness, diminish) = bot y6 = ypart bottom_left; rt z4 = (xpart top_right, (ypart top_right + ypart bottom_left) / 2); - x5 = x3 = (xpart top_right + xpart bottom_left) / 2 + x5 = x3 = thinning_start [xpart top_right, xpart bottom_left] - linethickness + 0.1 staff_space; z3 = whatever [z1, z4]; z5 = whatever [z6, z4]; @@ -379,7 +380,7 @@ fet_beginchar ("> accent", "sforzato"); .5 staff_space#, .5 staff_space#); draw_accent ((-w, -d), (w, h), - 0.05 staff_space + linethickness, 0.6); + 0.05 staff_space + linethickness, 0.7); penlabels (1, 3, 4, 5, 6); labels (7); fet_endchar; @@ -822,7 +823,6 @@ fet_beginchar ("Trill (`tr')", "trill"); .. z4r{down} .. z3r{left} ..tension (1.5 + .7 slant).. z2r{up} - .. z1r -- cycle; z5' = point 1.1 of krul_p; @@ -840,8 +840,8 @@ fet_beginchar ("Trill (`tr')", "trill"); z6''' = point 2.9 of krul_p; penpos6''' (hair_thick, angle (direction 2.9 of krul_p) + 90); penpos7 (hair_thick, up_angle + 90); - z7' = point 3.3 of krul_p; - penpos7' (hair_thick, angle (direction 3.3 of krul_p) + 90); + z7' = point 3.2 of krul_p; + penpos7' (hair_thick, angle (direction 3.2 of krul_p) + 90); % the left loop penstroke z5'e{direction 1.1 of krul_p} @@ -863,7 +863,7 @@ fet_beginchar ("Trill (`tr')", "trill"); penpos11 (hair_thick, -4); z11r = z9r; - z13l = (x9l + r_width, y11 - linethickness); + z13l = (x9l + r_width, y11 - linethickness); penpos13 (r_flare, 180); z15 = z13r - (bulb_size * r_fatness, 0); @@ -878,26 +878,29 @@ fet_beginchar ("Trill (`tr')", "trill"); -- z7'r; (u, v) = before intersectiontimes after; + save before_bulb, after_bulb; + path before_bulb, after_bulb; + before_bulb := z9r{up} + ..tension 0.94.. z13r{down}; + after_bulb := z13l{up} + ..tension 1.06.. z15{down}; + (u_bulb, v_bulb) = before_bulb intersectiontimes after_bulb; + % the connection between `t' and `r', the body of the `r', - % and part of the bulb - fill z7'l{z7 - z7'} - -- z7l + % and the bulb + fill z7'l + -- z7l{z7 - z7'} .. z9l{down} -- simple_serif (z10l, z10r, -30) -- z9r{up} - ..tension 0.94.. z13r{down} - -- z15{down} + .. subpath (0, u_bulb) of before_bulb + .. subpath (v_bulb, infinity) of after_bulb + .. z14 .. z13l{up} .. subpath (0, u) of before .. subpath (v, infinity) of after -- cycle; - % the rest of the bulb - fill z15{up} - ..tension 1.06.. z13l{down} - .. z14 - .. cycle; - penlabels (range 1 thru 15); penlabels (4', 5', 5'', 5''', 6', 6'', 6''', 7'); fet_endchar; @@ -1130,11 +1133,16 @@ fet_beginchar ("Coda", "coda"); penlabels (1, 2, 3, 4); - penstroke z1e{up} - .. z2e{right} - .. z3e{down} - .. z4e{left} - .. cycle; + fill z1l{up} + .. z2l{right} + .. z3l{down} + .. z4l{left} + .. cycle; + unfill z1r{up} + .. z2r{right} + .. z3r{down} + .. z4r{left} + .. cycle; draw_gridline ((0, -h), (0, h), thin); draw_gridline ((-w, 0), (w, 0), thin); @@ -1152,15 +1160,15 @@ fet_beginchar ("Varied Coda", "varcoda"); set_char_box (codawidth# + thick#, codawidth# + thick#, codaheight# + thick#, codaheight# + thick#); - x1 = -codawidth; + x1 = -codawidth + thick - .5 blot_diameter; y1 = y2 - thin; - x2 = codawidth; + x2 = codawidth - thick + .5 blot_diameter; y2 = codaheight; - draw_block (z1, z2); + draw_square_block (z1, z2); - x3 = x1; + x3 = -codawidth; y3 = -codaheight; - x4 = x1 + thick; + x4 = x3 + thick; y4 = y2; draw_block (z3, z4); @@ -1259,7 +1267,7 @@ def draw_arpeggio = save alpha; save ne, nw, se, sw; save x, y; - pair ne,nw,se,sw; + pair ne, nw, se, sw; alpha := -40; @@ -1378,8 +1386,8 @@ def draw_arpeggio_arrow = pickup pencircle scaled vround (0.5 rthin); bot z10 = (0.5 w, 0); - lft z11 = (-0.3 w, 0.8 h); - rt z12 = (1.3 w, 0.8 h); + lft z11 = (0.5 w - hround (0.8 w), 0.8 h); + rt z12 = (0.5 w + hround (0.8 w), 0.8 h); before_left := z1l -- z6{z6 - z1l} @@ -1437,13 +1445,12 @@ fet_endchar; input feta-slag; -% railroad tracks. % -% I actually have no clue how they should look, so we use a slightly curvy -% and tapered shape. +% Railroad tracks. We define two variants of these -- both as slightly +% tapered, comma-shaped curves and as two straight parallel slashes. % -fet_beginchar ("Caesura", "caesura"); +fet_beginchar ("Curved caesura", "caesura.curved"); save slant, space_between, clearance; save alpha, pat; save botthick, topthick; @@ -1497,4 +1504,57 @@ fet_beginchar ("Caesura", "caesura"); fet_endchar; +fet_beginchar ("Straight caesura", "caesura.straight"); + save slant, space_between, clearance; + save thick, ne, pat; + path pat; + pair ne; + + slant = 2.0; + thick = 2.88 linethickness; + + space_between# = 0.56 staff_space#; + clearance# = 0.2 staff_space#; + + set_char_box (0, 2.0 staff_space#, + staff_space# - clearance#, 1.2 staff_space#); + define_whole_pixels (space_between); + + x1 = 0; + x2 = x1 + thick; + y1 = y2 = -d; + + x3 = x4 + thick; + x4 = x1 + (h + d) / slant; + y3 = y4 = h; + + ne = unitvector (z4 - z1); + + z1a = z1 + blot_diameter * ne; + z1b = z1 + blot_diameter * right; + z2a = z2 + blot_diameter * ne; + z2b = z2 + blot_diameter * left; + + z3a = z3 - blot_diameter * ne; + z3b = z3 + blot_diameter * left; + z4a = z4 - blot_diameter * ne; + z4b = z4 + blot_diameter * right; + + pat = z1a{-ne} + .. {right}z1b + -- z2b{right} + .. {ne}z2a + -- z3a{ne} + .. {left}z3b + -- z4b{left} + .. {-ne}z4a + -- cycle; + + fill pat; + fill pat shifted (space_between, 0); + + labels(range 1 thru 4); + labels(1a, 1b, 2a, 2b, 3a, 3b, 4a, 4b); +fet_endchar; + fet_endgroup ("scripts");