X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=mf%2Ffeta-scripts.mf;h=83859dbe66fc2b4af51bd7bf63947d9700db6913;hb=446dc1f3ac9bfff6bfee31de929698b0425da6fe;hp=6d921cb74606fcfae725df6c361abe685f096060;hpb=27a4d9354effb09c696925881ec4df007da8a0db;p=lilypond.git diff --git a/mf/feta-scripts.mf b/mf/feta-scripts.mf index 6d921cb746..83859dbe66 100644 --- a/mf/feta-scripts.mf +++ b/mf/feta-scripts.mf @@ -1,7 +1,7 @@ % Feta (not the Font-En-Tja) music font -- implement scripts % This file is part of LilyPond, the GNU music typesetter. % -% Copyright (C) 1997--2010 Han-Wen Nienhuys +% Copyright (C) 1997--2012 Han-Wen Nienhuys % Jan Nieuwenhuizen % % @@ -620,6 +620,44 @@ fet_beginchar ("halfopen (unstopped)", "halfopen"); fet_endchar; +fet_beginchar ("halfopen vertical", "halfopenvertical"); + save thin, height, width, thick, factor, slash; + + factor := 3/2; + height# = 5/4 width#; + height# = staff_space#; + thin = 0.6 linethickness + 0.06 staff_space; + slash# = 1.05 linethickness#; + + set_char_box (width# / 2, width# / 2, + height# / 2, height# / 2); + + define_pixels (width, height, slash); + + 2 thick + 0.6 (height - 2 thin) = width; + + penpos1 (thick, 0); + penpos2 (thin, 90); + penpos3 (thick, 180); + penpos4 (thin, 270); + z1r = (w, 0); + z2r = (0, h); + z3r = (-w, 0); + z4r = (0, -h); + + penlabels (1, 2, 3, 4); + + penstroke z1e{up} + .. z2e{left} + .. z3e{down} + .. z4e{right} + .. cycle; + + draw_brush ((0, -h * factor), slash, + (0, h * factor), slash); +fet_endchar; + + fet_beginchar ("plus (stopped)", "stopped"); save hthick, vthick, size, outer_hsize, outer_vsize; @@ -1151,27 +1189,29 @@ fet_beginchar ("Segno", "segno"); penlabels (range 1 thru 8); fet_endchar; + fet_beginchar ("Varied Segno", "varsegno"); save ht, wd, loopdist, loopangle; save thin, med, thick; - save bulbradius; + save bulbradius, center; + pair center; ht# = 8 staff_space#; wd# = 2.5 staff_space#; set_char_box (wd# / 2, wd# / 2, ht# / 2, ht# / 2); - %set_char_box (0, 0, ht# / 2, ht# / 2); + % set_char_box (0, 0, ht# / 2, ht# / 2); loopdist = 4/3 staff_space; loopangle = 35; thick = 1/2 staff_space; - med = 1/4 staff_space; + med = 1/4 staff_space; thin = 1/10 staff_space; x1 = staff_space; y1 = 13/4 staff_space; - penpos1 (med, 210); + penpos1 (med, 210); z2l = (0, 4 staff_space); penpos2 (med, 270 - loopangle); @@ -1180,20 +1220,26 @@ fet_beginchar ("Varied Segno", "varsegno"); y3 = y1 + 1/4 staff_space; penpos3 (med, 270 + loopangle); - pair center; center = (0, 2 staff_space); - z4 = (3/4 staff_space, 2 staff_space) rotatedabout (center, 180 - loopangle); - z5 = 2[z4,center]; - x9 = x4; y9 = y4 - 2 loopdist; - x10 = x5; y10 = y5 - 2 loopdist; - penpos4 (thick, 90 - loopangle); - penpos5 (thick, 90 - loopangle); - penpos9 (thick, 90 - loopangle); + z4 = (3/4 staff_space, 2 staff_space) + rotatedabout (center, 180 - loopangle); + z5 = 2[z4, center]; + x9 = x4; + y9 = y4 - 2 loopdist; + x10 = x5; + y10 = y5 - 2 loopdist; + + penpos4 (thick, 90 - loopangle); + penpos5 (thick, 90 - loopangle); + penpos9 (thick, 90 - loopangle); penpos10 (thick, 90 - loopangle); - z6 = (4/3 staff_space, 4/3 staff_space) rotatedabout (2/3 center, -loopangle); - x11 = x6; y11 = y6 - 2 loopdist; - penpos6 (thin, -loopangle); + z6 = (4/3 staff_space, 4/3 staff_space) + rotatedabout (2/3 center, -loopangle); + x11 = x6; + y11 = y6 - 2 loopdist; + + penpos6 (thin, -loopangle); penpos11 (thin, -loopangle); z7 = 1/3 center; @@ -1205,31 +1251,36 @@ fet_beginchar ("Varied Segno", "varsegno"); z12 = -center; penpos12 (thick, 270 - loopangle); - z1' = 4/3[z1l,z1r]; - bulbradius = length ( z1l - z1'); + z1' = 4/3[z1l, z1r]; + bulbradius = length (z1l - z1'); pickup pencircle scaled 2 bulbradius; - drawdot z1'; + + save se_dir, nw_dir; + pair se_dir, nw_dir; + se_dir := dir -loopangle; + nw_dir := dir (180 - loopangle); + + draw_bulb (-1, z1r, z1l, bulbradius, .8); penstroke z1e - .. z2e - .. z3e - .. z4e{dir (-loopangle)} - .. z5e{dir (-loopangle)} - .. z6e - .. z7e - .. z8e - .. z9e{dir (-loopangle)} - .. z10e{dir (-loopangle)} - .. z11e - .. {dir (180 - loopangle)}z12e; + .. z2e + .. z3e + ... {se_dir}z4e + -- z5e{se_dir} + ... z6e + ... z7e{nw_dir} + ... z8e + ... {se_dir}z9e + -- z10e{se_dir} + ... z11e + ... {nw_dir}z12e; addto currentpicture also currentpicture scaled -1; penlabels (1, 1', 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12); - %draw_staff (-2, 2, 0); + % draw_staff (-2, 2, 0); fet_endchar; - fet_beginchar ("Coda", "coda"); save stickout, thin, thick, codawidth, codaheight; @@ -1434,17 +1485,18 @@ enddef; fet_beginchar ("Arpeggio", "arpeggio"); + begingroup; save height, overshoot, width; - height# = staff_space#; - width# = 0.8 height#; - overshoot# = 0.25 staff_space#; + height# := staff_space#; + width# := 0.8 * height#; + overshoot# := 0.25 * staff_space#; define_pixels (height, overshoot, width); - set_char_box (0, width#, 0, height#); draw_arpeggio; penlabels (range 1 thru 9); draw_staff (-2, 2, 0.0); + endgroup; fet_endchar; @@ -1455,7 +1507,8 @@ fet_endchar; % fet_beginchar ("Trill_element", "trill_element"); - save height, overshoot; + begingroup; + save height, overshoot, width; height# = staff_space#; width# = 0.8 height#; overshoot# = 0.25 staff_space#; @@ -1467,6 +1520,7 @@ fet_beginchar ("Trill_element", "trill_element"); currentpicture := currentpicture shifted -(width / 2, height / 2); currentpicture := currentpicture rotated 90; currentpicture := currentpicture shifted (height / 2, width / 2); + endgroup; fet_endchar;