/*SPDX-FileCopyrightText: 2023 Joshua Goins <josh@redstrate.com>SPDX-License-Identifier: GPL-2.0-or-later*/import QtQuickimport QtQuick.Controls as QQC2import QtQuick.Shapesimport org.kde.kirigami as KirigamiRectangle {id: rootimplicitWidth: 220implicitHeight: 220required property var devicereadonly property color lightColor: Kirigami.ColorUtils.tintWithAlpha(Kirigami.Theme.backgroundColor, Kirigami.Theme.textColor, 0.2)required property bool leftAxisreadonly property int markWidth: 5readonly property real axisXValue: device !== null ? leftAxis ? device.leftAxis.x : device.rightAxis.x : 0readonly property real axisYValue: device !== null ? leftAxis ? device.leftAxis.y : device.rightAxis.y : 0readonly property real axisX: (axisXValue * root.width / 2) + (root.width / 2)readonly property real axisY: (axisYValue * root.height / 2) + (root.height / 2)border {color: Kirigami.Theme.textColorwidth: 1}color: "transparent"Shape {anchors.fill: parent// horizontal middle separatorShapePath {strokeWidth: 1strokeColor: root.lightColorstartX: 0startY: root.height / 2PathLine {x: root.widthy: root.height / 2}}// vertical middle separatorShapePath {strokeWidth: 1strokeColor: root.lightColorstartX: root.width / 2startY: 0PathLine {x: root.width / 2y: root.height}}// first part of the markerShapePath {strokeWidth: 1strokeColor: Kirigami.Theme.textColorstartX: root.axisX - root.markWidthstartY: root.axisY - root.markWidthPathLine {x: root.axisX + root.markWidthy: root.axisY + root.markWidth}}// second part of the markerShapePath {strokeWidth: 1strokeColor: Kirigami.Theme.textColorstartX: root.axisX + root.markWidthstartY: root.axisY - root.markWidthPathLine {x: root.axisX - root.markWidthy: root.axisY + root.markWidth}}}}