Skip to content

Commit

Permalink
Fix #23508 : A custom style set as default style in Prefs. is not used
Browse files Browse the repository at this point in the history
Fixed by loading the preferences before loading the custom style

Also makes sure the custom style is complete, by initializing it with the built-in defulat style before loading.
  • Loading branch information
Maurizio M. Gavioli authored and Maurizio M. Gavioli committed Nov 15, 2013
1 parent d7c7838 commit 15b8de4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions mscore/musescore.cpp
Expand Up @@ -4783,11 +4783,11 @@ int main(int argc, char* av[])
qDebug() << " Virtual size:" << screen->virtualSize().width() << "x" << screen->virtualSize().height();
}

preferences.readDefaultStyle();

if (!useFactorySettings)
preferences.read();

preferences.readDefaultStyle();

if (converterDpi == 0)
converterDpi = preferences.pngResolution;

Expand Down
2 changes: 1 addition & 1 deletion mscore/preferences.cpp
Expand Up @@ -1450,7 +1450,7 @@ bool Preferences::readDefaultStyle()
{
if (defaultStyleFile.isEmpty())
return false;
MStyle* style = new MStyle;
MStyle* style = new MStyle(*MScore::defaultStyle());
QFile f(defaultStyleFile);
if (!f.open(QIODevice::ReadOnly))
return false;
Expand Down

0 comments on commit 15b8de4

Please sign in to comment.