-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
let dynamic/tempo symbols auto-resize to surrounding text #9395
Conversation
add comments to explain magic numbers
1fe292c
to
934372c
Compare
Backport of musescore#9395, plus fixing an mtest
Backport of musescore#9395, plus fixing an mtest
The backport (#9387) also shows a failing mtest (due to the changed default for dynamics size, easily fixed) and as such reveals that this particular mtest is missing from master, although the test file does exist (https://github.com/musescore/MuseScore/tree/master/src/importexport/musicxml/tests/data/testMeasureStyleSlash_ref.mscx). |
Backport of musescore#9395, plus fixing mtests
Backport of musescore#9395, plus fixing an mtest
Backport of musescore#9395, plus fixing an mtest
Backport of musescore#9395, plus fixing mtests
@@ -962,10 +962,12 @@ mu::draw::Font TextFragment::font(const TextBase* t) const | |||
if (format.fontFamily() == "ScoreText") { | |||
if (t->parent() && t->isDynamic()) { | |||
family = t->score()->scoreFont()->fontByName(t->score()->styleSt(Sid::MusicalSymbolFont))->family(); | |||
m = t->score()->styleV(Sid::dynamicsSymbolFontSize).toReal() * t->mag(); | |||
// to keep desired size ratio (based on 20pt symbol size to 10pt text size) | |||
m *= 2; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So you want it twice as big as the (new) default for dynamicsFontSize
.
Why not twice as big as the actual dynamicsFontSize
?
Wouzldn't that render this setting (in the EditStyle dialog) completyle useless?
} else if (t->parent() && t->isTempoText()) { | ||
family = t->score()->styleSt(Sid::MusicalTextFont); | ||
m = t->score()->styleV(Sid::tempoSymbolFontSize).toReal(); | ||
// to keep desired size ratio (based on 20pt symbol size to 12pt text size) | ||
m *= 5.0 / 3.0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Similar question here.
I got the 2.x import to work properly (finally):
I.e. by using the MusicalTextFont setting, and converting that into the corresponding MusyicalSymbolFont!
As the MusicalTextFont deterimines the look of Dynamics in MuseScore 1, 2 and 3, this to me is the way to go. See #9427 |
Backport of musescore#9395, plus fixing mtests and use the `MusicalTextFont` setting, converted into the corresponding `MusicalSymbolFont`
after musescore#9359 and musescore#9395 and as discussed there. Also after musescore#12354
after musescore#9359 and musescore#9395 and as discussed there. Also after musescore#12354
Follow up to resolve some of the comments brought up in #9359 after it was merged.
Instead of having separate font sizes for dynamic/tempo symbols, the symbols will automatically resize given the surrounding context text sizes.
One other change: default dynamics font size is now 10pt instead of 11pt.