fix(hyprland): anchor dolphin window to bottom-right, avoid off-screen clipping

Cursor-based move formula computed position from window_w/window_h before
the rule's own size directive resized the window, pushing it far past the
screen edge. Compute the target position directly from the same size
formula instead.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-09-21 20:24:44 +02:00
co-authored by Claude Sonnet 5
parent 47b461c4c0
commit 244358a99e
+2 -2
View File
@@ -62,8 +62,8 @@ hl.window_rule({
float = true, float = true,
size = { "max(monitor_w, monitor_h)*0.50", "min(monitor_w, monitor_h)*0.55" }, size = { "max(monitor_w, monitor_h)*0.50", "min(monitor_w, monitor_h)*0.55" },
move = { move = {
"max(20, min(cursor_x - (window_w*0.50), monitor_w - window_w + 20))", -- X axis clamping "monitor_w - (max(monitor_w, monitor_h)*0.50) - 20", -- X axis: always align to screen right (20px margin)
"max(20, min(cursor_y - 50, monitor_h - window_h + 20))" -- Y axis clamping "monitor_h - (min(monitor_w, monitor_h)*0.55) - 20" -- Y axis: always align to screen bottom (20px margin)
}, },
}) })