Notes not transposed when copied by notehead
1. Create a new score with a flute and a Bb clarinet
2. Insert a G quarter note into the flute staff, and a C quarter note into the clarinet staff
3. Click on the *notehead* of the C quarter note in the clarinet staff and hit copy
4. Click on the *notehead* of the G quarter note in the flute staff and hit paste
Expected behavior:
There should be a Bb (transposed from the clarinet's C) in the flute staff, in the same way that it does when multiple notes are selected
Actual behavior:
There is a C in the flute staff.
Platform:
r2908, GNU/Linux
Comments
Just to be clear - is concert pitch enabled or disabled for this??
Assume a transposing score, not a score in concert pitch (i.e. concert pitch disabled).
Other weird things happen too - the pitch plays back incorrectly. BTW, at step 1, I entered Bb as the key for the score, so the flute shows two flats, the clarinet none. The G on the flute part is second-to-bottom line; the C in clarinet is second-to-top space. When I copied the C from clarinet to flute, what displayed was C *below* the staff, but what plays back is *Bb* (middle line). If I then hit down arrow, the note now renders as Cb on the second-to-top space (and plays as the A a whole step below).
Hello, has there been any progress on this issue?
It seems we can fix this by adding a call to Note::setTpcFromPitch() here:
https://github.com/musescore/MuseScore/blob/77e980d95d0aa40735a17eceb19…
The note being added has the right pitch, since that's recorded in concert pitch, so this call does the right thing in this case. I don't know if this gets hit in other situations too (we're dropping a Note onto another Note), but it seems to me this should be fairly safe. We could make it safer by only doing this if the source and destination staves differ. We could also do the actual calculations, checking concert pitch state, finding the transposition interval, transposing the tpc. But I guess I'd like to know if this code is likely to be hit in other contexts as well.
https://github.com/musescore/MuseScore/pull/2306
Fixed in branch master, commit d28b36d0f9
fix #5098: tpc corruption on copy of note
Fixed in branch master, commit 50d6898a12
Merge pull request #2306 from MarcSabatella/5098-copy-note-transpose
fix #5098: tpc corruption on copy of note
Fixed in branch 2.0.3, commit c76410240a
fix #5098: tpc corruption on copy of note
Automatically closed -- issue fixed for 2 weeks with no activity.