-- Window rules are kept as data and registered in order at the bottom. This -- makes adding a rule independent from the registration mechanism. local rules = { -- Render terminal image previews as undecorated, non-focusing overlays. { name = "ueberzugpp-preview", match = { class = "ueberzugpp_.*", }, float = true, no_initial_focus = true, border_size = 0, rounding = 0, no_shadow = true, }, -- Ignore application requests to maximize themselves. { name = "suppress-maximize-events", match = { class = ".*", }, suppress_event = "maximize", }, -- Prevent empty XWayland drag helper windows from stealing focus. { name = "fix-xwayland-drags", match = { class = "^$", title = "^$", xwayland = true, float = true, fullscreen = false, pin = false, }, no_focus = true, }, -- Place the Hyprland runner near the lower-left edge as a floating window. { name = "move-hyprland-run", match = { class = "hyprland-run", }, move = "20 monitor_h-120", float = true, }, { name = "confine-dota2-cursor", match = { class = "dota2", }, confine_pointer = true, }, } -- Register every declarative rule with Hyprland. for _, rule in ipairs(rules) do hl.window_rule(rule) end