diff options
author | Han-Wen Nienhuys <hanwen@xs4all.nl> | 2007-01-08 09:17:13 +0100 |
---|---|---|
committer | Han-Wen Nienhuys <hanwen@xs4all.nl> | 2007-01-08 09:17:13 +0100 |
commit | 9c92b259689913faf1cb4f4aa4695899719fc6a0 (patch) | |
tree | 480dcaf7d8a53b7cc4853bb1f54c6b758e858524 | |
parent | 5e816a4ee513135e33d2b067a9b0ecf98de8a7e0 (diff) |
Guesstimate stem end position for bar-stem optical correction.
-rw-r--r-- | lily/staff-spacing.cc | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/lily/staff-spacing.cc b/lily/staff-spacing.cc index c7023db3aa..65c565617c 100644 --- a/lily/staff-spacing.cc +++ b/lily/staff-spacing.cc @@ -87,8 +87,15 @@ Staff_spacing::next_note_correction (Grob *me, Direction d = get_grob_direction (stem); if (Stem::is_normal_stem (stem) && d == DOWN) { - Real stem_start = Stem::head_positions (stem) [DOWN]; - Real stem_end = Stem::stem_end_position (stem); + + /* + can't look at stem-end-position, since that triggers + beam slope computations. + */ + Real stem_start = Stem::head_positions (stem) [d]; + Real stem_end = stem_start + + d * robust_scm2double (stem->get_property ("length"), 7); + Interval stem_posns (min (stem_start, stem_end), max (stem_end, stem_start)); |