diff --git a/home-manager/modules/sway.nix b/home-manager/modules/sway.nix index dc5088d..ae7a896 100644 --- a/home-manager/modules/sway.nix +++ b/home-manager/modules/sway.nix @@ -191,6 +191,30 @@ in }; }; + extraConfig = '' + # Display window as floating. Find out wayland app_id with "swaymsg -t get_tree | jq '.' | grep app_id" and xorg class with xprop + # mostly stolen from https://github.com/madic-creates/Sway-DE/blob/master/config/sway/sway.d/06_floating.conf + for_window [app_id = "floating"] floating enable + for_window [app_id = "floating_update"] floating enable, resize set width 1000px height 600px + for_window [app_id = "firefox" title="Library"] floating enable, border pixel 1, sticky enable + for_window [title = "Extension: (Bitwarden Password Manager) - Bitwarden — Mozilla Firefox"] floating enable + for_window [app_id = "wdisplays"] floating enable, resize set width 1150px height 480px + for_window [class = "(?i)pinentry"] floating enable + for_window [title = "(?:Open|Save) (?:File|Folder|As)"] floating enable, resize set width 1030 height 710 + for_window [title = "About Mozilla Firefox"] floating enable + for_window [title = "Firefox - Choose User Profile" ] floating enable + for_window [title = "Firefox — Sharing Indicator"] floating enable + for_window [window_role = "GtkFileChooserDialog"] resize set 590 340 + for_window [window_role = "bubble"] floating enable + for_window [window_role = "dialog"] floating enable + for_window [window_role = "pop-up"] floating enable + for_window [window_role = "task_dialog"] floating enable + for_window [window_type = "dialog"] floating enable + for_window [window_type = "menu"] floating enable + + # Tag xwayland windows with [X] + for_window [shell="xwayland"] title_format "[X] %title゜" + ''; }; }