]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/page-layout-problem.cc
Revert "Fix 1442."
[lilypond.git] / lily / page-layout-problem.cc
index c1cfeb0656bbdff88e9eb0c2b56cb4ba3e91de55..aaf86815dc2ea55540423c9f91cb3808974786d6 100644 (file)
@@ -319,10 +319,10 @@ Page_layout_problem::solve_rod_spring_problem (bool ragged)
       Real overflow = spacer.configuration_length (spacer.force ())
                      - page_height_;
       if (ragged && overflow < 1e-6)
-       warning (_ ("couldn't fit music on page: ragged-spacing was requested, but page was compressed"));
+       warning (_ ("cannot fit music on page: ragged-spacing was requested, but page was compressed"));
       else
        {
-         warning (_f ("couldn't fit music on page: overflow is %f",
+         warning (_f ("cannot fit music on page: overflow is %f",
                       overflow));
          warning (_ ("compressing music to fit"));
          vsize space_count = solution_.size ();
@@ -424,7 +424,8 @@ Page_layout_problem::find_system_offsets ()
                      loose_line_min_distances.clear ();
                    }
                  last_spaceable_line = staff;
-                 last_spaceable_line_translation = -solution_[spring_idx - 1];
+                 // Negative is down but the translation is relative to the whole page.
+                 last_spaceable_line_translation = -system_position + translation;
 
                  staff->translate_axis (translation, Y_AXIS);
                  found_spaceable_staff = true;
@@ -435,10 +436,6 @@ Page_layout_problem::find_system_offsets ()
                    loose_lines.push_back (last_spaceable_line);
 
                  if (staff_idx)
-                   // NOTE: the way we do distances between loose lines (and other lines too, actually)
-                   // is not the most accurate way possible: we only insert rods between adjacent
-                   // lines.  To be more accurate, we could insert rods between non-adjacent lines
-                   // using a scheme similar to the one in set_column_rods.
                    loose_line_min_distances.push_back (min_offsets[staff_idx-1] - min_offsets[staff_idx]);
                  else
                    {