Inspector "Font Face" for Text element doesn't work for text elements containing multiple fonts

• Jan 15, 2019 - 04:42
Reported version
3.0
Type
Functional
Frequency
Once
Severity
S4 - Minor
Reproducibility
Always
Status
by design
Regression
No
Workaround
No
Project

If I have a text element containing only one font, then the "Font Face" combobox in the Inspector seems to work correctly, as it correctly represents the one font of the text element, and changing that value in the dropdown box to some other font will immediately cause the text element to update its font to that new value.

However, the functionality doesn't work for a text element with multiple fonts, such as 3-font-title.mscz, which contains text starting as MuseJazz, then FreeSerif, then Cantarell. If I click on the text element, I see inspector's Font face says it is FreeSerif:

Screenshot at 2019-01-14 23-30-08.png

Changing that dropbox to some other font (such as Dejavu sans) doesn't have an actual effect on the text's font:

Screenshot at 2019-01-14 23-31-32.png

It only seems to have an actual effect if the text element was freshly-created or recently-reset, and only affects the initial text block starting from the start of the text element that hasn't been changed since last reset, up to when there is a new font in the text element.

It seems that the the desired behavior should be that the inspector is maybe reflect that there is multiple fonts in the block, by either displaying font as blank, or greyed out, or says something like "Multiple Fonts". And that changing it should be disabled if there are multiple fonts...or if allowed, then change all fonts to the newly selected font.


Comments

Sure it does - it's the setting for the element as a whole. Changing that does not and should not affect custom formatting overrides you apply to specific characters within the text via the toolbar. To me this is all exactly as it should be - I don't see a bug here. If you want to remove the custom formatting, there is a button for that.

Status active by design

Well that does make sense, in which case this isn't a bug as I wrote it...but I still notice inconsistent behavior around this...for instance if I start with unformatted plain text, and then change only the middle portion of unformatted text to a different font, then when I change the font face in the inspector, only the text to the left of the unformatted text gets updated. Now I suppose the reason why that happens is because doing the font change in the middle resulted in creating a separate text block for the text to the right of the middle portion...and even though that portion was unformatted, it doesn't get updated when changing the font face in inspector...only the text to the left of the custom formatted selection gets changed.

And there is inconsisten behavior when changing the font fact for a tempo text. If I create a tempo text and insert text to the left of the special notehead, then changing the font face in inspector only affects the text to the left of the note head, not the originally unformatted text to the right of the notehead. While if I didn't add any extra text before the notehead, the rest of the text to the right of the notehead will change formatting when I change the font face in inspector.

Why the code only changes the first text block of same font as in the inspector font face seems to suggest the code is only looking for the first text block that matches the font face. So I guess that should really be a separate issue report along the lines of have inspector formatting apply to all non-formatted text blocks, not just the initial unformatted one.

But I'll close this because that is a separate concern.