Warning, /plasma/plasma-sdk/themeexplorer/package/contents/ui/delegates/dialog.qml is written in an unsupported language. File is not indexed.
0001 /* 0002 * SPDX-FileCopyrightText: 2015 Marco Martin <mart@kde.org> 0003 * 0004 * SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 import QtQuick 2.0 0008 import QtQuick.Layouts 1.1 0009 0010 import org.kde.plasma.components 3.0 as PlasmaComponents 0011 import org.kde.ksvg 1.0 as KSvg 0012 import org.kde.kirigami as Kirigami 0013 0014 Item { 0015 KSvg.Svg { 0016 imagePath: model.imagePath 0017 onRepaintNeeded: { 0018 background.visible = background.hasElementPrefix("shadow") 0019 } 0020 } 0021 KSvg.FrameSvgItem { 0022 id: background 0023 anchors { 0024 fill: parent 0025 margins: Kirigami.Units.gridUnit 0026 } 0027 imagePath: model.imagePath 0028 onImagePathChanged: visible = hasElementPrefix("shadow") 0029 prefix: "shadow" 0030 } 0031 0032 KSvg.FrameSvgItem { 0033 anchors { 0034 fill: background 0035 leftMargin: background.margins.left 0036 topMargin: background.margins.top 0037 rightMargin: background.margins.right 0038 bottomMargin: background.margins.bottom 0039 } 0040 imagePath: model.imagePath 0041 0042 Rectangle { 0043 id: marginsRectangle 0044 anchors { 0045 fill: parent 0046 leftMargin: parent.margins.left 0047 topMargin: parent.margins.top 0048 rightMargin: parent.margins.right 0049 bottomMargin: parent.margins.bottom 0050 } 0051 color: "green" 0052 opacity: 0.5 0053 visible: root.showMargins 0054 } 0055 } 0056 0057 PlasmaComponents.Label { 0058 anchors.centerIn: parent 0059 text: model.imagePath 0060 visible: width < marginsRectangle.width 0061 } 0062 }