X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=mf%2Ffeta-scripts.mf;h=e27974b955040ccea88c9a0f77aa88149aaf6c4e;hb=2bbacb364aa29041af9cbbbd32cfad2e8e387cb3;hp=8496fd7c650977b03780e952b1b2e694d7e97384;hpb=ac58053330907c37ec08f790b0272cfee1536a64;p=lilypond.git diff --git a/mf/feta-scripts.mf b/mf/feta-scripts.mf index 8496fd7c65..e27974b955 100644 --- a/mf/feta-scripts.mf +++ b/mf/feta-scripts.mf @@ -1,14 +1,14 @@ % 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--2015 Han-Wen Nienhuys % Jan Nieuwenhuizen % % -% LilyPond is free software: you can redistribute it and/or modify +% The LilyPond font is free software: you can redistribute it and/or modify % it under the terms of the GNU General Public License as published by % the Free Software Foundation, either version 3 of the License, or -% (at your option) any later version. +% (at your option) any later version, or under the SIL Open Font License. % % LilyPond is distributed in the hope that it will be useful, % but WITHOUT ANY WARRANTY; without even the implied warranty of @@ -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; @@ -1217,24 +1255,28 @@ fet_beginchar ("Varied Segno", "varsegno"); 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; + ... {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); fet_endchar; @@ -1442,17 +1484,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); + draw_staff_if_debugging (-2, 2); + endgroup; fet_endchar; @@ -1463,7 +1506,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#; @@ -1475,6 +1519,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; @@ -1691,6 +1736,59 @@ fet_beginchar ("Straight caesura", "caesura.straight"); fet_endchar; +% A tick character to use instead of a comma or caesura as a breath mark. +% Very common in vocal notation. + +fet_beginchar ("Tick mark", "tickmark"); + save end_rad, bot_rad, pat, x_centre, x_extent; + path pat; + + end_rad = linethickness / 2; + bot_rad = linethickness; + + x_centre# = 0.6 staff_space#; + x_extent# = 1.7 staff_space#; + + define_pixels (x_centre, x_extent); + + pickup pencircle scaled end_rad; + + lft x1 = -x_centre; + y1 = 0.8 staff_space; + + x2 = 0; + y2l = 0; + + top rt z3 = (x_extent - x_centre, x_extent); + + x4 = lft x1; + y4 = staff_space; + + penpos2 (0.4 staff_space, 90); + penpos3 (end_rad, angle(z4 - z3) + 90); + penpos1 (end_rad, angle(z2 - z1) + 90); + + pat = z1r + .. top z1 + .. z1l{z2 - z1} + .. {z2 - (z1 + (0.3 staff_space,0))}z2l + (-bot_rad, bot_rad) + .. z2l + .. z2l + (bot_rad, bot_rad){z3 - (0.6 staff_space, 0) - z2} + .. {z3 - z4}z3r + .. rt z3 + .. {z4 - z3}z3l + .. {z2 - (z3 - (0.6 staff_space, 0))}rt z2r + .. {z1 - z2}lft z2r{z1 - z2} + .. cycle; + fill pat; + + set_char_box (x_centre#, x_extent# - x_centre#, 0, x_extent#); + + penlabels (1, 2, 3); + labels (4); +fet_endchar; + + fet_beginchar ("snap pizzicato (Bartok pizzicato)", "snappizzicato"); save height, width, thickness, superness;