Set style for windows

This commit is contained in:
Tobias Fella 2021-04-18 16:55:03 +02:00 committed by Bart De Vries
parent 55e13ab059
commit 4b32d7699a
1 changed files with 15 additions and 0 deletions

View File

@ -45,6 +45,21 @@ int main(int argc, char *argv[])
QQuickStyle::setStyle(QStringLiteral("Material"));
#else
QApplication app(argc, argv);
if(qEnvironmentVariableIsEmpty("QT_QUICK_CONTROLS_STYLE")) {
QQuickStyle::setStyle(QStringLiteral("org.kde.desktop"));
}
#endif
#ifdef Q_OS_WINDOWS
if (AttachConsole(ATTACH_PARENT_PROCESS)) {
freopen("CONOUT$", "w", stdout);
freopen("CONOUT$", "w", stderr);
}
QApplication::setStyle(QStringLiteral("breeze"));
auto font = app.font();
font.setPointSize(10);
app.setFont(font);
#endif
QCoreApplication::setOrganizationName(QStringLiteral("KDE"));