Merge pull request #2107 from Cacodemon345/patch-56
qt: Set font after loading translations
This commit is contained in:
@@ -141,11 +141,7 @@ int main(int argc, char* argv[]) {
|
|||||||
#endif
|
#endif
|
||||||
QApplication app(argc, argv);
|
QApplication app(argc, argv);
|
||||||
QLocale::setDefault(QLocale::C);
|
QLocale::setDefault(QLocale::C);
|
||||||
#ifdef Q_OS_WINDOWS
|
|
||||||
auto font_name = QObject::tr("FONT_NAME");
|
|
||||||
auto font_size = QObject::tr("FONT_SIZE");
|
|
||||||
QApplication::setFont(QFont(font_name, font_size.toInt()));
|
|
||||||
#endif
|
|
||||||
qt_set_sequence_auto_mnemonic(false);
|
qt_set_sequence_auto_mnemonic(false);
|
||||||
Q_INIT_RESOURCE(qt_resources);
|
Q_INIT_RESOURCE(qt_resources);
|
||||||
Q_INIT_RESOURCE(qt_translations);
|
Q_INIT_RESOURCE(qt_translations);
|
||||||
@@ -165,6 +161,11 @@ int main(int argc, char* argv[]) {
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
ProgSettings::loadTranslators(&app);
|
ProgSettings::loadTranslators(&app);
|
||||||
|
#ifdef Q_OS_WINDOWS
|
||||||
|
auto font_name = QObject::tr("FONT_NAME");
|
||||||
|
auto font_size = QObject::tr("FONT_SIZE");
|
||||||
|
QApplication::setFont(QFont(font_name, font_size.toInt()));
|
||||||
|
#endif
|
||||||
if (! pc_init_modules()) {
|
if (! pc_init_modules()) {
|
||||||
ui_msgbox_header(MBX_FATAL, (void*)IDS_2120, (void*)IDS_2056);
|
ui_msgbox_header(MBX_FATAL, (void*)IDS_2120, (void*)IDS_2056);
|
||||||
return 6;
|
return 6;
|
||||||
|
Reference in New Issue
Block a user