Warning, /plasma/latte-dock/declarativeimports/components/SpinBox.qml is written in an unsupported language. File is not indexed.

0001 /*
0002     SPDX-FileCopyrightText: 2019 Michail Vourlakos <mvourlakos@gmail.com>
0003     SPDX-License-Identifier: GPL-2.0-or-later
0004 */
0005 
0006 import QtQuick 2.0
0007 import QtQuick.Controls 1.4 as Controls
0008 import QtQuick.Controls.Styles.Plasma 2.0 as Styles
0009 import org.kde.plasma.core 2.0 as PlasmaCore
0010 
0011 Controls.SpinBox {
0012     implicitWidth: theme.mSize(theme.defaultFont).width * 10
0013 
0014     style: Styles.SpinBoxStyle {
0015         PlasmaCore.Svg {
0016             id: arrowSvg
0017             imagePath: "widgets/arrows"
0018             colorGroup: PlasmaCore.Theme.ButtonColorGroup
0019         }
0020         incrementControl: PlasmaCore.SvgItem {
0021             implicitWidth: theme.mSize(theme.defaultFont).width * 1.8
0022             anchors {
0023                 centerIn: parent
0024                 margins: 1
0025                 leftMargin: 0
0026                 rightMargin: 3
0027             }
0028             svg: arrowSvg
0029             elementId: "up-arrow"
0030             opacity: control.enabled ? (styleData.upPressed ? 1 : 0.6) : 0.5
0031         }
0032         decrementControl: PlasmaCore.SvgItem {
0033             implicitWidth: theme.mSize(theme.defaultFont).width * 1.8
0034             anchors {
0035                 centerIn: parent
0036                 margins: 1
0037                 leftMargin: 0
0038                 rightMargin: 3
0039             }
0040             svg: arrowSvg
0041             elementId: "down-arrow"
0042             opacity: control.enabled ? (styleData.upPressed ? 1 : 0.6) : 0.5
0043         }
0044     }
0045 }