summaryrefslogtreecommitdiff
path: root/mf
diff options
context:
space:
mode:
authorDan Eble <nine.fierce.ballads@gmail.com>2014-11-29 09:06:55 -0500
committerDan Eble <nine.fierce.ballads@gmail.com>2014-12-08 19:32:50 -0500
commite3c51326b986bb56f068f70d9c5e999c5fcfc36d (patch)
tree92feb3a0fa06a6153e03d572bf95edd5a3d9a201 /mf
parent145389636e81237d560aba4d04abcb89fa60cd9c (diff)
Issue 4211: Add an alternative quarter rest shaped like a mirrored Z.
For example, see G. Ricordi's edition of Don Pasquale by G. Donizetti, Atto Primo, Introduzione, measure 4, bass staff: http://javanese.imslp.info/files/imglnks/usimg/1/1a/IMSLP141736-PMLP58429-Donizetti_-_Don_Pasquale_VS_Sibley.1802.16329.pdf Many other quarter rests in the same score look slightly different. This new rest is designed to fit in with the other rests in the Feta font rather than to reproduce a particular historical look exactly.
Diffstat (limited to 'mf')
-rw-r--r--mf/feta-rests.mf66
1 files changed, 66 insertions, 0 deletions
diff --git a/mf/feta-rests.mf b/mf/feta-rests.mf
index 0a9d7ea43d..c531a70e89 100644
--- a/mf/feta-rests.mf
+++ b/mf/feta-rests.mf
@@ -378,6 +378,72 @@ fet_beginchar ("Classical quarter rest", "2classical");
fet_endchar;
+fet_beginchar ("Z-shaped quarter rest", "2z");
+ save ycenter;
+ save pat, bulb, rest;
+ path pat, bulb, rest;
+ show_labels := 0;
+
+ set_char_box (0, 1.125 staff_space#,
+ 0.5 staff_space# + bulb_diam# / 2,
+ 0.5 staff_space# + bulb_diam# / 2);
+
+ % The brushes on other rests taper from thin to thick,
+ % but because this rest has a bulb on both ends, use
+ % a constant thickness somewhere in between.
+ slash_thickness := (7 thin + 3 thick) / 10;
+
+ x1 = 0 + hround 0.5 slash_thickness;
+ y1 = -(d - vround 0.5 slash_thickness);
+ x2 = w - hround 0.5 slash_thickness;
+ y2 = h - vround 0.5 slash_thickness;
+
+ penpos1 (slash_thickness, angle(z2 - z1) - 90);
+ penpos2 (slash_thickness, angle(z2 - z1) - 90);
+
+ z9 = z2 + 0.5 slash_thickness * dir (angle (z2 - z1));
+ z12 = z1 + 0.5 slash_thickness * dir (angle (z1 - z2));
+ y9 := vround y9;
+
+ x1l := hround x1l;
+ x1r := hround x1r;
+ x1 := .5 [x1l, x1r];
+
+ x2l := hround x2l;
+ x2r := hround x2r;
+ x2 := .5 [x2l, x2r];
+
+ if show_labels = 1:
+ penlabels (1, 2);
+ labels (9, 12);
+ fi;
+
+ pat = z1l
+ -- z2l
+ .. z9
+ .. z2r
+ -- z1r
+ .. cycle;
+ bulb = draw_rest_bulb (0.5 staff_space, y2r, pat, 1.0, show_labels);
+
+ rest = z12
+ .. bulb rotatedaround ((0.5 w, 0), 180)
+ -- z2r
+ .. z9
+ .. bulb
+ -- z1l
+ .. cycle;
+
+ if show_labels = 0:
+ rest := rest xscaled -1 shifted (w, 0);
+ fi;
+
+ fill rest;
+
+ draw_staff_if_debugging (-2, 2);
+fet_endchar;
+
+
fet_beginchar ("8th rest", "3");
draw_eighth_rest (1);
fet_endchar;