diff options
| author | coast <coasteen@proton.me> | 2026-09-07 07:07:22 +0330 |
|---|---|---|
| committer | coast <coasteen@proton.me> | 2026-09-07 07:07:22 +0330 |
| commit | 7922ded35ff292e485c3369dab9726b9142ce526 (patch) | |
| tree | ea47cb7bb569b5fb8c44ede3357f1a8b4b41722c /home-configuration/config/quickshell/modules/desktop/Wallpaper.qml | |
| parent | a7cdf9580a901ed65f179417f6ed8a0848491b66 (diff) | |
| download | nix-7922ded35ff292e485c3369dab9726b9142ce526.tar.gz nix-7922ded35ff292e485c3369dab9726b9142ce526.tar.bz2 nix-7922ded35ff292e485c3369dab9726b9142ce526.tar.xz nix-7922ded35ff292e485c3369dab9726b9142ce526.tar.zst | |
a lot of quickshell
Diffstat (limited to 'home-configuration/config/quickshell/modules/desktop/Wallpaper.qml')
| -rw-r--r-- | home-configuration/config/quickshell/modules/desktop/Wallpaper.qml | 63 |
1 files changed, 63 insertions, 0 deletions
diff --git a/home-configuration/config/quickshell/modules/desktop/Wallpaper.qml b/home-configuration/config/quickshell/modules/desktop/Wallpaper.qml new file mode 100644 index 0000000..557fef9 --- /dev/null +++ b/home-configuration/config/quickshell/modules/desktop/Wallpaper.qml @@ -0,0 +1,63 @@ +import QtQuick +import QtQuick.Effects +import Quickshell +import Quickshell.Wayland +import "../../config.js" as Config + +Variants { + model: Quickshell.screens + + PanelWindow { + required property var modelData + + property var wallpaper: Config.wallpapers.find(function(w) { + return w.outputs.indexOf(modelData.name) !== -1 + }) + + screen: modelData + visible: wallpaper !== undefined + + anchors { + top: true + bottom: true + left: true + right: true + } + + exclusionMode: ExclusionMode.Ignore + + WlrLayershell.layer: WlrLayer.Background + WlrLayershell.namespace: "wallpaper" + + Image { + id: wallpaperImage + + anchors.fill: parent + + source: wallpaper ? wallpaper.path : "" + + fillMode: wallpaper + ? Image[wallpaper.fillMode] + : Image.PreserveAspectCrop + + opacity: wallpaper ? wallpaper.opacity : 1.0 + + asynchronous: wallpaper + ? wallpaper.asynchronous + : true + + cache: wallpaper + ? wallpaper.cache + : true + } + + MultiEffect { + anchors.fill: wallpaperImage + + source: wallpaperImage + + blurEnabled: wallpaper ? wallpaper.blur > 0 : false + blur: wallpaper ? wallpaper.blur : 0 + } + } +} |
