1

Modules/Hyprland: Update to current config format

This commit is contained in:
2025-12-14 16:14:07 +01:00
parent 1643f30906
commit 7b4c2df7af

View File

@ -111,19 +111,19 @@
windowrule = let windowrule = let
mkWorkspaceRule = workspace: class: mkWorkspaceRule = workspace: class:
"workspace ${workspace}, " "match:class ^(${class})$, "
+ "class:^(${class})$"; + "workspace ${workspace}";
mkWorkspaceRules = workspace: class-list: mkWorkspaceRules = workspace: class-list:
builtins.map (mkWorkspaceRule workspace) class-list; builtins.map (mkWorkspaceRule workspace) class-list;
mkFloatingRule = attrs: mkFloatingRule = attrs:
"float" (lib.optionalString (builtins.hasAttr "class" attrs) "match:class ^(${attrs.class})$, ")
+ (lib.optionalString (builtins.hasAttr "class" attrs) ", class:^(${attrs.class})$") + (lib.optionalString (builtins.hasAttr "title" attrs) "match:title ^(${attrs.title})$, ")
+ (lib.optionalString (builtins.hasAttr "title" attrs) ", title:^(${attrs.title})$"); + "float 1";
mkTranslucentRule = class: mkTranslucentRule = class:
"opacity ${hyprland.transparent-opacity} ${hyprland.transparent-opacity}, " "match:class ^(${class})$, "
+ "class:^(${class})$"; + "opacity ${hyprland.transparent-opacity} ${hyprland.transparent-opacity}";
in in
lib.mkMerge [ lib.mkMerge [
(hyprland.workspacerules (hyprland.workspacerules
@ -165,15 +165,15 @@
# Because those are not windows, but layers, # Because those are not windows, but layers,
# we have to blur them explicitly # we have to blur them explicitly
layerrule = [ layerrule = [
"blur,rofi" "match:class rofi, blur 1"
"ignorealpha 0.001,rofi" # Fix pixelated corners # "match:class rofi, ignore_alpha 0.001" # Fix pixelated corners
"xray 0,rofi" # Render on top of other windows # "match:class rofi, xray 0" # Render on top of other windows
"dimaround,rofi" # "match:class rofi, dim_around 1"
"blur,waybar" "match:class waybar, blur 1"
"blur,gtk4-layer-shell" "match:class gtk4-layer-shell, blur 1"
"blur,bar-0" "match:class bar-0, blur 1"
"blur,bar-1" "match:class bar-1, blur 1"
]; ];
decoration = { decoration = {