From bcb64a231fa6ba45a7f42edd3733f70e9a19cfdc Mon Sep 17 00:00:00 2001 From: Janek Bevendorff Date: Thu, 21 May 2020 02:58:52 +0200 Subject: [PATCH] Use Segoe UI font on Windows. Qt uses "MS Shell Dlg 2" as the default font, which resolves to Tahoma and not Segoe UI, which is the actual Windows 10 default font. See QTBUG-58610 --- src/core/Bootstrap.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/core/Bootstrap.cpp b/src/core/Bootstrap.cpp index 797bd4e546..cdf5e334a0 100644 --- a/src/core/Bootstrap.cpp +++ b/src/core/Bootstrap.cpp @@ -73,7 +73,6 @@ namespace Bootstrap setupSearchPaths(); applyEarlyQNetworkAccessManagerWorkaround(); - Translator::installTranslators(); } /** @@ -84,6 +83,15 @@ namespace Bootstrap void bootstrapApplication() { bootstrap(); + Translator::installTranslators(); + +#ifdef Q_OS_WIN + // Qt on Windows uses "MS Shell Dlg 2" as the default font for many widgets, which resolves + // to Tahoma 8pt, whereas the correct font would be "Segoe UI" 9pt. + // Apparently, some widgets are already using the correct font. Thanks, MuseScore for this neat fix! + QApplication::setFont(QApplication::font("QMessageBox")); +#endif + MessageBox::initializeButtonDefs(); #ifdef Q_OS_MACOS