Lines at start of time signature range deleted on change of previous time signature

• Apr 12, 2019 - 14:43
Reported version
3.0
Priority
P1 - High
Type
Functional
Frequency
Once
Severity
S3 - Major
Reproducibility
Randomly
Status
closed
Regression
No
Workaround
No
Project

First of all, I'm not entirely sure how to guarantee a reproduction but this is how it's happened to me.

I have a section (B) with dynamic markers in the second voice in 6/8 time. If I put 6/8 in a section which comes earlier than the B section and then remove the new time signature all the dynamic markers placed in the second voice (green) will disappear.

Generally, the issue seems to be with change of time signatures and I also noticed how only the second voice is affected by this issue. My B section repeats and I am unsure if the issue affects all repetitions or if it's just the next section that uses a second voice (green).


Comments

Status needs info active
Type Performance Functional

I can definitely see the problem in 3.1-beta also. Now someone can see what's happening and possibly fix it.

Title Dynamic markings disappearing Lines at start of time signature range deleted on change of previous time signature
Priority P1 - High

Seems to affect all lines (not dynamics) at the start of a time signature range, any time you change the previous time signature. So, a change from 3/4 to 4/4 somewhere in a score, any line that starts right at that boundary is lost if you do anything to change the 3/4 - delete it, change it to 2/4, etc.

In reply to by Marc Sabatella

I'd like to stress that this is only once variation of the problem. As I mentioned I've had entire sections lose their markings countless times and not realized right away, as it's clearly a problem that affects the score no matter of there you are currently editing. I'm not able to exactly pinpoint the issue but it seems to be related to time and/or key signatures .

I would say if you have seen entire sections lose markings, that's an entirely different an unrelated issue that only happens to have a similar symptom. So if you ever see it happen again and can find steps to reproduce that problem, please file a separate report for that.

One thing that certainly is known - changing time signatures means rewriting measures, and that means losing elements attached to specific measures, like breaks, markings attached to barlines, repeat markings, etc. That's not really a bug per se but the inevitable result of the fact that your old measures no longer exist.

This behavior was introduced when #279593 was fixed (commit d2f4f5c). The function rewriteMeasures() in edit.cpp changed the line:
auto spanners = s->spannerMap().findContained(tick1, tick2);
to use the spannerMap->findOverlapping() function instead.

This change includes spanners in the last measure - the one with the next time signature - in the list of spanners to be deleted.

I'll have a PR ready soon.

https://musescore.org/en/node/279593
https://github.com/musescore/MuseScore/commit/d2f4f5c

Fix version
3.6.2