Dotfiles/desktopenvs/hyprlua/hypr/layouts/scrolling.lua

28 lines
1.2 KiB
Lua

-- Scrolling: an infinite row/column of windows you scroll through. The session
-- default. Adjustable from the menu:
-- * direction (down by default) — see M.set() in init.lua.
-- * focus_fit_method 0/1 ("Centered follow") — see M.set_fit(); when centered the
-- focused column is centred and the previous/next columns peek in from the sides.
--
-- column_width is kept < 1.0 (0.5) so the active column is narrower than the viewport
-- and the prev/next columns stay on-screen and clickable. fullscreen_on_one_column
-- lets a lone window still fill the screen, so the narrow width costs nothing alone.
return {
name = "scrolling",
label = "Scrolling",
backend = "scrolling", -- hyprland general.layout value
directional = true,
dirs = { "down", "up", "right", "left" },
default_dir = "down",
fit_method = true, -- exposes the "Centered follow" toggle in the menu
config = {
scrolling = {
direction = "down",
column_width = 0.5,
focus_fit_method = 1,
follow_focus = true,
fullscreen_on_one_column = true,
},
},
}