aboutsummaryrefslogtreecommitdiff
path: root/quickshell/items/Electrons.qml
blob: 769eda87266e0fa3b665810709a4178bf44998dc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import QtQuick
import QtQuick.Layouts

RowLayout {
  spacing: 0
  Text {
    text: " Electrons:"
    color: shellRoot.white
    font {
      family: shellRoot.fontFamily
      pixelSize: shellRoot.fontSize
    }
  }
  Text {
    text: (batteryCharging ? ("AC/DC(" + battery + ")") : battery)
    color: (battery <= redBatteryPoint) ? shellRoot.red : ((battery <= orangeBatteryPoint) ? shellRoot.orange : shellRoot.green)
    font {
      family: shellRoot.fontFamily
      pixelSize: shellRoot.fontSize
      bold: true
    }
  }
}