]> git.donarmstrong.com Git - lilypond.git/commitdiff
Issue 3876: Fix shape of G clefs
authorWerner Lemberg <wl@gnu.org>
Thu, 6 Mar 2014 06:19:49 +0000 (07:19 +0100)
committerWerner Lemberg <wl@gnu.org>
Fri, 14 Mar 2014 14:39:27 +0000 (15:39 +0100)
This patch simplifies the code for the double G clefs; it also fixes the
incorrect test of the `double_shift' parameter that caused the non-double
G clefs being drawn twice.

Recent FontForge warnings like

  Internal Error (overlap) in clefs.G: Intersection failed!

or the ugly shape with a straight line instead of a curve in the left part
of the G clef are now gone: Drawing the shape twice triggered a bunch of
FontForge bugs.

mf/feta-clefs.mf

index d96f5f399dbdcd28e24cb9109431dd0babfc498f..3c762d6ee45a387b14115ff56ff847527b4696a4 100644 (file)
@@ -556,29 +556,9 @@ def draw_gclef (expr reduction, double_shift, extra_width) =
 
        fill bulb;
 
-       if double_shift <> 1:
-
-               % transform helper points
-               for n := 106, 110, 111, 112, 121:
-                       forsuffixes e := l,,r:
-                               z[n+100]e = z[n]e shifted (double_shift * reduced_ss, 0);
-                       endfor
-               endfor
-               for n := 110, 111:
-                       forsuffixes e := l,,r:
-                               z[n+100]'e = z[n]'e shifted (double_shift * reduced_ss, 0);
-                       endfor
-               endfor
-
-               fill swirl shifted (double_shift * reduced_ss, 0);
-               penstroke z221e
-                         .. z210e{down_}
-                         .. z210'e
-                         .. z206e
-                         .. z211'e
-                         .. z211e{dir (-95 + corr_angle)}
-                         .. z212e{dir (bot_angle_)};
-               fill bulb shifted (double_shift * reduced_ss, 0);
+       if double_shift <> 0:
+               addto currentpicture also
+                 currentpicture shifted (double_shift * reduced_ss, 0);
        fi;
 
        penlabels (range 101 thru 121);