Incorrect spacing of grace notes with accidentals

• Apr 14, 2014 - 05:58
Type
Functional
Severity
S4 - Minor
Status
closed
Project

Windows 7, GIT commit: ef4c692

1) new score, flute, C major
2) measure 2, add quarter note Bb
3) drag grace note to this note

Result: too much space before note

bgd.png

I plan to fix this along with #25341: Chord with accidental and offset downstem note too close to barline and #25342: too much space after time signature if first chord has accidental; it's all the same chunk of code, and testing my fixes for that code is I discovered this problem.

Attachment Size
bgd.png 1.3 KB

Comments

Seems not as related as I think. As far as I can tell, the code in Measure::layoutX() is assigning the correct amount of leading space. It may the code in Chord::layoutPitched() that is miscalculating something. One clue is that the effect actually gets worse depending on what else is going on in the chord. For example, if there are two grace notes and they both have accidentals, there is too much room in front of each. Also, the effect isn't limited to the beginning of the bar:

grace2.png

Attachment Size
grace2.png 2.95 KB