]> Nutra Git (v2) - gamesguru/feather.git/commitdiff
windows: fix dark mode
authortobtoht <tob@featherwallet.org>
Sun, 22 Jan 2023 22:19:23 +0000 (23:19 +0100)
committertobtoht <tob@featherwallet.org>
Sun, 22 Jan 2023 22:19:39 +0000 (23:19 +0100)
src/main.cpp

index a84e0e0491b60af9c187642b3b729cbabbf324bf..d3e2bcfffa95ffb079e448cbaea38ec0bfcf77b3 100644 (file)
@@ -37,6 +37,12 @@ if (AttachConsole(ATTACH_PARENT_PROCESS)) {
 }
 #endif
 
+// #TODO: Fix Windows dark mode handling Qt 6.5 beta1
+// darkmode=2 (default) causes some text to become unreadable
+#if defined(Q_OS_WIN)
+    qputenv("QT_QPA_PLATFORM", "windows:darkmode=1");
+#endif
+
     QStringList argv_;
     for(int i = 0; i != argc; i++){
         argv_ << QString::fromStdString(argv[i]);