From 943036a507718bd87a1fdb09a13e8324fdc34960 Mon Sep 17 00:00:00 2001 From: zer0day Date: Mon, 10 Nov 2025 14:11:51 +0100 Subject: [PATCH] Use SystemClock support library instead of date --- user/Time.qml | 24 ++++++++---------------- 1 file changed, 8 insertions(+), 16 deletions(-) diff --git a/user/Time.qml b/user/Time.qml index 0b0fa12..75c1e8f 100644 --- a/user/Time.qml +++ b/user/Time.qml @@ -1,27 +1,19 @@ pragma Singleton import Quickshell -import Quickshell.Io import QtQuick Singleton { id: root - property string time + Singleton { + id: root + readonly property string time: { + Qt.formatDateTime(clock.date, "hh:mm:ss ddd dd.MM.yyyy") + } - Process { - id: dateProc - command: ["date"] - running: true - - stdout: StdioCollector { - onStreamFinished: root.time = this.text + SystemClock { + id: clock + precision: SystemClock.Seconds } } - - Timer { - intervall: 1000 - running: true - repeat: true - onTriggered: dateProc.running = true - } } \ No newline at end of file