Second Voice can end up broken
There's some conditions under which the second (and probably all other than first) voice can end up broken.
I don't have exact steps to reproduce, it usually involves some note entry, copy/cut/pasting and deleting.
I will post more, if I can find out,
A example is attached
Attachment | Size |
---|---|
second_voice_broken.mscz | 1.68 KB |
Comments
Okay, I can provide some steps
It seems to occur when there are notes at the beginning and/or the end of a selection which aren't fully covered by the selection. Hmm... can't explain better, I've attached some screen shots and two files
How to reproduce:
1) enter notes like in step1.jpg or take before.mscz
2) make the selection shown in step2.jpg (do it exactly like there, three "blue" and three "green" notes)
3) copy
4) select the rest of measure three
5) paste. should look like step3.jpg now
6) select the last note of the first voice (the quarter note) and press the "c"-key several times
7) which results in step4.jpg or after.mscz
The copy or the paste function should contain a check, if a note's duration extends the selection, and if so, it should be given a shorter duration, so that it fits in.
In this example, the quarter note in the first voice should in the clipboard only be a dotted eighth note.
If this is too complicated, there could be a warning instead, that the selection is inconsistent.
Marking as critical since it results in bars with corrupt timing
(Confirmed using MuseScore 1.0 and r. 4104 nightly build, Windows 7)
Also see this .
Here's a patch. Notes are cut so measures aren't broken anymore
please test
Can someone review this code please?
I adapted the patch and commited in the branch. I let the issue open, since the patch is not applied in trunk yet.
Is this still reproducible?
I think the 'before' score maybe corrupt (see the treble stave of bar 5).
When I try the steps, the fourth semiquaver is also pasted.
Using MuseScore 2.0 Nightly Build (bd8b902) - Mac 10.7.5.
Looks like this is fixed (tested by following the steps from scratch rather than using the corrupted scores)
ee5bbfb
Windows 7
Automatically closed -- issue fixed for 2 weeks with no activity.