Skip to content

Coming from Hyprland or niri ​

In Hyprland and niri you set options and the compositor does the rest. In Hazel the config is a Lua program, and the behaviour you know is a few lines of it. Most rows below link to a recipe that has those lines.

HyprlandniriHazel
bind = SUPER, Return, exec, footMod+Return { spawn "foot"; }bind(mod, "Return", function() spawn("foot") end), from your first config
bindm = SUPER, mouse:272, movewindowdrag with Mod helda pointer_button handler: Dragging windows
exec-once = waybarspawn-at-startup "waybar"if not wm.is_reload then spawn("waybar") end
exec = ...spawn(...) at the top level, which runs on every reload
env = QT_QPA_PLATFORM,waylandenvironment { }spawn_env.QT_QPA_PLATFORM = "wayland": Session
windowrule = float, class:pavucontrolwindow-rule { match app-id=...; open-floating true; }a check on window.app_id when the window first draws: Window rules
monitor = DP-1, 2560x1440@144, 0x0, 1output "DP-1" { mode ...; position ...; }an added handler on wm.outputs: Monitor layout
input { kb_layout = us }input { keyboard { xkb { layout "us"; } } }keyboard.layout = "us": Keyboard layout
natural_scroll = truenatural-scrolla pointer_scroll handler: Natural scrolling
gaps_in, border_size, col.active_bordergaps, focus-ring, bordergap in Tiling, and Borders
roundinggeometry-corner-radiuswindow.box.corner_radius = 8
inactive_opacityFocus fades
bezier, animation = windows, ...animations { window-movement { spring ...; } }Anim.spring and Anim.tween on any property: Animation
general:layout = dwindle or masterthe scrolling layouta function from area and windows to rectangles: Layouts
bind = SUPER, 1, workspace, 1Mod+1 { focus-workspace 1; }Workspaces
hyprctl dispatch ..., hyprctl clientsniri msg ...hazel eval '<lua>': Debugging
hyprctl reloadreloads on savereloads on save, or wm:reload()
hyprlock, hypridleswaylock, swayidlethe same programs: Panels and lock screens
XWaylandxwayland-satellitexwayland-satellite: X apps

Nothing happens by default. A config with no new_window handler leaves every window at the top-left corner, unfocused. That's why your first config is the base every recipe builds on.

Not there yet: blur, touchpad settings such as tap-to-click and pointer acceleration, and turning monitors off when idle.