]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/staff-spacing.cc
Run grand-replace for 2009.
[lilypond.git] / lily / staff-spacing.cc
index 72b997514c9738e23613aaf7f88a1380bd1ecc70..3587f70c6354c0b1d89e0df627478f26377305dd 100644 (file)
@@ -3,7 +3,7 @@
 
   source file of the GNU LilyPond music typesetter
 
-  (c) 2001--2007  Han-Wen Nienhuys <hanwen@xs4all.nl>
+  (c) 2001--2009  Han-Wen Nienhuys <hanwen@xs4all.nl>
 */
 
 #include "staff-spacing.hh"
@@ -108,7 +108,7 @@ Staff_spacing::next_notes_correction (Grob *me,
 }
 
 /* We calculate three things here: the ideal distance, the minimum distance
-   (which is the distance at which collisions will occure) and the "fixed"
+   (which is the distance at which collisions will occur) and the "fixed"
    distance, which is the distance at which things start to look really bad.
    We arrange things so that the fixed distance will be attained when the
    line is compressed with a force of 1.0 */
@@ -196,14 +196,14 @@ Staff_spacing::get_spacing (Grob *me, Grob *right_col)
   ideal += correction;
 
   Spring ret (ideal, min_dist);
-  ret.set_inverse_stretch_strength (ideal - fixed);
+  ret.set_inverse_stretch_strength (max (0.0, ideal - fixed));
   return ret;
 }
 
 ADD_INTERFACE (Staff_spacing,
-              "This object calculates spacing details from a "
-              " breakable symbol (left) to another object. For example, it takes care "
-              " of  optical spacing from  a bar lines to a note.",
+              "This object calculates spacing details from a breakable"
+              " symbol (left) to another object.  For example, it takes care"
+              " of optical spacing from a bar line to a note.",
 
               /* properties */
               "stem-spacing-correction "