nichts/modules/style/quickshell/shell/ClockWidget.qml

47 lines
880 B
QML
Raw Permalink Normal View History

2025-06-26 20:46:50 +02:00
import QtQuick
import Quickshell
Rectangle {
width: text.width
implicitHeight: text.height
// border.color: "black"
border.width: 2
radius: 0
color: "transparent"
Behavior on implicitHeight {
NumberAnimation {
duration: 100
easing.type: Easing.OutCubic
}
}
Item {
width: parent.width
height: text.height
anchors.centerIn: parent
SystemClock {
id: clock
precision: SystemClock.Seconds
}
Text {
id: text
anchors.centerIn: parent
property var date: Date()
text: Qt.formatDateTime(clock.date, "hh mm")
font.family: "ComicShannsMono Nerd Font Mono"
font.weight: Font.ExtraBold
font.pointSize: 12
color: "black"
}
}
}