chord leading/trailing space from 1.3 score ignored upon import

• May 7, 2014 - 16:10
S4 - Minor

Windows 7, GIT commit: c20b96e

1) load attached score (created in 1.3) in both 1.3 and a 2.0 build

Result: the leading and trailing space added around the third note is missing in the 2.0 build

The code shows this is simply not implemented. leadingSpace and trailingSpace were formerly Chord properties, but now they are Segment properties. Unfortunately, at the time we read the Chord, the Segment does not yet exist, so there is no simple way to apply these properties immediately upon read.

I would propose we add a couple of fields to the Chord object to temporarily store these values on read, then transfer them to the Segment once it is created.

Attachment Size
leading.mscz 1.41 KB


I should add, though, that I'm not sure we actually *want* to do this.

I just went out of my way to strip away manual adjustments from chords in 1.3 scores on the (valid in many cases) assumption that these adjustments will probably no longer make sense. That's because many of these adjustments were just working around layout issues that have been fixed, and applying these adjustments to the new default positions would be counterproductive.

The same *may* be true of leading/trailing space. That is, some uses of leading/trailing space may be just working around layout issues in 1.3 that will no longer exist in 2.0. While there will no doubt be *some* of these adjustments done for other reasons that the user might want to preserve, that's equally true of the "offset" adjustments I am currently proposing stripping off (see #25390: Layout of 1.3 scores).

So far, after running a lot of scores through my code, I am not seeing obvious bad effects from continuing to ignore the leading/trailing space, *except* in the case of scores that used invisible notes with negative space around them to provide playback of ornaments. No doubt there are other cases as well. But a whole lot of scores look just fine with the leading/trailing space ignore, including "Reunion", which apparently contains half a dozen uses of leadingSpace.

If we ever add an option to preserve 1.3 manual adjustments, though, this should be included.