diff --git a/qt/src/EmuApplication.cpp b/qt/src/EmuApplication.cpp index 406cc0df..cacb1d3b 100644 --- a/qt/src/EmuApplication.cpp +++ b/qt/src/EmuApplication.cpp @@ -611,11 +611,6 @@ QString EmuApplication::iconPrefix() const char *whiteicons = ":/icons/whiteicons/"; const char *blackicons = ":/icons/blackicons/"; - if (QGuiApplication::styleHints()->colorScheme() == Qt::ColorScheme::Dark) - return whiteicons; - if (QGuiApplication::styleHints()->colorScheme() == Qt::ColorScheme::Light) - return blackicons; - if (QGuiApplication::palette().color(QPalette::WindowText).lightness() > QGuiApplication::palette().color(QPalette::Window).lightness()) return whiteicons; diff --git a/qt/src/FoldersPanel.cpp b/qt/src/FoldersPanel.cpp index 1bb092ac..8e3f3c0a 100644 --- a/qt/src/FoldersPanel.cpp +++ b/qt/src/FoldersPanel.cpp @@ -26,7 +26,7 @@ void FoldersPanel::connectEntry(QComboBox *combo, QLineEdit *lineEdit, QPushButt QObject::connect(combo, &QComboBox::activated, [=](int index) { *location = index; - refreshEntry(combo, lineEdit, browse, location, folder); + this->refreshEntry(combo, lineEdit, browse, location, folder); app->updateSettings(); }); diff --git a/qt/src/main.cpp b/qt/src/main.cpp index c726ba5b..b3b68139 100644 --- a/qt/src/main.cpp +++ b/qt/src/main.cpp @@ -28,8 +28,35 @@ int main(int argc, char *argv[]) if (emu.qtapp->platformName() == "windows") { - if (emu.qtapp->style()->name() == "windows11") - emu.qtapp->setStyle("windowsvista"); + emu.qtapp->setStyle("fusion"); + + const QColor darkGray(53, 53, 53); + const QColor gray(128, 128, 128); + const QColor black(25, 25, 25); + const QColor blue(198, 238, 255); + const QColor blue2(0, 88, 208); + + QPalette darkPalette; + darkPalette.setColor(QPalette::Window, darkGray); + darkPalette.setColor(QPalette::WindowText, Qt::white); + darkPalette.setColor(QPalette::Base, black); + darkPalette.setColor(QPalette::AlternateBase, darkGray); + darkPalette.setColor(QPalette::ToolTipBase, blue2); + darkPalette.setColor(QPalette::ToolTipText, Qt::white); + darkPalette.setColor(QPalette::Text, Qt::white); + darkPalette.setColor(QPalette::Button, darkGray); + darkPalette.setColor(QPalette::ButtonText, Qt::white); + darkPalette.setColor(QPalette::Link, blue); + darkPalette.setColor(QPalette::Highlight, blue2); + darkPalette.setColor(QPalette::HighlightedText, Qt::white); + darkPalette.setColor(QPalette::PlaceholderText, QColor(Qt::white).darker()); + + darkPalette.setColor(QPalette::Active, QPalette::Button, darkGray); + darkPalette.setColor(QPalette::Disabled, QPalette::ButtonText, gray); + darkPalette.setColor(QPalette::Disabled, QPalette::WindowText, gray); + darkPalette.setColor(QPalette::Disabled, QPalette::Text, gray); + darkPalette.setColor(QPalette::Disabled, QPalette::Light, darkGray); + emu.qtapp->setPalette(darkPalette); } #ifndef _WIN32