Simple tool to help using (almost) any font in chord symbols
I have an idea.
The biggest obstacle in using different fonts in chord symbols seems to be that most fonts do not have a sharp sign or a flat sign. This results in a fallback character appearing instead, with horrible spacing (kerning?). Because of this, only a couple of specifically designed fonts are usable.
I believe the issue could be somewhat resolved by making it possible to use sharps and flats from another font, separate from the rest of the symbols. This feature could be in the Chord Symbols menu, where one can find the extension and modifier scaling and offset.
I don't know whether this is simple to implement or not, but I'm quite confident it would help us multiply the amount of usable chord fonts.
Comments
Just use the fonts provided, FreeSerif, Edwin, MuseJazz Text...
In reply to Just use the fonts provided,… by Jojo-Schmitz
I do. I just would love to have more options. There are also others on the forums trying to use other fonts.
From reading other conversations on the forums I came to understand that the problem is that there are no proper flat signs in most fonts. And this is likely not going to change because font makers are not very interested in their fonts being used in a music notation software. The ideal solution to getting more options for chords is of course someone making great fonts that do have all the necessary signs, but im not very optimistic about that.
I have about 200 fonts. Ten of them work in chords.
About a hundred don't work just because they dont have a flat sign.
I think that fonts are an important part of making beautiful sheet music, and chord symbols is an area where musescore has somewhat limited options.
I attached an image of the working fonts used in a variety of chord types - in my opinion there is room for improvement.
In reply to I do. I just would love to… by fransfelix
A while back (and with MuseScore 1.x IIRC) I used a custom chords.xml to compensate for this, not sure whether that is still helpful?
In reply to A while back I used a custom… by Jojo-Schmitz
Granted, you can make anything work with custom xml files.
I've fiddled with them before and managed to make Averias fonts work on chords, but that was a lot of work. Back then that was the only option because there were no other tools for scaling and ofsetting extensions and modifiers. These tools are awesome an now it seems that the only big obstacle is the flat sign.
This got me thinking that maybe its not actually that big of a hurdle to make a custom xml file that just fixes the flat sign. But then again you have to tweak the file and go back and forth figuring out what font to use for the flats and sharps.
I also researched more into google fonts. It seems that although maybe one in 30 fonts has flats and shaprs, the sheer volume of fonts available means that there are dozens more that can be used as chord fonts without custom xml.
In reply to I do. I just would love to… by fransfelix
To me the obvious solution is to use a font editor like FonrForge to simply add the missing symbols. No need for a special solution just for accidentals or just for chord symbols or just for MuseScore for that matter - it's the same solution one would use to add any missing symbol to any font for any purpose.
In reply to To me the obvious solution… by Marc Sabatella
The big difference is though that adding such a symbol to the font requires both technical knowhow and a font license that allowed for such changes + the additional downside of nobody else seeing the effect unless you also distribute the modified font file (which again is a licensing pickle).
Having the option to either choose whether the "real flat/sharp" substitution should happen and/or combining it with the font choice for it caters to a way broader audience with less incompatibilities.
In reply to The big difference is though… by jeetee
True - so for someday it might be nice to have something implemented specifically to solve this problem (I'm not sure, but it might have already happened for post-MuseScore-4 as part of the GSoC project.
But meanwhile, the font editor will get the job done today :-)
After working on this for a couple of days I think I have the best solutions for now.
A) There are surprisingly many fonts that work as is. I've attached a preview of the ones I could find. These are all from Google Fonts.
B) Making a custom xml file. This seems like a lot of work at first, but you actually only have to separate the symbols you want to change, like this:
font family="Edwin"
sym code="0x266d" name="b"/
sym code="0x266e" name="natural"/
sym code="0x266f" name="#"/
/font
font family="Edwin" class="modifier"
sym code="0x266d" name="sb"/
sym code="0x266f" name="s#"/
/font
However, it is important that this is added in the end of Part I, because everything after you write family=Edwin will be in Edwin. Naturally you can also pick accidentals form another font if Edwin's symbols don't look good.
If there are more non-functioning symbols, you can just add more. This xml can also be used with any font.
You can also just modify the font if its easier for you.
In reply to After working on this for a… by fransfelix
By the way - some of the fonts have bad looking diminshed chords, and this is because "Greek small letter omicron" is being used and some fonts dont have that. Does anyone know why regular "o" isn't being used?
In reply to By the way - some of the… by fransfelix
the regular "o" is used, Just not in Jazz style
See https://musescore.org/en/handbook/3/chord-symbols#chord-symbol-syntax
In reply to the regular "o" is used,… by Jojo-Schmitz
I just checked the chords_std.xml that came with newest version of musescore.
There is
sym code="0x03bf" name="circle"
which corresponds to U+03BF. That is not regular o.
In reply to I just checked the chords… by fransfelix
That file is not used by default though? Anyway, to me the o looks like an o, in Standard and Custom style using that chords_std.xml
Maybe that chords_std.xml should better use ° "0x00B0"?
In reply to That file is not used by… by Jojo-Schmitz
As far as I know, ti is the file used by default. When you select "standard", that's the file name appearing next to it, greyed out.
The greek symbol looks exactly like o.
I think it should definately be either regular o or 0x00B0, whichever looks better.
In reply to That file is not used by… by Jojo-Schmitz
According to the handbook,
"Diminished: dim, ° (entered with lowercase letter o, shows as ° if using the Jazz style, as o otherwise)"
In reply to According to the handbook, … by fransfelix
And as said, it does look like an o (lowercase letter O) to me. But maybe in Edwin/FreeSerif the omicron looks identical, but not in some other fonts?
Actually that indeed seems to be the case. For now I've added that to the handbook, so it is no longer a bug but a documented feature ;-)
No idea why the omicron has been chosen. @Marc Sabatella?
In reply to And as said, it does look… by Jojo-Schmitz
I had forgotten that we did this, but it looks like I added it as part of https://github.com/musescore/MuseScore/pull/5246. The circle definition was present before in case someone else wanted to create a custom definition that used it, but we never actually used it ourselves. The definition used a Greek letter because it was the only standard Unicode codepoint I could find that seemed remotely appropriate. That is, in some font at least, it looked less like an "o" and more like a circle. The letter "o" is often more oval, with thicker sides compared to the top, etc.
In reply to I had forgotten that we did… by Marc Sabatella
Why not the °, °, available on many keyboards?
In reply to Why not the °ree; by Jojo-Schmitz
Both definitions are present in the jazz XML file. But in the pop/rock world, it's pretty uncommon to see that, so chords_std does not use it.
In reply to Both definitions are present… by Marc Sabatella
Ok, then why not a simple lower case o?
In reply to Ok, that why not a simple… by Jojo-Schmitz
It was, for many years. As mentioned, it appears I changed it a couple of years ago but frankly don't recall why. Probably someone somewhere had said it should be rounder.
In reply to It was, for many years. As… by Marc Sabatella
Which, al least in Edwin, it isn't, looks exactly the same to me.
Time to revert that change?
In reply to Which, al least in Edwin, it… by Jojo-Schmitz
Lots of this was re-done for MuseScore 4+ anyhow as part of GSoC. So I'm not sure it applies at all. If it causes a problem, then it could indeed be reverted for MuseScore 4.
In reply to Lots of this was re-done for… by Marc Sabatella
Maybe for 3.x?
In reply to Lots of this was re-done for… by Marc Sabatella
That
<sym code="0x03bf" name="circle"/>
is in chgords_std.xml since at least 2.0 Beta 2, 582ae98, to "fix tests & handling of 1.X scores". So basically ever since that file exists.Would changing that to
<sym code="0x006f" name="circle"/><!-- Latin small letter o-->
fix the issue? Which makes sort of sense, as<sym code="0x00f8" name="oslash"/>
really is " Latin small letter o with slash".Well, omicron makes (or made) some sense too, as
<sym code="0x0394" name="triangle"/>
is "Greek capital letter delta"...Pretty strange: the "0" does not turn into an "ø", but stays a "0" ?!
Edit, I was just being dumb, "F0" turns into "Fø", but "Fm0" stays "Fm0"
Dumb question: is an Fm0 and an F0 the same thing? They do sound and realize identical in 3.6.2 (but not in a later 3.x??)
In reply to That <sym code="0x03bf" name… by Jojo-Schmitz
Really, the more "correct" fix would be to find a more suitable circle in Unicode and set the sym definition to use that, but then also remove the place where the circle is actually used - the code I added more recently that I referenced above. Here are the relevant lines:
https://github.com/musescore/MuseScore/pull/5246/files#diff-34e52808df8…
The point of doing it that way would be to allow someone who wanted an actual circle someday to be able to get it easily, as the sym definition would already be in place. As far I can remember recall, that is probably why had planted that sym definition there all those years ago even though it was never used until recently. But maybe there was some other reason connected to the other changes made in that PR.
As for doing any of those "3.x", that to me depends entirely on what 3.x is and how much testing it might get. As far as I know it's still not a thing, and if it were to be a thing, I'd still favor making it be a 3.6.3, with only the half-dozen or so most critical fixes and least risky fixes. To me this would not qualify. If there is in addition / instead something I'd consider more of a 3.7 (e.g., the PR you've been assembling) with many more fixes and a ton more testing, then I don't see a problem with it.
As for Fm0, it is not really a thing, except for a couple of people here who said they had seen it somewhere and wanted MuseScore to support it by treating it as an alternate way of writing a half-diminished chord. I think maybe Ashwat may have added something for this during the pre-GSoC "warmup" phase? That would have been post 3.6.2 if so. In 3.6.2, Fm0 is just Fm in terms of playback, as the 0 is seen as just a meaningless number (which is why it doesn't render as half-diminished either).
In reply to Really, the more "correct"… by Marc Sabatella
Hmm, but with ø being called "Latin small letter o with slash"", I think a plain "Latin small letter o" is most suitable here, at least should match the font's design, so both should match in their look, and better than a bpossibly not available omicon, then taken from somefall back font with an entirely different look.
And yes, I mean 3.7, that big PR, certainly not 3.6.3
In reply to Hmm, but with ø being called… by Jojo-Schmitz
True. Unless of course we also found a more suitable oslash, and/or perhaps used the actual SmuFL and made sure the fallback worked.
In reply to True. Unless of course we… by Marc Sabatella
That would mean to use a Musical Text Font (like Leland Text) rather than a 'normal' Text font (like Edwin)
There is
<sym>csymHalfDiminished</sym>
and<sym>csymDiminished</sym>
.And also
<sym>csymMajorSeventh</sym>
for a triangle.These seem missing or at least not looking jazzy al all, for MuseJazz (fallback to Petaluma should work there though, instead it and Gonville and Emmentaler seem to fallback to Bravura there)
In reply to That wouzld mean to use a… by Jojo-Schmitz
MuseJazz Text predates SMuFL by quite a bit and I'm not sure it was ever properly updated - perhaps because older scores may have depended on the old layout? I know there is work going on right now to augment it (no pun intended) some for MuseScore 4. Would be good to see if there are other SMuFL discrepancies.
In reply to After working on this for a… by fransfelix
Your xml does render a diminished chord using lower case o, e.g. entered as "Fmo" as "Fmcircle", as it is lacking that
<sym code="0x03bf" name="circle"/>
And I think you might want to move double flat and double sharp into the Edwin section too? Esp. those are missing from many fonts as far as I know. Maybe that "omicron" thing too (rather than changing it to a plain Latin small o)?
I don't quite understand whjat your additions for "smaj" and "mmaj" are about, mind to explain?
In reply to Your xml dooes render a… by Jojo-Schmitz
Whoops!
Indeed, if a font doesn't have sharps and flats it surely doesn't have doubles.
As a sidenote, I experimented a little and noticed that there is a triangle symbol "White Up-Pointing Triangle"(0x25B3) that (in my opinion) looks better than current "Greek Capital Letter Delta" (0x0394).
0x25B3 seems to work well in Edwin, Bravura, MuseJazz Text, MScore Text, Free Sans and Free Serif.
I wonder if there is some spesific reason why "Greek Capital Letter Delta" was chosen?
In reply to Whoops! Indeed, if a font… by fransfelix
I guess that fonts having that 0x25b3 are rarer than those that have 0x0394?
In reply to I guess that fonts having… by Jojo-Schmitz
Seems reasonable.
In reply to Seems reasonable. by fransfelix
How about the attached then?
In reply to How about the attached then? by Jojo-Schmitz
Theres a problem at line 38
In reply to Theres a problem at line 38 by fransfelix
Yes, sorry, try this
In reply to Yes, try this by Jojo-Schmitz
Works like a charm!
In reply to Works like a charm! by fransfelix
So I'll add it to my PR #9000, to the 3.x branch
Remains to be seen whether and in what form this is usfefull for master too (and so for MuseScore 4)