OPINIONATED OMARCHY
TROUBLESHOOTING CORPUS
790
RECORDS
790
AUDITED
0
UNCHECKED
2388
SOURCES
LIVE
hyprland-config low occasional DISPUTE

Fix gaps, borders and rounding in looknfeel.lua being ignored on Omarchy 4

omarchyhyprland
CORRECTED An auditor found the fix wrong or incomplete and rewrote it. · checked against Omarchy omarchy 4.0.4-1 on 2026-10-05
AUDIT NOTE

Mechanism confirmed on 4.0.4-1. default/hypr/bindings/utilities.lua:20 binds SUPER+SHIFT+BACKSPACE to omarchy-hyprland-window-gaps-toggle, which runs omarchy-hyprland-toggle window-no-gaps. That script copies $OMARCHY_PATH/default/hypr/toggles/window-no-gaps.lua into ~/.local/state/omarchy/toggles/hypr/, off removes it, and every path ends in hyprctl reload. window-no-gaps.lua sets gaps_out, gaps_in, border_size and rounding to 0. The user hyprland.lua requires hypr.looknfeel before default.hypr.toggles, which loads every .lua in the state dir through require_all, so the toggle wins. SUPER+CTRL+BACKSPACE (utilities.lua:21) and single-window-aspect-ratio.lua { 1, 1 } confirmed. hyprctl getoption general.gaps_in printed css gap data: 5 5 5 5 here. Two small inaccuracies in the fix. flags.lua is not empty, it holds two comment lines. And the 'directory always needs one file' warning is in flags.lua's own comment, not in the script. The fix was rewritten with those two points correct and nothing else changed. Not exercised: the toggle was not pressed.

The cause above was not rewritten and may still contain the error described. The fix below is the corrected version.

Symptom

I set gaps_in, gaps_out, border_size or rounding in ~/.config/hypr/looknfeel.lua and they have no effect: windows sit edge to edge with no border no matter what I write, and it survives reboots and omarchy update. It started after I pressed something by accident.

Cause

Omarchy 4 has a permanent toggle for this. SUPER+SHIFT+BACKSPACE runs omarchy-hyprland-window-gaps-toggle, which calls omarchy-hyprland-toggle window-no-gaps. That copies /usr/share/omarchy/default/hypr/toggles/window-no-gaps.lua to ~/.local/state/omarchy/toggles/hypr/window-no-gaps.lua and reloads Hyprland. The file sets gaps_out = 0, gaps_in = 0, border_size = 0 and rounding = 0.

Load order makes it win. ~/.config/hypr/hyprland.lua requires Omarchy's defaults, then your hypr.monitors, hypr.input, hypr.bindings, hypr.looknfeel, hypr.autostart, and only then require("default.hypr.toggles"), which loads every .lua file in ~/.local/state/omarchy/toggles/hypr/. So the toggle overrides looknfeel.lua. Because the state file persists, the override survives reboots and updates. SUPER+CTRL+BACKSPACE does the same thing for single-window-aspect-ratio.lua, which forces layout.single_window_aspect_ratio = { 1, 1 }.

Fix

**See which toggles are active:**


ls ~/.local/state/omarchy/toggles/hypr/
# flags.lua is always there and holds only comments. Anything else is an active toggle.

**Turn the gaps toggle off.** Press SUPER+SHIFT+BACKSPACE again, or:


omarchy-hyprland-toggle window-no-gaps off
omarchy-hyprland-toggle single-window-aspect-ratio off   # if that one is on too

The script removes the state file and runs hyprctl reload itself. Do not delete flags.lua. Its own comment says the directory always needs at least one file.

**If you want your values to win even while a toggle is on**, set them below the toggles line in ~/.config/hypr/hyprland.lua instead of in looknfeel.lua:


-- Toggle config flags dynamically.
require("default.hypr.toggles")

hl.config({ general = { gaps_in = 5, gaps_out = 10, border_size = 2 } })

That makes the SUPER+SHIFT+BACKSPACE toggle do nothing, so pick one approach.

Verify

ls ~/.local/state/omarchy/toggles/hypr/ shows only flags.lua, and hyprctl getoption general.gaps_in reports your value (Omarchy's default prints css gap data: 5 5 5 5). Load order and toggle mechanics were read from the 4.0.4 files on this machine. The toggle was not pressed during this check.

Sources

omarchy-window-gaps-toggle-overrides-looknfeel