diff --git a/options/custom/desktops/hyprland/plugins.nix b/options/custom/desktops/hyprland/plugins.nix index 6b08647..c931c4c 100644 --- a/options/custom/desktops/hyprland/plugins.nix +++ b/options/custom/desktops/hyprland/plugins.nix @@ -30,7 +30,7 @@ in { "plugin:hyprbars:nobar, class:^dropdown$" "plugin:hyprbars:nobar, class:^org\\.gnome\\.Nautilus$, title:^New Folder$" "plugin:hyprbars:nobar, class:^steam_app_.+$" - "plugin:hyprbars:nobar, class:^waydroid.*$" + "plugin:hyprbars:nobar, class:^[Ww]aydroid.*$" "plugin:hyprbars:nobar, class:^Xdg-desktop-portal-gtk$" "plugin:hyprbars:nobar, title:^Picture.in.[Pp]icture$" ]; diff --git a/options/custom/desktops/hyprland/rules.nix b/options/custom/desktops/hyprland/rules.nix index d432dc5..879bfc6 100644 --- a/options/custom/desktops/hyprland/rules.nix +++ b/options/custom/desktops/hyprland/rules.nix @@ -48,6 +48,37 @@ in { ### Static geometry rules tr = num: toString (builtins.floor num); # Convert truncated float to string + # Bottom center + android = rec { + x = tr (width / scale / 2 - (toInt w) / 2); + y = tr (height + / scale + - (toInt h) + - gap + - padding + + ( + if ultrawide + then - border # Cause unknown + else 0 + )); + w = tr ( + width + / scale + * ( + if ultrawide + then 0.5 # 50% + else 1 + ) + + ( + if ultrawide + then - gap / 2 * 2 # Center layout padding between windows + else - gap * 2 + ) + - border * 2 + ); + h = tr (height / scale * 0.5); # 50% + }; + # Bottom center clipboard = rec { x = tr (width / scale / 2 - (toInt w) / 2); @@ -217,7 +248,7 @@ in { (fullscreen true ["idleinhibit focus"]) (pinned true ["bordercolor rgb(073642) rgb(073642)"]) - (tag.android ["idleinhibit always" "tile" "workspace special:android"]) + (tag.android ["idleinhibit always" "move ${android.x} ${android.y}" "size ${android.w} ${android.h}" "workspace special:android"]) (tag.clipboard ["move ${clipboard.x} ${clipboard.y}" "pin" "size ${clipboard.w} ${clipboard.h}" "stayfocused"]) (tag.dropdown ["move ${dropdown.x} ${dropdown.y}" "pin" "size ${dropdown.w} ${dropdown.h}"]) (tag.editor ["group override set" "tile"])