hyprland: make Hyprspace the primary overview

This commit is contained in:
2026-05-15 01:16:46 -07:00
parent 8250cfdbc9
commit 724fb61054
4 changed files with 19 additions and 13 deletions

View File

@@ -89,7 +89,7 @@ function M.setup(ctx)
local function setup_window_overview_bindings() local function setup_window_overview_bindings()
bind(main_mod .. " + SHIFT + C", hl.dsp.window.close(), desc("Close active window")) bind(main_mod .. " + SHIFT + C", hl.dsp.window.close(), desc("Close active window"))
bind(main_mod .. " + SHIFT + Q", hl.dsp.exit(), desc("Exit Hyprland")) bind(main_mod .. " + SHIFT + Q", hl.dsp.exit(), desc("Exit Hyprland"))
bind(main_mod .. " + Tab", hyprexpo("toggle"), desc("Toggle workspace expo", overview_bind_opts)) bind(main_mod .. " + Tab", hyprspace("toggle"), desc("Toggle Hyprspace workspace overview", overview_bind_opts))
bind(main_mod .. " + SHIFT + Tab", hyprwinview({ bind(main_mod .. " + SHIFT + Tab", hyprwinview({
action = "show", action = "show",
include_current_workspace = false, include_current_workspace = false,
@@ -97,12 +97,8 @@ function M.setup(ctx)
default_action = "bring", default_action = "bring",
}), desc("Show all-workspace window overview", overview_bind_opts)) }), desc("Show all-workspace window overview", overview_bind_opts))
bind(main_mod .. " + SHIFT + slash", hyprwinview({ action = "toggle-filter" }), desc("Toggle window overview filter", overview_bind_opts)) bind(main_mod .. " + SHIFT + slash", hyprwinview({ action = "toggle-filter" }), desc("Toggle window overview filter", overview_bind_opts))
bind("ALT + Tab", enable_hyprspace and hyprspace("toggle") or hyprwinview({ bind("ALT + Tab", hyprexpo("toggle"), desc("Toggle hyprexpo workspace overview", overview_bind_opts))
action = "show", bind("ALT + SHIFT + Tab", hyprexpo("on"), desc("Open hyprexpo workspace overview", overview_bind_opts))
start_in_filter_mode = true,
default_action = "select",
}), desc("Toggle alternate window overview", overview_bind_opts))
bind("ALT + SHIFT + Tab", hyprexpo("on"), desc("Open workspace expo", overview_bind_opts))
bind(main_mod .. " + G", hyprwinview({ bind(main_mod .. " + G", hyprwinview({
action = "show", action = "show",
start_in_filter_mode = true, start_in_filter_mode = true,

View File

@@ -177,9 +177,19 @@ function M.setup(ctx)
local function hyprspace(action) local function hyprspace(action)
return function() return function()
overview_trace("hyprspace " .. tostring(action or "toggle")) local request = action
if type(request) == "table" then
request.action = request.action or "toggle"
if request.all == nil then
request.all = true
end
else
request = { action = action or "toggle", all = true }
end
overview_trace("hyprspace " .. tostring(request.action))
if hl.plugin and hl.plugin.hyprspace and hl.plugin.hyprspace.overview then if hl.plugin and hl.plugin.hyprspace and hl.plugin.hyprspace.overview then
hl.plugin.hyprspace.overview({ action = action or "toggle" }) hl.plugin.hyprspace.overview(request)
else else
hl.notification.create({ hl.notification.create({
text = "hyprspace is not loaded", text = "hyprspace is not loaded",

View File

@@ -63,7 +63,7 @@ return {
current_layout = columns_layout, current_layout = columns_layout,
enable_nstack = true, enable_nstack = true,
enable_hyprexpo = true, enable_hyprexpo = true,
enable_hyprspace = env_bool("HYPRLAND_ENABLE_HYPRSPACE", false), enable_hyprspace = env_bool("HYPRLAND_ENABLE_HYPRSPACE", true),
enable_hyprwinview = true, enable_hyprwinview = true,
enable_workspace_history = true, enable_workspace_history = true,
enable_hyprwobbly = true, enable_hyprwobbly = true,

6
nixos/flake.lock generated
View File

@@ -10,11 +10,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1778761768, "lastModified": 1778832075,
"narHash": "sha256-1i9S0IRjUuz98ab9/V2+5ax5YxIDhvl7NuMlBVXJ328=", "narHash": "sha256-q+5ETwj+oiZBT9j6/huwB8nwV4nbZdZmCrchL2E7tDQ=",
"owner": "colonelpanic8", "owner": "colonelpanic8",
"repo": "Hyprspace", "repo": "Hyprspace",
"rev": "2ca4f1a47cf2dc569e6e7034e53c4cd9b25e36a8", "rev": "bf2ef21007e8963fcb0016ae26b6b21704946f80",
"type": "github" "type": "github"
}, },
"original": { "original": {