Swing - Piano Roll Editor - Incompatibility

• Sep 4, 2020 - 11:00
Reported version
3.5
Priority
P2 - Medium
Type
Functional
Frequency
Once
Severity
S3 - Major
Reproducibility
Always
Status
active
Regression
No
Workaround
Yes
Project

1) Open the attached score and see for yourself

OR

1) Create a new score

2) Enable Swing:

2.1)Right click anywhere, go to "Style -> Score -> Swing" and hit "eighth note" (so Swing is globally activated)
OR
2.2) Add a local "Swing" Text at the beginning of your score

3) Add some notes, preferably eighth notes so Swing applies correctly

4) Select those notes and right click. Open the Piano Roll Editor (PRE)

5) All of those notes should still be selected in the PRE. Transpose the grouped notes by dragging them up or down with your mouse and hit okay

Expected result: Swing should still apply to those notes
Actual result: Swing does not apply to the transposed group anymore

After some investigation in our community forum, some users managed to figure out as to why this may be:

If taking a look at the code, one can clearly see that there are empty "" tags written by the PRE which override the Swing operation. (I attached a screenshot of the code.)

Attachment Size
Swing - PRE - Incomp.mscz 11.62 KB
codemusescore.png 26.18 KB

Comments

The swing playback code deliberately skips notes with custom events attached - it doesn't analyze the content of those events. I think the fix here is to make sure we don't create the empty events in the first place.