ContextView: QFontDatabase::families is not static in Qt 5

This commit is contained in:
Jonas Kvinge 2023-05-05 17:46:02 +02:00
parent b90d284b08
commit 97e6b17f96
1 changed files with 4 additions and 0 deletions

View File

@ -331,7 +331,11 @@ void ContextView::AddActions() {
void ContextView::ReloadSettings() {
QString default_font;
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
if (QFontDatabase::families().contains(ContextSettingsPage::kDefaultFontFamily)) {
#else
if (QFontDatabase().families().contains(ContextSettingsPage::kDefaultFontFamily)) {
#endif
default_font = ContextSettingsPage::kDefaultFontFamily;
}
else {