X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=lily%2Fnote-collision.cc;h=7ac359b36f8a52f5576ebde0bf1817459d19cf5b;hb=5b4b0d6e9a197e8f9eb085b7c2ad78b8be3e5cfc;hp=894f16071fa5d5e76e0d2101ffe4a897e47c13b3;hpb=76309628e3f692deed6d0b23b1752fb1dd1cc57e;p=lilypond.git diff --git a/lily/note-collision.cc b/lily/note-collision.cc index 894f16071f..7ac359b36f 100644 --- a/lily/note-collision.cc +++ b/lily/note-collision.cc @@ -3,7 +3,7 @@ source file of the GNU LilyPond music typesetter - (c) 1997--2007 Han-Wen Nienhuys + (c) 1997--2008 Han-Wen Nienhuys */ #include "note-collision.hh" @@ -161,6 +161,13 @@ check_meshing_chords (Grob *me, Real shift_amount = 1; bool touch = (ups[0] >= dps.back ()); + /* As a special case, if the topmost part of the downstem chord is a second, + the top note of which is the same pitch as the lowest upstem note, they + shouldn't count as touching. + */ + if (dps.back () == ups[0] && dps.size () > 1 && dps[dps.size() - 2] == ups[0] - 1) + touch = false; + if (touch) shift_amount *= -1;