X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=lily%2Fspacing-spanner.cc;h=be0cd01a450883c1d3bb3dbe6e6a3226f8780c49;hb=0387f04497978e37b335a8b99eec905499d6ad0f;hp=ba5d40e51879ffe7f5b7709c51cbfed96579ed41;hpb=6fef7b7a22004cccab9b133d7458fb100d47293a;p=lilypond.git diff --git a/lily/spacing-spanner.cc b/lily/spacing-spanner.cc index ba5d40e518..be0cd01a45 100644 --- a/lily/spacing-spanner.cc +++ b/lily/spacing-spanner.cc @@ -3,7 +3,7 @@ source file of the GNU LilyPond music typesetter - (c) 1999--2007 Han-Wen Nienhuys + (c) 1999--2008 Han-Wen Nienhuys */ #include "spacing-spanner.hh" @@ -405,8 +405,20 @@ Spacing_spanner::musical_column_spacing (Grob *me, Note that we don't actually pack things as tightly as possible: we don't allow the next column to begin before this one ends. */ - spring.set_distance (max (left_col->extent (left_col, X_AXIS)[RIGHT], - spring.min_distance ())); + /* FIXME: the else clause below is the "right" thing to do, + but we can't do it because of all the empty columns that the + ligature-engravers leave lying around. In that case, the extent of + the column is incorrect because it includes note-heads that aren't + there. We get around this by only including the column extent if + the left-hand column is "genuine". This is a dirty hack and it + should be fixed in the ligature-engravers. --jneem + */ + if (Paper_column::is_extraneous_column_from_ligature (left_col)) + spring.set_distance (spring.min_distance ()); + else + spring.set_distance (max (left_col->extent (left_col, X_AXIS)[RIGHT], + spring.min_distance ())); + spring.set_inverse_stretch_strength (1.0); }