mirror of
https://github.com/Theaninova/TheaninovOS.git
synced 2026-01-23 01:52:46 +00:00
feat: hyprland scrolling
This commit is contained in:
@@ -13,13 +13,17 @@ let
|
||||
hyprctl clients -j | jq -r "map(select(.workspace.id == $WORKSPACE) | select(.class == \"$1\") | .address | select(. != $WINDOW)) | .[0]"
|
||||
'';
|
||||
};
|
||||
cfg = osConfig.desktops.hyprland;
|
||||
in
|
||||
{
|
||||
config = lib.mkIf osConfig.desktops.hyprland.enable {
|
||||
config = lib.mkIf cfg.enable {
|
||||
wayland.windowManager.hyprland = {
|
||||
enable = true;
|
||||
settings = {
|
||||
general.allow_tearing = true;
|
||||
general = {
|
||||
allow_tearing = true;
|
||||
layout = lib.mkIf cfg.scrolling "scrolling";
|
||||
};
|
||||
input = {
|
||||
accel_profile = "flat";
|
||||
kb_layout = osConfig.services.xserver.xkb.layout;
|
||||
@@ -32,23 +36,43 @@ in
|
||||
"SUPER,D,fullscreen,1"
|
||||
"SUPER,V,fullscreen,0"
|
||||
|
||||
"SUPER_SHIFT,up,movewindow,u"
|
||||
"SUPER_SHIFT,down,movewindow,d"
|
||||
"SUPER_SHIFT,left,movewindow,l"
|
||||
"SUPER_SHIFT,right,movewindow,r"
|
||||
|
||||
"SUPER,up,movefocus,u"
|
||||
"SUPER,down,movefocus,d"
|
||||
"SUPER,left,movefocus,l"
|
||||
"SUPER,right,movefocus,r"
|
||||
|
||||
"SUPER,f,workspace,r-1"
|
||||
"SUPER,h,workspace,r+1"
|
||||
"SUPER_SHIFT,f,movetoworkspace,r-1"
|
||||
"SUPER_SHIFT,h,movetoworkspace,r+1"
|
||||
"SUPER,mouse_up,workspace,r+1"
|
||||
"SUPER,mouse_down,workspace,r-1"
|
||||
];
|
||||
]
|
||||
++ (
|
||||
if cfg.scrolling then
|
||||
[
|
||||
"SUPER,up,layoutmsg,focus u"
|
||||
"SUPER,down,layoutmsg,focus d"
|
||||
"SUPER,right,layoutmsg,focus r"
|
||||
"SUPER,left,layoutmsg,focus l"
|
||||
|
||||
"SUPER_SHIFT,up,layoutmsg,movewindowto u"
|
||||
"SUPER_SHIFT,down,layoutmsg,movewindowto d"
|
||||
"SUPER_SHIFT,left,layoutmsg,swapcol l"
|
||||
"SUPER_SHIFT,right,layoutmsg,swapcol r"
|
||||
|
||||
"SUPER,mouse_up,layoutmsg,focus r"
|
||||
"SUPER,mouse_down,layoutmsg,focus l"
|
||||
]
|
||||
else
|
||||
[
|
||||
"SUPER_SHIFT,up,movewindow,u"
|
||||
"SUPER_SHIFT,down,movewindow,d"
|
||||
"SUPER_SHIFT,left,movewindow,l"
|
||||
"SUPER_SHIFT,right,movewindow,r"
|
||||
|
||||
"SUPER,up,movefocus,u"
|
||||
"SUPER,down,movefocus,d"
|
||||
"SUPER,left,movefocus,l"
|
||||
"SUPER,right,movefocus,r"
|
||||
|
||||
"SUPER,mouse_up,workspace,r+1"
|
||||
"SUPER,mouse_down,workspace,r-1"
|
||||
]
|
||||
);
|
||||
bindm = [
|
||||
"SUPER,mouse:272,movewindow"
|
||||
"SUPER,mouse:273,resizewindow"
|
||||
|
||||
Reference in New Issue
Block a user