mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-11-29 14:18:49 +03:00
Clean up config names a bit
This commit is contained in:
parent
23a9306383
commit
50f994bd23
2 changed files with 5 additions and 8 deletions
|
@ -93,7 +93,7 @@ UserSettings::load(std::optional<QString> profile)
|
|||
sortByImportance_ = settings.value("user/sort_by_unread", true).toBool();
|
||||
readReceipts_ = settings.value("user/read_receipts", true).toBool();
|
||||
theme_ = settings.value("user/theme", defaultTheme_).toString();
|
||||
font_ = settings.value("user/font_family", "").toString();
|
||||
font_ = settings.value("user/font_family", "default").toString();
|
||||
avatarCircles_ = settings.value("user/avatar_circles", true).toBool();
|
||||
decryptSidebar_ = settings.value("user/decrypt_sidebar", true).toBool();
|
||||
privacyScreen_ = settings.value("user/privacy_screen", false).toBool();
|
||||
|
@ -101,7 +101,7 @@ UserSettings::load(std::optional<QString> profile)
|
|||
shareKeysWithTrustedUsers_ =
|
||||
settings.value("user/share_keys_with_trusted_users", true).toBool();
|
||||
mobileMode_ = settings.value("user/mobile_mode", false).toBool();
|
||||
emojiFont_ = settings.value("user/emoji_font_family", "Default").toString();
|
||||
emojiFont_ = settings.value("user/emoji_font_family", "default").toString();
|
||||
baseFontSize_ = settings.value("user/font_size", QFont().pointSizeF()).toDouble();
|
||||
auto tempPresence = settings.value("user/presence", "").toString().toStdString();
|
||||
auto presenceValue = QMetaEnum::fromType<Presence>().keyToValue(tempPresence.c_str());
|
||||
|
@ -343,7 +343,7 @@ UserSettings::setEmojiFontFamily(QString family)
|
|||
return;
|
||||
|
||||
if (family == tr("Default")) {
|
||||
emojiFont_ = "Default";
|
||||
emojiFont_ = "default";
|
||||
} else {
|
||||
emojiFont_ = family;
|
||||
}
|
||||
|
@ -737,10 +737,7 @@ UserSettingsPage::UserSettingsPage(QSharedPointer<UserSettings> settings, QWidge
|
|||
}
|
||||
|
||||
QString currentFont = settings_->font();
|
||||
if (currentFont == "Default") {
|
||||
fontSelectionCombo_->setCurrentIndex(
|
||||
fontSelectionCombo_->findText(tr(currentFont.toStdString().c_str())));
|
||||
} else {
|
||||
if (currentFont != "default" || currentFont != "") {
|
||||
fontSelectionCombo_->setCurrentIndex(fontSelectionCombo_->findText(currentFont));
|
||||
}
|
||||
|
||||
|
|
|
@ -214,7 +214,7 @@ main(int argc, char *argv[])
|
|||
|
||||
QFont font;
|
||||
QString userFontFamily = settings.lock()->font();
|
||||
if (!userFontFamily.isEmpty()) {
|
||||
if (!userFontFamily.isEmpty() && userFontFamily != "default") {
|
||||
font.setFamily(userFontFamily);
|
||||
}
|
||||
font.setPointSizeF(settings.lock()->fontSize());
|
||||
|
|
Loading…
Reference in a new issue