Add date and time parsing and add colors from matugen to all current elements of top bar
This commit is contained in:
@@ -5,7 +5,7 @@ import "../constants"
|
|||||||
|
|
||||||
Text {
|
Text {
|
||||||
id: clock
|
id: clock
|
||||||
color: Constants.colBlue
|
color: Colors.md3.on_primary_fixed
|
||||||
|
|
||||||
font {
|
font {
|
||||||
family: Constants.fontFamily
|
family: Constants.fontFamily
|
||||||
@@ -14,7 +14,7 @@ Text {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function updateTime() {
|
function updateTime() {
|
||||||
text = Qt.formatDateTime(new Date(), "ddd, MMM dd - HH:mm");
|
text = Qt.formatDateTime(new Date(), "[dd-MM-yy] - [HH:mm]");
|
||||||
}
|
}
|
||||||
|
|
||||||
Component.onCompleted: updateTime()
|
Component.onCompleted: updateTime()
|
||||||
|
|||||||
9
quickshell/ui/LineSeparator.qml
Normal file
9
quickshell/ui/LineSeparator.qml
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
import QtQuick
|
||||||
|
import "../constants"
|
||||||
|
|
||||||
|
// vertical line separator for top bar
|
||||||
|
Rectangle {
|
||||||
|
width: 1
|
||||||
|
height: 16
|
||||||
|
color: Colors.md3.on_background
|
||||||
|
}
|
||||||
@@ -72,33 +72,29 @@ Item {
|
|||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: 10
|
spacing: 10
|
||||||
|
|
||||||
|
LineSeparator {}
|
||||||
|
|
||||||
BarText {
|
BarText {
|
||||||
prefix: "C"
|
prefix: "C"
|
||||||
value: cpuUsage
|
value: cpuUsage
|
||||||
}
|
}
|
||||||
|
|
||||||
Rectangle {
|
LineSeparator {}
|
||||||
width: 1
|
|
||||||
height: 16
|
|
||||||
color: Colors.md3.on_background
|
|
||||||
}
|
|
||||||
|
|
||||||
BarText {
|
BarText {
|
||||||
prefix: "M"
|
prefix: "M"
|
||||||
value: memUsage
|
value: memUsage
|
||||||
}
|
}
|
||||||
|
|
||||||
Rectangle {
|
LineSeparator {}
|
||||||
width: 1
|
|
||||||
height: 16
|
|
||||||
color: Colors.md3.on_background
|
|
||||||
}
|
|
||||||
|
|
||||||
BarText {
|
BarText {
|
||||||
prefix: "G"
|
prefix: "G"
|
||||||
value: gpuUsage
|
value: gpuUsage
|
||||||
}
|
}
|
||||||
|
|
||||||
|
LineSeparator {}
|
||||||
|
|
||||||
Clock {}
|
Clock {}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user