Setting lyrics style changes glissando text

• May 7, 2020 - 19:18
Reported version
3.4
Type
Functional
Frequency
Few
Severity
S4 - Minor
Reproducibility
Always
Status
closed
Regression
No
Workaround
No
Project

This is an odd one, but has bitten me a few times lately.

  1. Open the attached score.
  2. Note that the glissando texts have been changed from the default.
  3. Select one of the lyrics.
  4. In the Inspector, hit the "S" next to the font name.
  5. The text of the glassandi is changed to the default ("gliss').
Attachment Size
Glissando_Phenomenon3.mscx 11.62 KB

Comments

Note for other developers: generally, when bugs like this happen, what this means internally is the property wasn't changed correctly in the first place. Typically it means we are neglecting to set the UNSTYLED flag. Often these bugs happen when the property is first changed, and the result is that the change doesn't even save. In this case, it does save, but I think the flag isn't being set on the read. You can also tell this by clicking the glissando and looking in the Inspector - you'll see the reset button is grayed out, indicating that it is still marked STYLED. Ifx is probably in Glissando::read() - when processing the "text" tag, instead of just setting _text, we need to actually set the property, using something like readProperty() and/or setPropertyFlags().

I don't have a correct build environment set up right now or I'd probably have been able to fix it in about the same amount of time it took me to write the above :-).

Here's perhaps another aspect of the same phenomenon:
1. Open the same attached score.
2. Select the first lyric. Set it to a dramatically different font and press "S" to set the style.
3. Note that none of the other lyrics changed their font.
4. Now select the second lyric. Set it to a second dramatically different font and press the "S" to set the style.
5. Note that only the first lyric changed its font.

Well, no, the reason the set as style button isn't having an effect is that those lyrics all deviate from the default style already. You'd have to first reset the lyrics to default style in order for subsequent style changes to take effect.

Status PR created fixed

Fixed in branch 3.x, commit e4861a77ed

_fix #316096, fix #305093: custom gliss text reverts to default "gliss"

Resolves: https://musescore.org/en/node/316096
Resolves: https://musescore.org/en/node/305093

Issue is that customized gliss text reverts back to the default "gliss".
In all 3.x versions, this happened after saving, reloading,
then making any style change.
In 3.6, this happens immediately on the save/reload.
Cause is that the property was never makred unstyled on read.
Fix is to change the plain setting of "text" with
a call to readProperty() on Pid::GLISS_TEXT.

Fix version
3.6.2