From 4663c7d683af2c83a57afa4952bd2a214d4fb61f Mon Sep 17 00:00:00 2001 From: zach Date: Thu, 21 May 2026 17:55:31 +0200 Subject: [PATCH 1/5] better wallpaper preview positioning --- .../Settings/Controls/WallpaperCropper.qml | 34 +++++++++---------- 1 file changed, 16 insertions(+), 18 deletions(-) diff --git a/Modules/Settings/Controls/WallpaperCropper.qml b/Modules/Settings/Controls/WallpaperCropper.qml index 4fba8dd..1cc0d82 100644 --- a/Modules/Settings/Controls/WallpaperCropper.qml +++ b/Modules/Settings/Controls/WallpaperCropper.qml @@ -38,15 +38,13 @@ RowLayout { property var displayData readonly property real imageRatio: scaledImg.sourceSize.width / scaledImg.sourceSize.height property real monitorScale: 1.0 - readonly property real scaleDownX: scaledImg.width / scaledImg.sourceSize.width - readonly property real scaleDownY: scaledImg.height / scaledImg.sourceSize.height - readonly property real scaleX: (scaledImg.sourceSize.width * monitorScale) / scaledImg.width - readonly property real scaleY: (scaledImg.sourceSize.height * monitorScale) / scaledImg.height + readonly property real scaleDownX: scaledImg.paintedWidth / scaledImg.sourceSize.width + readonly property real scaleDownY: scaledImg.paintedHeight / scaledImg.sourceSize.height + readonly property real scaleX: (scaledImg.sourceSize.width * monitorScale) / scaledImg.paintedWidth + readonly property real scaleY: (scaledImg.sourceSize.height * monitorScale) / scaledImg.paintedHeight - anchors.left: parent.left - anchors.right: parent.right - anchors.verticalCenter: parent.verticalCenter - height: width / imageRatio + anchors.fill: parent + fillMode: Image.PreserveAspectFit source: Wallpapers.current onPaintedWidthChanged: { @@ -74,23 +72,23 @@ RowLayout { property real aspectRatio: delegate.modelData.width / delegate.modelData.height readonly property real baseHeight: baseWidth / aspectRatio readonly property real baseWidth: { - let fittedHeight = scaledImg.height; + let fittedHeight = scaledImg.paintedHeight; let fittedWidth = fittedHeight * aspectRatio; - if (fittedWidth > scaledImg.width) { - fittedWidth = scaledImg.width; + if (fittedWidth > scaledImg.paintedWidth) { + fittedWidth = scaledImg.paintedWidth; fittedHeight = fittedWidth / aspectRatio; } return fittedWidth; } - readonly property real imageX: (scaledImg.width - scaledImg.width) / 2 - readonly property real imageY: (scaledImg.height - scaledImg.height) / 2 + readonly property real imageX: (scaledImg.width - scaledImg.paintedWidth) / 2 + readonly property real imageY: (scaledImg.height - scaledImg.paintedHeight) / 2 property real zoom: scaledImg.displayData.zoom function centerInImage() { - x = imageX + (scaledImg.width - width) / 2; - y = imageY + (scaledImg.height - height) / 2; + x = imageX + (scaledImg.paintedWidth - width) / 2; + y = imageY + (scaledImg.paintedHeight - height) / 2; } function clampToBounds() { @@ -129,9 +127,9 @@ RowLayout { let nx = mouseX - cropRect.width * 0.5; let ny = mouseY - cropRect.height * 0.5; - nx = Math.max(cropRect.imageX, Math.min(nx, cropRect.imageX + scaledImg.width - cropRect.width)); + nx = Math.max(cropRect.imageX, Math.min(nx, cropRect.imageX + scaledImg.paintedWidth - cropRect.width)); - ny = Math.max(cropRect.imageY, Math.min(ny, cropRect.imageY + scaledImg.height - cropRect.height)); + ny = Math.max(cropRect.imageY, Math.min(ny, cropRect.imageY + scaledImg.paintedHeight - cropRect.height)); cropRect.x = nx; cropRect.y = ny; @@ -150,7 +148,7 @@ RowLayout { } onReleased: { const croprect = cropRect.mapToItem(scaledImg, 0, 0, cropRect.width, cropRect.height); - const upscaledRect = Qt.rect(croprect.x / scaledImg.width, croprect.y / scaledImg.height, croprect.width / scaledImg.width, croprect.height / scaledImg.height); + const upscaledRect = Qt.rect((croprect.x - cropRect.imageX) / scaledImg.paintedWidth, (croprect.y - cropRect.imageY) / scaledImg.paintedHeight, croprect.width / scaledImg.paintedWidth, croprect.height / scaledImg.paintedHeight); Wallpapers.setCrop(delegate.modelData.name, upscaledRect, croprect, cropRect.zoom); } onWheel: wheel => { From 9e75b593f4d02b04ec2928db914eff3355428886 Mon Sep 17 00:00:00 2001 From: zach Date: Thu, 21 May 2026 19:14:29 +0200 Subject: [PATCH 2/5] scale slider for crop tool --- .../Settings/Controls/WallpaperCropper.qml | 71 ++++++++++++++++--- 1 file changed, 60 insertions(+), 11 deletions(-) diff --git a/Modules/Settings/Controls/WallpaperCropper.qml b/Modules/Settings/Controls/WallpaperCropper.qml index 1cc0d82..1bc84f5 100644 --- a/Modules/Settings/Controls/WallpaperCropper.qml +++ b/Modules/Settings/Controls/WallpaperCropper.qml @@ -4,6 +4,7 @@ import QtQuick import QtQuick.Layouts import Quickshell import Quickshell.Hyprland +import ZShell.Internal import qs.Config import qs.Components import qs.Helpers @@ -29,23 +30,63 @@ RowLayout { required property ShellScreen modelData + function zoomClipRect(zoom: real): void { + let oldCenterX = cropRect.x + cropRect.width * 0.5; + let oldCenterY = cropRect.y + cropRect.height * 0.5; + + cropRect.zoom = zoom; + + cropRect.x = oldCenterX - cropRect.width * 0.5; + cropRect.y = oldCenterY - cropRect.height * 0.5; + + cropRect.clampToBounds(); + } + Layout.fillHeight: true Layout.fillWidth: true - Image { + RowLayout { + id: sliderLayout + + anchors.bottom: parent.bottom + anchors.left: parent.left + anchors.right: parent.right + implicitHeight: 30 + spacing: Appearance.spacing.large + + CustomText { + text: qsTr("Crop scale") + } + + CustomSlider { + id: zoomSlider + + Layout.fillWidth: true + Layout.preferredHeight: 10 + from: 1.0 + to: 5.0 + value: cropRect.zoom + + onMoved: delegate.zoomClipRect(value) + } + } + + CachingImage { id: scaledImg property var displayData - readonly property real imageRatio: scaledImg.sourceSize.width / scaledImg.sourceSize.height property real monitorScale: 1.0 - readonly property real scaleDownX: scaledImg.paintedWidth / scaledImg.sourceSize.width - readonly property real scaleDownY: scaledImg.paintedHeight / scaledImg.sourceSize.height - readonly property real scaleX: (scaledImg.sourceSize.width * monitorScale) / scaledImg.paintedWidth - readonly property real scaleY: (scaledImg.sourceSize.height * monitorScale) / scaledImg.paintedHeight - anchors.fill: parent + anchors.bottom: sliderLayout.top + anchors.left: parent.left + anchors.right: parent.right + anchors.top: parent.top + asynchronous: true fillMode: Image.PreserveAspectFit + // retainWhileLoading: true source: Wallpapers.current + sourceSize.height: parent.height + sourceSize.width: parent.width onPaintedWidthChanged: { if (paintedWidth > 0) { @@ -84,6 +125,7 @@ RowLayout { } readonly property real imageX: (scaledImg.width - scaledImg.paintedWidth) / 2 readonly property real imageY: (scaledImg.height - scaledImg.paintedHeight) / 2 + property real imgAspectRatio: scaledImg.paintedWidth / scaledImg.paintedHeight property real zoom: scaledImg.displayData.zoom function centerInImage() { @@ -114,8 +156,14 @@ RowLayout { border.color: "lime" border.width: 2 height: baseHeight / zoom + opacity: zoom > 1.0 ? 1 : Math.abs(aspectRatio - imgAspectRatio) > 0.1 ? 1 : 0 width: baseWidth / zoom + Behavior on opacity { + Anim { + } + } + onHeightChanged: clampToBounds() onWidthChanged: clampToBounds() } @@ -147,9 +195,11 @@ RowLayout { updateCrop(mouse.x, mouse.y); } onReleased: { - const croprect = cropRect.mapToItem(scaledImg, 0, 0, cropRect.width, cropRect.height); - const upscaledRect = Qt.rect((croprect.x - cropRect.imageX) / scaledImg.paintedWidth, (croprect.y - cropRect.imageY) / scaledImg.paintedHeight, croprect.width / scaledImg.paintedWidth, croprect.height / scaledImg.paintedHeight); - Wallpapers.setCrop(delegate.modelData.name, upscaledRect, croprect, cropRect.zoom); + if (cropRect.opacity > 0) { + const croprect = cropRect.mapToItem(scaledImg, 0, 0, cropRect.width, cropRect.height); + const upscaledRect = Qt.rect((croprect.x - cropRect.imageX) / scaledImg.paintedWidth, (croprect.y - cropRect.imageY) / scaledImg.paintedHeight, croprect.width / scaledImg.paintedWidth, croprect.height / scaledImg.paintedHeight); + Wallpapers.setCrop(delegate.modelData.name, upscaledRect, croprect, cropRect.zoom); + } } onWheel: wheel => { let oldCenterX = cropRect.x + cropRect.width * 0.5; @@ -161,7 +211,6 @@ RowLayout { cropRect.zoom /= 1.1; cropRect.zoom = Math.max(1.0, Math.min(cropRect.zoom, 5.0)); - console.log(cropRect.zoom); cropRect.x = oldCenterX - cropRect.width * 0.5; cropRect.y = oldCenterY - cropRect.height * 0.5; From 2342edcf66732ac3ed18cc9c7113151789eda7f3 Mon Sep 17 00:00:00 2001 From: zach Date: Thu, 21 May 2026 23:12:01 +0200 Subject: [PATCH 3/5] apply button, wheel doesn't zoom --- Modules/Settings/Categories/Background.qml | 1 - .../Settings/Controls/WallpaperCropper.qml | 365 ++++++++++-------- 2 files changed, 201 insertions(+), 165 deletions(-) diff --git a/Modules/Settings/Categories/Background.qml b/Modules/Settings/Categories/Background.qml index 4f7390e..233c31f 100644 --- a/Modules/Settings/Categories/Background.qml +++ b/Modules/Settings/Categories/Background.qml @@ -36,7 +36,6 @@ SettingsPage { } WallpaperCropper { - screen: root.screen } } diff --git a/Modules/Settings/Controls/WallpaperCropper.qml b/Modules/Settings/Controls/WallpaperCropper.qml index 1bc84f5..bd3ff93 100644 --- a/Modules/Settings/Controls/WallpaperCropper.qml +++ b/Modules/Settings/Controls/WallpaperCropper.qml @@ -9,213 +9,250 @@ import qs.Config import qs.Components import qs.Helpers -RowLayout { - id: root +Item { + id: wrapper - required property ShellScreen screen + property bool changesMade: false + + signal requestCrop Layout.fillWidth: true Layout.preferredHeight: 400 - spacing: Appearance.spacing.normal - Repeater { - model: ScriptModel { - values: [...Quickshell.screens].sort((a, b) => { - return a.x - b.x; - }) + IconButton { + anchors.margins: Appearance.padding.normal + anchors.right: parent.right + anchors.top: parent.top + icon: "check" + opacity: wrapper.changesMade ? 1 : 0 + scale: wrapper.changesMade ? 1 : 0 + z: 2 + + Behavior on opacity { + Anim { + } + } + Behavior on scale { + Anim { + } } - Item { - id: delegate + onClicked: { + wrapper.requestCrop(); + wrapper.changesMade = false; + } + } - required property ShellScreen modelData + RowLayout { + id: root - function zoomClipRect(zoom: real): void { - let oldCenterX = cropRect.x + cropRect.width * 0.5; - let oldCenterY = cropRect.y + cropRect.height * 0.5; + anchors.fill: parent + spacing: Appearance.spacing.normal - cropRect.zoom = zoom; - - cropRect.x = oldCenterX - cropRect.width * 0.5; - cropRect.y = oldCenterY - cropRect.height * 0.5; - - cropRect.clampToBounds(); + Repeater { + model: ScriptModel { + values: [...Quickshell.screens].sort((a, b) => { + return a.x - b.x; + }) } - Layout.fillHeight: true - Layout.fillWidth: true + Item { + id: delegate - RowLayout { - id: sliderLayout + required property ShellScreen modelData - anchors.bottom: parent.bottom - anchors.left: parent.left - anchors.right: parent.right - implicitHeight: 30 - spacing: Appearance.spacing.large - - CustomText { - text: qsTr("Crop scale") + function applyCrop(): void { + const croprect = cropRect.mapToItem(scaledImg, 0, 0, cropRect.width, cropRect.height); + const upscaledRect = Qt.rect((croprect.x - cropRect.imageX) / scaledImg.paintedWidth, (croprect.y - cropRect.imageY) / scaledImg.paintedHeight, croprect.width / scaledImg.paintedWidth, croprect.height / scaledImg.paintedHeight); + Wallpapers.setCrop(delegate.modelData.name, upscaledRect, croprect, cropRect.zoom); } - CustomSlider { - id: zoomSlider + function zoomClipRect(zoom: real): void { + let oldCenterX = cropRect.x + cropRect.width * 0.5; + let oldCenterY = cropRect.y + cropRect.height * 0.5; - Layout.fillWidth: true - Layout.preferredHeight: 10 - from: 1.0 - to: 5.0 - value: cropRect.zoom + cropRect.zoom = zoom; - onMoved: delegate.zoomClipRect(value) - } - } + cropRect.x = oldCenterX - cropRect.width * 0.5; + cropRect.y = oldCenterY - cropRect.height * 0.5; - CachingImage { - id: scaledImg - - property var displayData - property real monitorScale: 1.0 - - anchors.bottom: sliderLayout.top - anchors.left: parent.left - anchors.right: parent.right - anchors.top: parent.top - asynchronous: true - fillMode: Image.PreserveAspectFit - // retainWhileLoading: true - source: Wallpapers.current - sourceSize.height: parent.height - sourceSize.width: parent.width - - onPaintedWidthChanged: { - if (paintedWidth > 0) { - scaledImg.displayData = Wallpapers.getCrop(delegate.modelData.name); - cropRect.zoom = Wallpapers.getCrop(delegate.modelData.name).zoom; - cropRect.restoreFromData(); - } + cropRect.clampToBounds(); } - CustomText { - id: monitorId + Layout.fillHeight: true + Layout.fillWidth: true - anchors.centerIn: parent - color: Qt.alpha(DynamicColors.palette.m3surface, 0.85) - font.pointSize: Appearance.font.size.large * 4 - style: Text.Outline - styleColor: DynamicColors.palette.m3onSurface - text: delegate.modelData.name + Connections { + function onRequestCrop(): void { + delegate.applyCrop(); + } + + target: wrapper } - CustomRect { - id: cropRect + RowLayout { + id: sliderLayout - property real aspectRatio: delegate.modelData.width / delegate.modelData.height - readonly property real baseHeight: baseWidth / aspectRatio - readonly property real baseWidth: { - let fittedHeight = scaledImg.paintedHeight; - let fittedWidth = fittedHeight * aspectRatio; + anchors.bottom: parent.bottom + anchors.left: parent.left + anchors.right: parent.right + implicitHeight: 30 + spacing: Appearance.spacing.large - if (fittedWidth > scaledImg.paintedWidth) { - fittedWidth = scaledImg.paintedWidth; - fittedHeight = fittedWidth / aspectRatio; - } - - return fittedWidth; - } - readonly property real imageX: (scaledImg.width - scaledImg.paintedWidth) / 2 - readonly property real imageY: (scaledImg.height - scaledImg.paintedHeight) / 2 - property real imgAspectRatio: scaledImg.paintedWidth / scaledImg.paintedHeight - property real zoom: scaledImg.displayData.zoom - - function centerInImage() { - x = imageX + (scaledImg.paintedWidth - width) / 2; - y = imageY + (scaledImg.paintedHeight - height) / 2; + CustomText { + text: qsTr("Crop scale") } - function clampToBounds() { - x = Math.max(imageX, Math.min(x, imageX + scaledImg.paintedWidth - width)); + CustomSlider { + id: zoomSlider - y = Math.max(imageY, Math.min(y, imageY + scaledImg.paintedHeight - height)); - } + Layout.fillWidth: true + Layout.preferredHeight: 10 + from: 1.0 + to: 5.0 + value: cropRect.zoom - function restoreFromData() { - let data = scaledImg.displayData; - - if (data && data.scaledX !== 0 || data.scaledY !== 0 || data.scaledWidth !== 0 || data.scaledHeight !== 0) { - x = data.scaledX; - y = data.scaledY; - - clampToBounds(); - } else { - zoom = 1.0; - centerInImage(); + onMoved: { + delegate.zoomClipRect(value); + wrapper.changesMade = true; } } - - border.color: "lime" - border.width: 2 - height: baseHeight / zoom - opacity: zoom > 1.0 ? 1 : Math.abs(aspectRatio - imgAspectRatio) > 0.1 ? 1 : 0 - width: baseWidth / zoom - - Behavior on opacity { - Anim { - } - } - - onHeightChanged: clampToBounds() - onWidthChanged: clampToBounds() } - MouseArea { - id: mouse + CachingImage { + id: scaledImg - function updateCrop(mouseX, mouseY) { - let nx = mouseX - cropRect.width * 0.5; - let ny = mouseY - cropRect.height * 0.5; + property var displayData + property real monitorScale: 1.0 - nx = Math.max(cropRect.imageX, Math.min(nx, cropRect.imageX + scaledImg.paintedWidth - cropRect.width)); + anchors.bottom: sliderLayout.top + anchors.bottomMargin: Appearance.spacing.normal + anchors.left: parent.left + anchors.right: parent.right + anchors.top: parent.top + asynchronous: true + fillMode: Image.PreserveAspectFit + // retainWhileLoading: true + source: Wallpapers.current + sourceSize.height: parent.height + sourceSize.width: parent.width - ny = Math.max(cropRect.imageY, Math.min(ny, cropRect.imageY + scaledImg.paintedHeight - cropRect.height)); + onPaintedWidthChanged: { + if (paintedWidth > 0) { + scaledImg.displayData = Wallpapers.getCrop(delegate.modelData.name); + cropRect.zoom = Wallpapers.getCrop(delegate.modelData.name).zoom; + cropRect.restoreFromData(); + } + } + onSourceChanged: cropRect.clampToBounds() + onStatusChanged: if (scaledImg.status == Image.Ready) + cropRect.clampToBounds() - cropRect.x = nx; - cropRect.y = ny; + CustomText { + id: monitorId + + anchors.centerIn: parent + color: Qt.alpha(DynamicColors.palette.m3surface, 0.85) + font.pointSize: Appearance.font.size.large * 4 + style: Text.Outline + styleColor: DynamicColors.palette.m3onSurface + text: delegate.modelData.name } - anchors.fill: parent - hoverEnabled: true - preventStealing: true + CustomRect { + id: cropRect - onPositionChanged: mouse => { - if (pressed) + property real aspectRatio: delegate.modelData.width / delegate.modelData.height + readonly property real baseHeight: baseWidth / aspectRatio + readonly property real baseWidth: { + let fittedHeight = scaledImg.paintedHeight; + let fittedWidth = fittedHeight * aspectRatio; + + if (fittedWidth > scaledImg.paintedWidth) { + fittedWidth = scaledImg.paintedWidth; + fittedHeight = fittedWidth / aspectRatio; + } + + return fittedWidth; + } + readonly property real imageX: (scaledImg.width - scaledImg.paintedWidth) / 2 + readonly property real imageY: (scaledImg.height - scaledImg.paintedHeight) / 2 + property real imgAspectRatio: scaledImg.paintedWidth / scaledImg.paintedHeight + property real zoom: scaledImg.displayData.zoom + + function centerInImage() { + x = imageX + (scaledImg.paintedWidth - width) / 2; + y = imageY + (scaledImg.paintedHeight - height) / 2; + } + + function clampToBounds() { + x = Math.max(imageX, Math.min(x, imageX + scaledImg.paintedWidth - width)); + + y = Math.max(imageY, Math.min(y, imageY + scaledImg.paintedHeight - height)); + } + + function restoreFromData() { + let data = scaledImg.displayData; + + if (data && data.scaledX !== 0 || data.scaledY !== 0 || data.scaledWidth !== 0 || data.scaledHeight !== 0) { + x = data.scaledX; + y = data.scaledY; + + clampToBounds(); + } else { + zoom = 1.0; + centerInImage(); + } + } + + border.color: DynamicColors.palette.m3primary + border.width: 2 + height: baseHeight / zoom + opacity: 1 + width: baseWidth / zoom + + Behavior on opacity { + Anim { + } + } + + Component.onCompleted: clampToBounds() + onHeightChanged: clampToBounds() + onWidthChanged: clampToBounds() + } + + MouseArea { + id: mouse + + function updateCrop(mouseX, mouseY) { + let nx = mouseX - cropRect.width * 0.5; + let ny = mouseY - cropRect.height * 0.5; + + nx = Math.max(cropRect.imageX, Math.min(nx, cropRect.imageX + scaledImg.paintedWidth - cropRect.width)); + + ny = Math.max(cropRect.imageY, Math.min(ny, cropRect.imageY + scaledImg.paintedHeight - cropRect.height)); + + cropRect.x = nx; + cropRect.y = ny; + } + + anchors.fill: parent + hoverEnabled: true + preventStealing: true + + onPositionChanged: mouse => { + if (pressed) { + updateCrop(mouse.x, mouse.y); + wrapper.changesMade = true; + } + } + onPressed: mouse => { updateCrop(mouse.x, mouse.y); - } - onPressed: mouse => { - updateCrop(mouse.x, mouse.y); - } - onReleased: { - if (cropRect.opacity > 0) { - const croprect = cropRect.mapToItem(scaledImg, 0, 0, cropRect.width, cropRect.height); - const upscaledRect = Qt.rect((croprect.x - cropRect.imageX) / scaledImg.paintedWidth, (croprect.y - cropRect.imageY) / scaledImg.paintedHeight, croprect.width / scaledImg.paintedWidth, croprect.height / scaledImg.paintedHeight); - Wallpapers.setCrop(delegate.modelData.name, upscaledRect, croprect, cropRect.zoom); + wrapper.changesMade = true; + } + onReleased: { + wrapper.changesMade = true; } - } - onWheel: wheel => { - let oldCenterX = cropRect.x + cropRect.width * 0.5; - let oldCenterY = cropRect.y + cropRect.height * 0.5; - - if (wheel.angleDelta.y > 0) - cropRect.zoom *= 1.1; - else - cropRect.zoom /= 1.1; - - cropRect.zoom = Math.max(1.0, Math.min(cropRect.zoom, 5.0)); - - cropRect.x = oldCenterX - cropRect.width * 0.5; - cropRect.y = oldCenterY - cropRect.height * 0.5; - - cropRect.clampToBounds(); } } } From a0d56b965c4a627a6b2ee126d582565db245887a Mon Sep 17 00:00:00 2001 From: zach Date: Thu, 21 May 2026 23:29:49 +0200 Subject: [PATCH 4/5] toggle to show notif icon on lockscreen --- Config/Config.qml | 1 + Config/LockConf.qml | 1 + Modules/Lock/NotifGroup.qml | 1 + Modules/Settings/Categories/Lockscreen.qml | 9 +++++++++ scripts/SettingsIndex.mjs | 7 +++++++ 5 files changed, 19 insertions(+) diff --git a/Config/Config.qml b/Config/Config.qml index c694c28..c02f483 100644 --- a/Config/Config.qml +++ b/Config/Config.qml @@ -242,6 +242,7 @@ Singleton { recolorLogo: lock.recolorLogo, enableFprint: lock.enableFprint, showNotifContent: lock.showNotifContent, + showNotifIcon: lock.showNotifIcon, maxFprintTries: lock.maxFprintTries, blurAmount: lock.blurAmount, sizes: { diff --git a/Config/LockConf.qml b/Config/LockConf.qml index bf83565..560218f 100644 --- a/Config/LockConf.qml +++ b/Config/LockConf.qml @@ -6,6 +6,7 @@ JsonObject { property int maxFprintTries: 3 property bool recolorLogo: false property bool showNotifContent: false + property bool showNotifIcon: false property Sizes sizes: Sizes { } diff --git a/Modules/Lock/NotifGroup.qml b/Modules/Lock/NotifGroup.qml index eaca951..4c0302c 100644 --- a/Modules/Lock/NotifGroup.qml +++ b/Modules/Lock/NotifGroup.qml @@ -58,6 +58,7 @@ CustomRect { fillMode: Image.PreserveAspectCrop height: Config.notifs.sizes.image source: Qt.resolvedUrl(root.image) + visible: Config.lock.showNotifIcon width: Config.notifs.sizes.image } } diff --git a/Modules/Settings/Categories/Lockscreen.qml b/Modules/Settings/Categories/Lockscreen.qml index 9c63787..50c93db 100644 --- a/Modules/Settings/Categories/Lockscreen.qml +++ b/Modules/Settings/Categories/Lockscreen.qml @@ -50,6 +50,15 @@ SettingsPage { Separator { } + SettingSwitch { + name: "Show notification icon" + object: Config.lock + setting: "showNotifIcon" + } + + Separator { + } + SettingSpinBox { min: 0 name: "Blur amount" diff --git a/scripts/SettingsIndex.mjs b/scripts/SettingsIndex.mjs index 8e6303a..12c74e1 100644 --- a/scripts/SettingsIndex.mjs +++ b/scripts/SettingsIndex.mjs @@ -311,6 +311,13 @@ export const settingsIndex = [ section: "Lockscreen", keywords: ["notification", "hide", "privacy"], }, + { + name: "Show notification icon", + category: "lockscreen", + categoryName: "Lockscreen", + section: "Lockscreen", + keywords: ["notification", "hide", "icon"], + }, { name: "Blur amount", category: "lockscreen", From 88526b9e98a2481bdba5ccb1a9c0704213fea0fa Mon Sep 17 00:00:00 2001 From: zach Date: Thu, 21 May 2026 23:43:27 +0200 Subject: [PATCH 5/5] show notif icon true by default --- Config/LockConf.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Config/LockConf.qml b/Config/LockConf.qml index 560218f..87a4f4e 100644 --- a/Config/LockConf.qml +++ b/Config/LockConf.qml @@ -6,7 +6,7 @@ JsonObject { property int maxFprintTries: 3 property bool recolorLogo: false property bool showNotifContent: false - property bool showNotifIcon: false + property bool showNotifIcon: true property Sizes sizes: Sizes { }