diff --git a/CMakeLists.txt b/CMakeLists.txt --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -14,7 +14,7 @@ cmake_minimum_required (VERSION 2.8.12 FATAL_ERROR) set(QT_MIN_VERSION "5.4.0") -set(KF5_MIN_VERSION "5.18.0") +set(KF5_MIN_VERSION "5.25.0") set(PLASMA_MIN_VERSION "5.4.0") find_package(ECM ${KF5_MIN_VERSION} REQUIRED NO_MODULE) diff --git a/src/Gui/KSMainWindow.cpp b/src/Gui/KSMainWindow.cpp --- a/src/Gui/KSMainWindow.cpp +++ b/src/Gui/KSMainWindow.cpp @@ -39,6 +39,7 @@ #include #include #include +#include #include "SettingsDialog/SettingsDialog.h" #include "ExportMenu.h" @@ -67,7 +68,7 @@ // credits for this goes to Thomas Lübking #ifdef XCB_FOUND - if (qApp->platformName() == QStringLiteral("xcb")) { + if (KWindowSystem::isPlatformX11()) { // create a window if we haven't already. note that the QWidget constructor // should already have done this diff --git a/src/SpectacleCore.cpp b/src/SpectacleCore.cpp --- a/src/SpectacleCore.cpp +++ b/src/SpectacleCore.cpp @@ -62,7 +62,7 @@ } #ifdef XCB_FOUND - if (qApp->platformName() == QStringLiteral("xcb")) { + if (KWindowSystem::isPlatformX11()) { mImageGrabber = new X11ImageGrabber; } #endif