SUMMARY The old developer setting "ForceGlCoreProfile=true" from KDeclarative triggers --- 8< --- auto format = QSurfaceFormat::defaultFormat(); if (s.forceGlCoreProfile()) { format.setVersion(3,2); format.setProfile(QSurfaceFormat::CoreProfile); } // [...] QSurfaceFormat::setDefaultFormat(format); --- 8< --- (see https://invent.kde.org/frameworks/kdeclarative/-/blob/master/src/quickaddons/qtquicksettings.cpp) whereas Kirigami seems at least for ShadowedRectangle to rely on newer openGL versions being supported in the shader code. STEPS TO REPRODUCE 1. Add this config entry to .config/kdeglobals --- 8< --- [QtQuickRendererSettings] ForceGlCoreProfile=true --- 8< --- 2. (Re)start systemsettings, open Colors, Plasma Style, App Style or any other config module using previews where selection is rendered with ShadowedRectangle OBSERVED RESULT Rectanlge is not painted, console log talks about shader not being compilable EXPECTED RESULT Rectangle painted I had this flag set from some old experiments with custom openGL content in Plasma widgets, and so far never had seen visual glitches. This popped up only in a recent month.
CCing initial contributor of ShadowedRectangle. There's also an issue with the QtQuick Software rendering backend, the rectangle doesn't render. The previews are empty here: QMLSCENE_DEVICE=softwarecontext kcmshell5 lookandfeel Though that's probably a separate issue.
The core profile shaders currently use version 450. You could try changing the #version directive to 320 in src/scenegraph/shaders/header_desktop_core.glsl. Though personally I think forcing the GL version like KDeclarative is doing here is wrong and it should default to whatever the highest version is that it can support. For reference, this was tested using qmlscene --core-profile which also forces core profile but doesn't force a version.
(In reply to Fabian Vogt from comment #1) > CCing initial contributor of ShadowedRectangle. > > There's also an issue with the QtQuick Software rendering backend, the > rectangle doesn't render. The previews are empty here: > QMLSCENE_DEVICE=softwarecontext kcmshell5 lookandfeel > Though that's probably a separate issue. This seems to be unrelated and an issue with the preview rendering. As far as I can tell the actual rectangle is rendered correctly (it's responsible for rendering the highlight), it just doesn't have any contents.
(In reply to Arjen Hiemstra from comment #3) > (In reply to Fabian Vogt from comment #1) > > CCing initial contributor of ShadowedRectangle. > > > > There's also an issue with the QtQuick Software rendering backend, the > > rectangle doesn't render. The previews are empty here: > > QMLSCENE_DEVICE=softwarecontext kcmshell5 lookandfeel > > Though that's probably a separate issue. > > This seems to be unrelated and an issue with the preview rendering. As far > as I can tell the actual rectangle is rendered correctly (it's responsible > for rendering the highlight), it just doesn't have any contents. After replacing ShadowedRectangle with just Rectangle it appears fine. By making PaintedRectangleItem::paint return early to not make it draw anything, the previews appear correctly, so it appears like it's drawing on top of the previews.