Corruption on pasting a range with a truncated note that requires a tie
Reported version
2.2
Priority
P1 - High
Type
Functional
Severity
S2 - Critical
Status
closed
Regression
No
Workaround
No
Project
Windows 7/10. MS 2.2.1, 51b8386
- Open attached score. Click on the first note in voice 1, then shift click on the 6th note in voice 1.
- Copy and paste the selection into measure 2.
Expected result:
Actual result:
Attachment | Size |
---|---|
paste_partial_measure.mscz | 10.69 KB |
Comments
See #4867: Rests in measures should be grouped according to time signature. It's just another case of the same basic issue that when creating rests in compound meter, we don't do so according to the usual convention. Usually people report this about note input, but it's the same for copy/paste.
In reply to See #4867: 6/8 rest grouping… by Marc Sabatella
Sure? I tried note input with the above example and got the expected result shown above
In reply to Sure? I tried note input… by Jojo-Schmitz
The picture for the actual results should end up reporting a corrupted measure since there are more than 3 beats in the measure. Testing in 2.2.1 results in no corruption reported.
@Marc, I may be wrong, but I understood the issue as being the note in the second voice is copied for its full duration, even though the selection is only the first 3 compound beats. @geetar would have to clarify.
Regards
EDIT: Mike is indeed correct. I missed that. That would probably be the issue.
Ah, sorry, I wasn't thinking about the second voice - I only noticed the issue with the order of the rests in the first.
FWIW, when doing a range selection involving multiple voices, there is always a question of how to handle cases where one voice overlaps the boundary. We do normally try to deal with this one way or another, but the "expected" semantics might vary (eg, one valid result would also be to copy the full dotted half but without the extra rests, another would be to note to copy the dotted half at all). I'd consider any solution that didn't produce corruption to be satisfactory here.
In reply to Ah, sorry, I wasn't thinking… by Marc Sabatella
I agree. As long a the user knows what to expect any result is fine with me. Coping only the first voice, since no complete second voice note is selected, makes sense to me. Normal user actions should never result in a corruption and corruptions need to be reported.
Edit: To support my logic that voice 2 should be ignored, select the first six notes in voice 1 and press R.
Figured it out! MuseScore copies the incomplete note's duration without any problem, but breaks on notating it if it can't be represented by a single "picture" (i.e. needs a tie). In the case when a tie is needed, it draws the single "picture" with the shortest value that is longer than the actual note-value, but keeps the actual value for playback and rest calculations. See attached score for more detailed description.
Nice investigation! I'm updating the title to reflect this understanding. It's hardly self-explanatory, but hopefully descriptive enough to be useful.
FWIW, as corruptions go, this one is relatively harmless, simply deleting the rests appears to do the right thing.
Since the appearance of the chord in voice 2 does not match its actual duration, deleting the rests does not solve the underlying problem. It only makes the measure appear to be correct. A better workaround would be to change the duration of the chord. Removing the dot and adding it back appears to do the right thing.
I use the word "chord" because duration applies to the chord rather than the note.
Good point. I actually did that first and verified it really worked, then also tried deleting the rests and incorrectly jumped to the conclusion that worked too.
See fix #272403: Corruption on pasting a range with a truncated note that requires a tie #3688.
In reply to See fix #272403: Corruption… by mattmcclinch
@mattmcclinch I'm curious what you decided to do with the note in another voice that does not span the selection area.
The note was already being truncated to fit into the gap created for it, but its duration was not achievable without a tie, and of course it was being displayed as the wrong duration type. I decided to split up the note and tie the pieces together, as in geetar's original expected result. So I corrected the issue at the paste end. I did not attempt to answer the question of whether that note should have been copied at all.
In reply to The note was already being… by mattmcclinch
As I previous stated, as long as there is no corruption and we know what to expect any solution is acceptable. Now we know what to look for in testing.
Fixed in branch master, commit ab6830fbd8
fix #272403: Corruption on pasting a range with a truncated note that requires a tie
Fixed in branch master, commit 4c6f877ca6
Merge pull request #3688 from mattmcclinch/272403-truncate-chordrest
fix #272403: Corruption on pasting a range with a truncated note that requires a tie
See https://github.com/musescore/MuseScore/pull/3688
Automatically closed -- issue fixed for 2 weeks with no activity.