From: Han-Wen Nienhuys Date: Wed, 7 Sep 2005 23:28:34 +0000 (+0000) Subject: (get_configuration): also avoid dots for non-space X-Git-Tag: release/2.7.10~18 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=2b547a5a7d782c3e6cb421b22e53eb481c65b35d;p=lilypond.git (get_configuration): also avoid dots for non-space situations. --- diff --git a/ChangeLog b/ChangeLog index 5500f1c87e..2694dc1c19 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2005-09-08 Han-Wen Nienhuys + + * lily/tie.cc (get_configuration): also avoid dots for non-space + situations. + 2005-09-07 Jan Nieuwenhuizen * Documentation/user/instrument-notation.itely: Bugfix. diff --git a/lily/tie.cc b/lily/tie.cc index 8a105688be..6e62f424f0 100644 --- a/lily/tie.cc +++ b/lily/tie.cc @@ -261,29 +261,30 @@ Tie::get_configuration (Grob *me_grob, Grob *common, Avoid dot */ Grob *left_dot = unsmob_grob (me->get_bound (LEFT)->get_object ("dot")); - if (left_dot && in_space) + int dot_pos = int (Staff_symbol_referencer::get_position (left_dot)); + if (left_dot + && (staff_position == dot_pos + || staff_position + dir == dot_pos)) { - if (staff_position == Staff_symbol_referencer::get_position (left_dot)) - { - staff_position += dir; - in_space = false; + staff_position += dir; + in_space = !in_space; - if (skylines) - { - Real y = staff_space * 0.5 * staff_position; - attachments = get_skyline_attachment (*skylines, y); - attachments.widen (-gap); - Bezier b = slur_shape (attachments.length(), - details.height_limit_, - details.ratio_); - Offset middle = b.curve_point (0.5); - Offset edge = b.curve_point (0.0); - dy = fabs (middle[Y_AXIS] - edge[Y_AXIS]); - fits_in_space = - (dy < 0.6 * staff_space); - } + if (skylines) + { + Real y = staff_space * 0.5 * staff_position; + attachments = get_skyline_attachment (*skylines, y); + attachments.widen (-gap); + Bezier b = slur_shape (attachments.length(), + details.height_limit_, + details.ratio_); + Offset middle = b.curve_point (0.5); + Offset edge = b.curve_point (0.0); + dy = fabs (middle[Y_AXIS] - edge[Y_AXIS]); + fits_in_space = + (dy < 0.6 * staff_space); } } + /* Avoid flag. */