From 8bd4bbe7ea795951e4d489e7d97357173a68ef7d Mon Sep 17 00:00:00 2001 From: darksignal7 Date: Sun, 5 Oct 2025 19:24:29 +0300 Subject: [PATCH] add ability to hide minute and hour hand --- .../quickshell/ii/modules/background/CookieClock.qml | 3 +++ .config/quickshell/ii/modules/common/Config.qml | 4 ++-- .../quickshell/ii/modules/settings/InterfaceConfig.qml | 10 ++++++++++ 3 files changed, 15 insertions(+), 2 deletions(-) diff --git a/.config/quickshell/ii/modules/background/CookieClock.qml b/.config/quickshell/ii/modules/background/CookieClock.qml index 56c812a6b..bdb29ca28 100644 --- a/.config/quickshell/ii/modules/background/CookieClock.qml +++ b/.config/quickshell/ii/modules/background/CookieClock.qml @@ -198,6 +198,7 @@ Item { // Hour hand Item { + visible: Config.options.background.clock.cookie.hourHandStyle === "hide" ? false : true anchors.fill: parent z: Config.options.background.clock.cookie.hourHandStyle === "fill" ? 3 : 1 rotation: -90 + (360 / 12) * (root.clockHour + root.clockMinute / 60) @@ -230,6 +231,7 @@ Item { // Minute hand Item { + visible: Config.options.background.clock.cookie.minuteHandStyle === "hide" ? false : true anchors.fill: parent z: Config.options.background.clock.cookie.minuteHandStyle === "thin" ? 1 : 3 rotation: -90 + (360 / 60) * root.clockMinute @@ -251,6 +253,7 @@ Item { // Center dot Rectangle { + visible: Config.options.background.clock.cookie.minuteHandStyle === "hide" && Config.options.background.clock.cookie.hourHandStyle === "hide" ? false : true z: 4 opacity: Config.options.background.clock.cookie.minuteHandStyle !== "bold" ? 1.0 : 0 color: Config.options.background.clock.cookie.minuteHandStyle === "medium" ? root.colBackground : root.colMinuteHand diff --git a/.config/quickshell/ii/modules/common/Config.qml b/.config/quickshell/ii/modules/common/Config.qml index 10f688520..5b217faa0 100644 --- a/.config/quickshell/ii/modules/common/Config.qml +++ b/.config/quickshell/ii/modules/common/Config.qml @@ -132,8 +132,8 @@ Singleton { property int clockSides: 12 property JsonObject cookie: JsonObject { property string dialNumberStyle: "dots" // Options: "dots" , "numbers", "full" , "none" - property string hourHandStyle: "fill" // Options: "fill", "stroke" - property string minuteHandStyle: "medium" // Options: "medium", "bold" + property string hourHandStyle: "fill" // Options: "fill", "stroke", "hide" + property string minuteHandStyle: "medium" // Options: "medium", "bold", "hide" property string secondHandStyle: "dot" // Options: "dot", "line" , "none" property string dateStyle: "rotating" // Options: "rotating", "square", "none" property bool timeIndicators: true diff --git a/.config/quickshell/ii/modules/settings/InterfaceConfig.qml b/.config/quickshell/ii/modules/settings/InterfaceConfig.qml index 0e78e5251..3d7c7bd16 100644 --- a/.config/quickshell/ii/modules/settings/InterfaceConfig.qml +++ b/.config/quickshell/ii/modules/settings/InterfaceConfig.qml @@ -170,6 +170,11 @@ ContentPage { displayName: Translation.tr("Bold"), icon: "pen_size_5", value: "bold" + }, + { + displayName: Translation.tr("Hide"), + icon: "hide_image", + value: "hide" } ] } @@ -223,6 +228,11 @@ ContentPage { displayName: Translation.tr("Stroke"), icon: "stroke_partial", value: "stroke" + }, + { + displayName: Translation.tr("Hide"), + icon: "hide_image", + value: "hide" } ] }