https://bugs.kde.org/show_bug.cgi?id=357893
--- Comment #5 from RJVB <rjvber...@gmail.com> --- Below is an extract of the local patch I'm using for respecting the default style. I didn't implement the use of Fusion myself (that patch is from yesterday when I hadn't yet thought of Fusion :)) I wouldn't have thought of using Fusion before Breeze (Fusion should always be present) but that's up to you to decide. If you give me a heads-up when you're done I'll check with the native Mac theme. It works better with KDE than it did under KDE4 but it looks certain elements (the play control buttons in the monitor view for instance) tend to get messed up. diff --git src/mainwindow.cpp src/mainwindow.cpp index 8f20c3a..aa7f966 100644 --- src/mainwindow.cpp +++ src/mainwindow.cpp @@ -124,6 +124,15 @@ QMap <QString,QImage> MainWindow::m_lumacache; return a.first < b.first; }*/ +// determine the the default KDE style as defined BY THE USER +// (as opposed to whatever style KDE considers default) +static QString defaultStyle(const char *fallback=Q_NULLPTR) +{ + KSharedConfigPtr kdeGlobals = KSharedConfig::openConfig(QStringLiteral("kdeglobals"), KConfig::NoGlobals); + KConfigGroup cg(kdeGlobals, "KDE"); + return cg.readEntry("widgetStyle", fallback); +} + MainWindow::MainWindow(const QString &MltPath, const QUrl &Url, const QString & clipsToLoad, QWidget *parent) : KXmlGuiWindow(parent), m_timelineArea(NULL), @@ -3401,7 +3410,11 @@ void MainWindow::slotChangeStyle(QAction *a) void MainWindow::doChangeStyle() { - QApplication::setStyle(QStyleFactory::create(KdenliveSettings::widgetstyle())); + QString newStyle = KdenliveSettings::widgetstyle(); + if (newStyle.isEmpty() || newStyle == QStringLiteral("Default")) { + newStyle = defaultStyle("Breeze"); + } + QApplication::setStyle(QStyleFactory::create(newStyle)); // Changing widget style resets color theme, so update color theme again ThemeManager::instance()->slotChangePalette(); } -- You are receiving this mail because: You are watching all bug changes.