Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
#include <QLocalServer>
#include <QLoggingCategory>
#include <QProcessEnvironment>
#include <QQuickStyle>
#include <QQuickWindow>
#include <QSystemTrayIcon>
#include <csignal>
Expand Down Expand Up @@ -299,9 +300,9 @@ int main(int argc, char* argv[]) {

KColorSchemeManager::instance();

QApplication::setStyle(QStringLiteral("breeze"));
if (qEnvironmentVariableIsEmpty("QT_QUICK_CONTROLS_STYLE")) {
QQuickStyle::setStyle(QStringLiteral("org.kde.desktop"));
QIcon::setFallbackThemeName(QStringLiteral("breeze"));
if (qEnvironmentVariableIsEmpty("QT_QUICK_CONTROLS_STYLE") && QQuickStyle::name().isEmpty()) {
QQuickStyle::setStyle(QStringLiteral("org.kde.desktop"));
Comment on lines +304 to +305
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if (qEnvironmentVariableIsEmpty("QT_QUICK_CONTROLS_STYLE") && QQuickStyle::name().isEmpty()) {
QQuickStyle::setStyle(QStringLiteral("org.kde.desktop"));
if (qEnvironmentVariableIsEmpty("QT_QUICK_CONTROLS_STYLE")) {
QQuickStyle::setStyle(QStringLiteral("org.kde.desktop"));

org.kde.desktop allows to follow the QStyle in a QML app. Don't use any of the default QQuickStyle as they are all quite bad

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I applied this and Breeze style is used on Gnome.

Copy link
Author

@Lunix-420 Lunix-420 Nov 11, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tested this change. It seems to fix the icon issue, but it also causes most UI elements (~90%) to ignore the qt6ct theme again. Interestingly, very few elements, like text field backgrounds or the active part of the slider rails, still respect the theme apparently.

With this change:
before

Before:
after

}

// Parsing command line options
Expand Down
Loading