11e4e94ee8
Lua config (hyprland.d.lua):
- keybinds: layout-aware binds now read the per-workspace layout via
cur_ws_layout() instead of the global hl.get_config("general.layout"),
fixing mouse-wheel/bracket scrolling and ratio keys on the lua:*-scroll
layouts.
- add state.lua shared module (ws_layouts) replacing the _G globals.
- layout: factor the 9 duplicated layout_msg bodies into scroll_msg/swap_msg
builders; drop a dead #state expression.
- rules: NO_BLUELIGHT window.open handler no longer leaks a rule per open
(one per class) and regex-escapes/nil-guards the class.
- monitors: quote non-numeric scale so scale="auto" renders.
- drop debug print() focus handler, local-next shadowing, stray {mouse=true}
on wheel binds (kept on drag/resize, which require it).
Quickshell:
- brightness OSD is now event-driven: Osd.qml gains an IpcHandler(target:osd)
and the keybind pushes the new level via `qs ipc call osd brightness`,
removing the always-on 500ms brightnessctl poll.
- GamemodePill watches GameMode's D-Bus signals via gdbus monitor instead of
polling gamemoded --status every 5s.
Cleanup:
- remove stock hyprland.lua.refactor/ boilerplate and the redundant,
partly-wrong hyprland_lua_api.md (both were deployed into ~/.config/hypr;
.luarc.json already points the LSP at /usr/share/hypr/stubs).
- refresh hypr/AGENTS.md (lua layout) and quickshell/CLAUDE.md (v0.3.0).
36 lines
996 B
Cheetah
36 lines
996 B
Cheetah
{{- range .monitors }}
|
|
hl.monitor({
|
|
output = "{{ .name }}",
|
|
mode = "{{ .width }}x{{ .height }}@{{ .refresh_rate }}",
|
|
position = "{{ .position }}",
|
|
scale = {{ if kindIs "string" .scale }}"{{ .scale }}"{{ else }}{{ .scale }}{{ end }}
|
|
{{- if hasKey . "vrr" }},
|
|
vrr = {{ .vrr }}
|
|
{{- end }}
|
|
{{- if hasKey . "transform" }},
|
|
transform = {{ .transform }}
|
|
{{- end }}
|
|
{{- if hasKey . "bitdepth" }},
|
|
bitdepth = {{ .bitdepth }}
|
|
{{- end }}
|
|
{{- if hasKey . "cm" }},
|
|
cm = "{{ .cm }}"
|
|
{{- end }}
|
|
{{- if hasKey . "supports_hdr" }},
|
|
supports_hdr = {{ .supports_hdr }}
|
|
{{- end }}
|
|
{{- if hasKey . "sdrbrightness" }},
|
|
sdrbrightness = {{ .sdrbrightness }}
|
|
{{- end }}
|
|
{{- if hasKey . "sdrsaturation" }},
|
|
sdrsaturation = {{ .sdrsaturation }}
|
|
{{- end }}
|
|
{{- if hasKey . "max_luminance" }},
|
|
max_luminance = {{ .max_luminance }}
|
|
{{- end }}
|
|
})
|
|
{{- end }}
|
|
{{- if not .monitors }}
|
|
hl.monitor({ output = "", mode = "preferred", position = "auto", scale = 1 })
|
|
{{- end }}
|