]> git.donarmstrong.com Git - lilypond.git/commitdiff
Fix 759.
authorJoe Neeman <joeneeman@gmail.com>
Fri, 29 May 2009 23:58:29 +0000 (16:58 -0700)
committerJoe Neeman <joeneeman@gmail.com>
Sat, 6 Jun 2009 05:55:54 +0000 (08:55 +0300)
Only include live staves in refpoint-staff-extent.

lily/align-interface.cc
lily/system.cc

index d69930c3aa5ec715ab7bf2a42020506c966fab4b..cbc9443fc7ce4f1491492ecb745f2c1e26241717 100644 (file)
@@ -249,8 +249,10 @@ Align_interface::get_extents_aligned_translates (Grob *me,
        }
     }
 
+  // So far, we've computed the translates for all the non-empty elements.
+  // Here, we set the translates for the empty elements: an empty element
+  // gets the same translation as the last non-empty element before it.
   vector<Real> all_translates;
-
   if (!translates.empty ())
     {
       Real w = translates[0];
index 6f363970ff75af4d78a6baecc347970830d9bb12..e0964482fcf91373fb73aaf07aebac53844d7ce3 100644 (file)
@@ -419,7 +419,8 @@ System::get_paper_system ()
   Interval staff_refpoints;
   extract_grob_set (this, "spaceable-staves", staves);
   for (vsize i = 0; i < staves.size (); i++)
-    staff_refpoints.add_point (staves[i]->relative_coordinate (this, Y_AXIS));
+    if (staves[i]->is_live ())
+      staff_refpoints.add_point (staves[i]->relative_coordinate (this, Y_AXIS));
 
   pl->set_property ("staff-refpoint-extent", ly_interval2scm (staff_refpoints));
   pl->set_property ("system-grob", this->self_scm ());