diff options
| author | caley <195605706+cqley@users.noreply.github.com> | 2026-07-15 12:47:00 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-07-15 12:47:00 +0200 |
| commit | a734d2a86d7727e24eb31e217f14d8315e0e22e6 (patch) | |
| tree | 7c94a3898877864db6fb20877e6e4f4b9a006bd7 /nixos | |
| parent | a0d9b36e8f94643a31f14615d29a8ee2f8916297 (diff) | |
Update qksh.nix
Diffstat (limited to 'nixos')
| -rw-r--r-- | nixos/mdls/qksh.nix | 32 |
1 files changed, 27 insertions, 5 deletions
diff --git a/nixos/mdls/qksh.nix b/nixos/mdls/qksh.nix index 2bb4e90..c44f0bc 100644 --- a/nixos/mdls/qksh.nix +++ b/nixos/mdls/qksh.nix @@ -64,6 +64,9 @@ property string sysStats: "cpu --% | mem --%" property string micState: "" + + // Dynamic background color pulled from the colors script + property string bgColor: "#1c1c1c" function removeNotif(nid) { for (let i = 0; i < notifModel.count; i++) { @@ -322,8 +325,27 @@ } } + Process { + id: bgProc + command: ["sh", "-c", "grep '^background=' $HOME/.colors/colors.sh | cut -d'\"' -f2"] + running: true // Run once on startup to fetch the latest background + stdout: SplitParser { + onRead: data => { + let val = data.trim() + if (val !== "") root.bgColor = val + } + } + } + Process { id: launchProc; running: false } - Process { id: mProc; running: false } + Process { + id: mProc + running: false + onRunningChanged: { + // Refreshes the color automatically when a command (like your wallpaper script) completes + if (!running) bgProc.running = true + } + } Process { id: recProc; running: false } Process { @@ -410,7 +432,7 @@ Rectangle { anchors.fill: parent - color: "#1c1c1c" + color: root.bgColor // <-- Updated to use dynamic background MText { anchors.centerIn: parent @@ -621,7 +643,7 @@ width: root.implicitWidth height: parent.height anchors.horizontalCenter: parent.horizontalCenter - color: "#1c1c1c" + color: root.bgColor // <-- Updated to use dynamic background Column { anchors.top: parent.top @@ -716,7 +738,7 @@ id: toastRect width: Math.round(root.implicitWidth / 3) height: 34 - color: "#1c1c1c" + color: root.bgColor // <-- Updated to use dynamic background Rectangle { visible: index > 0 @@ -848,7 +870,7 @@ Rectangle { id: calendarBox anchors.fill: parent - color: "#1c1c1c" + color: root.bgColor // <-- Updated to use dynamic background border.color: "#3c3c3c" border.width: 1 focus: true |
