Libplasma

Frame.qml
1/*
2 SPDX-FileCopyrightText: 2016 Marco Martin <mart@kde.org>
3
4 SPDX-License-Identifier: LGPL-2.0-or-later
5*/
6
7import QtQuick
8import QtQuick.Controls
9import QtQuick.Templates as T
10import org.kde.kirigami as Kirigami
11import org.kde.ksvg as KSvg
12//NOTE: importing PlasmaCore is necessary in order to make KSvg load the current Plasma Theme
13import org.kde.plasma.core as PlasmaCore
14
15T.Frame {
16 id: control
17
18 implicitWidth: contentWidth + leftPadding + rightPadding
19 implicitHeight: contentHeight + topPadding + bottomPadding
20
21 contentWidth: contentItem.implicitWidth || (contentChildren.length === 1 ? contentChildren[0].implicitWidth : 0)
22 contentHeight: contentItem.implicitHeight || (contentChildren.length === 1 ? contentChildren[0].implicitHeight : 0)
23
24 padding: Kirigami.Units.smallSpacing
25
26 background: KSvg.FrameSvgItem {
27 imagePath: "widgets/frame"
28 prefix: "plain"
29 }
30}
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:10:41 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.