feat(hyprlua): spawn filepicker dialog at cursor via +at-cursor tag
Add a dedicated at-cursor window rule (float + move to cursor) and point the Super+F / Super+Shift+F filepicker binds at it, so the zenity dialog opens centered on the mouse instead of mid-screen. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>feat/astal-menu
parent
403023c096
commit
3324e669bb
|
|
@ -52,8 +52,8 @@ hl.bind(mainMod .. " + SHIFT + R", hl.dsp.exec_cmd("wofi --show drun"))
|
||||||
hl.bind("CTRL + SHIFT + R", hl.dsp.exec_cmd(menu))
|
hl.bind("CTRL + SHIFT + R", hl.dsp.exec_cmd(menu))
|
||||||
|
|
||||||
-- File picker dialog -> clipboard (path / contents)
|
-- File picker dialog -> clipboard (path / contents)
|
||||||
hl.bind(mainMod .. " + F", hl.dsp.exec_cmd("[tag +centered] ~/.config/scripts/filepicker-clipboard.sh path"))
|
hl.bind(mainMod .. " + F", hl.dsp.exec_cmd("[tag +at-cursor] ~/.config/scripts/filepicker-clipboard.sh path"))
|
||||||
hl.bind(mainMod .. " + SHIFT + F", hl.dsp.exec_cmd("[tag +centered] ~/.config/scripts/filepicker-clipboard.sh content"))
|
hl.bind(mainMod .. " + SHIFT + F", hl.dsp.exec_cmd("[tag +at-cursor] ~/.config/scripts/filepicker-clipboard.sh content"))
|
||||||
-- old:
|
-- old:
|
||||||
-- hl.bind(mainMod .. " + F", hl.dsp.exec_cmd("~/.config/scripts/wofi-file-search.sh"))
|
-- hl.bind(mainMod .. " + F", hl.dsp.exec_cmd("~/.config/scripts/wofi-file-search.sh"))
|
||||||
-- hl.bind(mainMod .. " + SHIFT + F", hl.dsp.exec_cmd("~/.config/scripts/foldersearch.sh"))
|
-- hl.bind(mainMod .. " + SHIFT + F", hl.dsp.exec_cmd("~/.config/scripts/foldersearch.sh"))
|
||||||
|
|
|
||||||
|
|
@ -73,6 +73,14 @@ hl.window_rule({
|
||||||
size = "(monitor_w*0.2) (monitor_h*0.2)",
|
size = "(monitor_w*0.2) (monitor_h*0.2)",
|
||||||
})
|
})
|
||||||
|
|
||||||
|
-- filepicker — float centred at cursor
|
||||||
|
hl.window_rule({
|
||||||
|
name = "at-cursor",
|
||||||
|
match = { tag = "at-cursor" },
|
||||||
|
float = true,
|
||||||
|
move = "(cursor_x-(window_w/2)) (cursor_y-(window_h/2))",
|
||||||
|
})
|
||||||
|
|
||||||
-- spotify floating
|
-- spotify floating
|
||||||
hl.window_rule({
|
hl.window_rule({
|
||||||
name = "spotify-float",
|
name = "spotify-float",
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue