]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/spacing-loose-columns.cc
Run `make grand-replace'.
[lilypond.git] / lily / spacing-loose-columns.cc
index aa91b4fcf280e1bbe6d862e5a96d765bf53c8fad..5aeb357b37bc739a874e88aa9c5af27ffd8312d3 100644 (file)
@@ -3,7 +3,7 @@
 
   source file of the GNU LilyPond music typesetter
 
-  (c) 2005--2007 Han-Wen Nienhuys <hanwen@xs4all.nl>
+  (c) 2005--2008 Han-Wen Nienhuys <hanwen@xs4all.nl>
 */
 
 #include "system.hh"
@@ -100,7 +100,7 @@ set_loose_columns (System *which, Column_x_positions const *posns)
 
       vector<Real> clique_spacing;
       clique_spacing.push_back (0.0);
-      for (vsize j = 1; j < clique.size () - 1; j ++)
+      for (vsize j = 1; j + 1 < clique.size (); j ++)
        {
          Grob *clique_col = clique[j];
 
@@ -119,23 +119,19 @@ set_loose_columns (System *which, Column_x_positions const *posns)
          else
            programming_error ("Column without spacing object");
 
-         bool expand_only = false;
          Real base_note_space = 0.0;
 
          if (Paper_column::is_musical (next_col)
              && Paper_column::is_musical (loose_col))
-           base_note_space = Spacing_spanner::note_spacing (spacing, loose_col, next_col, 
-                                                            &options, &expand_only);
+           base_note_space = Spacing_spanner::note_spacing (spacing, loose_col, next_col,
+                                                            &options);
          else
            {
-             Real fixed, space;
-             
-             Spacing_spanner::standard_breakable_column_spacing (spacing, 
-                                                                 loose_col, next_col,
-                                                                 &fixed, &space,
-                                                                 &options);
-
-             base_note_space = space;
+             Spring spring = Spacing_spanner::standard_breakable_column_spacing (spacing,
+                                                                                 loose_col, next_col,
+                                                                                 &options);
+
+             base_note_space = spring.distance ();
            }
 
          base_note_space = max (base_note_space,