]> git.donarmstrong.com Git - lilypond.git/commitdiff
Issue 4065: Don't rescale \layout in \score markup when already scaled
authorDavid Kastrup <dak@gnu.org>
Tue, 12 Aug 2014 18:29:22 +0000 (20:29 +0200)
committerDavid Kastrup <dak@gnu.org>
Tue, 12 Aug 2014 20:26:57 +0000 (22:26 +0200)
This change modifies the fix for issue 677 to avoid scaling problems
when employing $(ly:grob-layout grob) in the \layout of a score markup.

lily/score-scheme.cc

index fc6985e701f218ee9d13ce7fa582cc498dfad9e7..913cdc14c083d994784f8811f7f3e03cb257940d 100644 (file)
@@ -130,7 +130,12 @@ LY_DEFINE (ly_score_embedded_format, "ly:score-embedded-format",
   if (!score_def)
     return SCM_BOOL_F;
 
-  score_def = scale_output_def (score_def, output_scale (od));
+  /* Don't rescale if the layout has already been scaled */
+  if (to_boolean (score_def->c_variable ("cloned")))
+    score_def = score_def->clone ();
+  else
+    score_def = scale_output_def (score_def, output_scale (od));
+
   score_def->parent_ = od;
 
   SCM context = ly_run_translator (sc->get_music (), score_def->unprotect ());