Kstars

Led.qml
1// SPDX-FileCopyrightText: 2016 Artem Fedoskin <afedoskin3@gmail.com>
2// SPDX-License-Identifier: GPL-2.0-or-later
3
4import QtQuick 2.6
5import "../../constants" 1.0
6
7Image {
8 property string color: "grey"
9 width: 16 * Num.dp
10 height: 16 * Num.dp
11 sourceSize.height: 16 * Num.dp
12 sourceSize.width: 16 * Num.dp
13
14 source: "images/" + Num.density + "/grey.png"
15 onColorChanged: {
16 if(color == "red") {
17 source = "images/" + Num.density + "/red.png"
18 } else if(color == "green") {
19 source = "images/" + Num.density + "/green.png"
20 } else if(color == "yellow") {
21 source = "images/" + Num.density + "/yellow.png"
22 } else if(color == "grey") {
23 source = "images/" + Num.density + "/grey.png"
24 }
25 }
26}
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:04:46 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.