From 682db9b32f274424c7364880c6d1be625849b259 Mon Sep 17 00:00:00 2001 From: Caroline Larimore Date: Sat, 11 May 2024 22:10:32 -0700 Subject: Add addition position to EWW music widget --- modules/home/eww.nix | 6 +++--- modules/home/i3.nix | 3 ++- 2 files changed, 5 insertions(+), 4 deletions(-) (limited to 'modules') diff --git a/modules/home/eww.nix b/modules/home/eww.nix index 3be22ea..850fc9b 100644 --- a/modules/home/eww.nix +++ b/modules/home/eww.nix @@ -95,13 +95,13 @@ ''; xdg.configFile."eww/eww.yuck".text = '' - (defwindow music + (defwindow music [pos] :monitor 0 :geometry (geometry - :x "0px" + :x { pos == "right" ? "2px" : "0px" } :y "0px" :height {128 + 16} - :anchor "bottom center" + :anchor { pos == "right" ? "bottom right" : "bottom center" } ) :stacking "fg" :windowtype "dock" diff --git a/modules/home/i3.nix b/modules/home/i3.nix index 27556ae..927a813 100644 --- a/modules/home/i3.nix +++ b/modules/home/i3.nix @@ -128,7 +128,8 @@ "XF86AudioPrev" = "exec playerctl previous"; # Media controller widget - "${mod}+m" = "exec --no-startup-id eww-toggle music"; + "${mod}+m" = "exec --no-startup-id eww-toggle music --arg pos=center"; + "${mod}+n" = "exec --no-startup-id eww-toggle music --arg pos=right"; # Workspaces "${mod}+grave" = "workspace number ${ws0}"; -- cgit v1.2.3