diff options
| author | littleblack111 <littleblack11111@gmail.com> | 2025-07-15 01:11:48 +0800 |
|---|---|---|
| committer | littleblack111 <littleblack11111@gmail.com> | 2025-07-15 01:11:48 +0800 |
| commit | 3ecfa34824d0842f21c925150afd1ec2b62630c0 (patch) | |
| tree | d0447b05898521845a6007c51623061c713ec902 /bar/TimeDate.qml | |
| parent | 318965ec16b11b2e5b454978a282521e74b2220a (diff) | |
timedate: animated time
Diffstat (limited to 'bar/TimeDate.qml')
| -rw-r--r-- | bar/TimeDate.qml | 24 |
1 files changed, 22 insertions, 2 deletions
diff --git a/bar/TimeDate.qml b/bar/TimeDate.qml index 1a952c7..6ef8596 100644 --- a/bar/TimeDate.qml +++ b/bar/TimeDate.qml @@ -34,8 +34,28 @@ Item { text: Icons.resource.clock font.pixelSize: Style.font.size.larger } - IText { - text: Services.TimeDate.time + RowLayout { + property int h: Services.TimeDate.hours + property int m: Services.TimeDate.minutes + property int s: Services.TimeDate.seconds + spacing: 0 + IText { + text: (parent.h > 10 ? "" : "0") + parent.h + } + IText { + text: ":" + } + IText { + animate: true + text: (parent.m > 10 ? "" : "0") + parent.m + } + IText { + text: ":" + } + IText { + animate: true + text: (parent.s > 10 ? "" : "0") + parent.s + } } Item { Layout.fillWidth: true |
