From 1b1018e687031166ecdcfa17a073cceada5b8100 Mon Sep 17 00:00:00 2001 From: Filip Fila Date: Fri, 1 May 2020 23:49:26 +0200 Subject: [PATCH] [Plasmoid Heading] Draw the heading only when there is an SVG in the theme Summary: We're the only theme with the appropriate heading svgs that make the headers and footers look as they should. All the other themes fall back to Breeze, which is not a good look for some of them: - the heading is too jarring compared to applet background - the heading does not extend all the way vertically and horizontally To solve this, to avoid degrading unmaintained themes and to give themes a chance to adjust on their own terms, this patch makes the heading visible only when the needed SVG exists in the theme. Test Plan: Avoids this: {F8276897} {F8276896} Breeze still works as it should. Reviewers: #vdg, #plasma, niccolove, ngraham Reviewed By: #vdg, niccolove, ngraham Subscribers: ngraham, niccolove, kde-frameworks-devel Tags: #frameworks Differential Revision: https://phabricator.kde.org/D29352 --- .../plasmaextracomponents/qml/PlasmoidHeading.qml | 1 + 1 file changed, 1 insertion(+) diff --git a/src/declarativeimports/plasmaextracomponents/qml/PlasmoidHeading.qml b/src/declarativeimports/plasmaextracomponents/qml/PlasmoidHeading.qml index 74db6b15a..9bf45cae0 100644 --- a/src/declarativeimports/plasmaextracomponents/qml/PlasmoidHeading.qml +++ b/src/declarativeimports/plasmaextracomponents/qml/PlasmoidHeading.qml @@ -65,6 +65,7 @@ import QtQuick.Templates 2.12 as T background: PlasmaCore.FrameSvgItem { id: headingSvg + visible: fromCurrentTheme imagePath: "widgets/plasmoidheading" prefix: location == PlasmoidHeading.Location.Header? 'header' : 'footer' }