Repository navigation
Expand file tree
/
Copy pathSolarPanelTile6.qml
More file actions
63 lines (55 loc) · 1.59 KB
/
Copy pathSolarPanelTile6.qml
File metadata and controls
63 lines (55 loc) · 1.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
import QtQuick 2.1
import qb.components 1.0
Tile {
id: myUsageTile
property bool dimState: screenStateController.dimmedColors
Text {
id: tileTitle
anchors {
baseline: parent.top
baselineOffset: 30
horizontalCenter: parent.horizontalCenter
}
font {
family: qfont.regular.name
pixelSize: qfont.tileTitle
}
color: !dimState? "black" : "white"
text: "Stroom nu"
}
Text {
id: txtBig
text: parseInt(parseInt(app.currentPower) + parseInt(app.currentUsage) - parseInt(app.currentPowerProd)) + " W"
color: dimmableColors.clockTileColor
anchors {
top: tileTitle.bottom
topMargin: isNxt? 6:5
horizontalCenter: parent.horizontalCenter
}
font.pixelSize: dimState ? qfont.clockFaceText : qfont.timeAndTemperatureText
font.family: qfont.regular.name
}
Text {
id: source
text: "Van de zon: " + parseInt(app.currentPower) + " W / het net: " + parseInt(app.currentUsage) + " W"
anchors {
top: txtBig.bottom
topMargin: 2
horizontalCenter: parent.horizontalCenter
}
font.pixelSize: isNxt? 16:12
font.family: qfont.bold.name
color : dimState? dimmableColors.clockTileColor : colors.clockTileColor
}
Text {
id: prod
text: "Terug net: " + parseInt(app.currentPowerProd) + " W / Totaal: " + parseFloat(parseInt(parseInt(app.totalPowerProductionNt) + parseInt(app.totalPowerProductionLt)) /1000).toFixed(1) + " kWh"
anchors {
top: source.bottom
horizontalCenter: parent.horizontalCenter
}
font.pixelSize: isNxt? 16:12
font.family: qfont.bold.name
color : dimState? dimmableColors.clockTileColor : colors.clockTileColor
}
}