From 2b9b99fb4d73dcc2db85c73de69d5a5bc7635ad8 Mon Sep 17 00:00:00 2001 From: Andre Ramnitz Date: Mon, 2 Mar 2026 22:39:32 +0100 Subject: [PATCH] Reapply "hypr: update config for 0.54.0 and cleanup" This reverts commit dd4f61d4845b1fd6192ea68f0ff9cfaadd90f0ef. --- dot-config/hypr/fragments/keybinds.conf | 95 ++---------------- dot-config/hypr/fragments/windowrules.conf | 4 +- dot-config/hypr/fragments/workspacerules.conf | 11 ++- dot-config/hypr/hyprland.conf | 22 ++++- dot-config/hypr/scripts/custom-accel-macos.py | 98 ------------------- dot-config/hypr/scripts/gaps.sh | 53 ---------- dot-config/hypr/scripts/workspace.sh | 64 ------------ 7 files changed, 39 insertions(+), 308 deletions(-) delete mode 100644 dot-config/hypr/scripts/custom-accel-macos.py delete mode 100755 dot-config/hypr/scripts/gaps.sh delete mode 100755 dot-config/hypr/scripts/workspace.sh diff --git a/dot-config/hypr/fragments/keybinds.conf b/dot-config/hypr/fragments/keybinds.conf index 38cc92de..d5ea90f6 100644 --- a/dot-config/hypr/fragments/keybinds.conf +++ b/dot-config/hypr/fragments/keybinds.conf @@ -14,15 +14,12 @@ $floatterm = foot -o pad=0x0 -a popup # mainmod shortcuts # ─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────── -# example: bind = $mainmod Shift, Return, exec, [float; size 1280 800;] foot -o pad=0x0 bind = $mainmod, Return, exec, $term bind = $mainmod Ctrl, Return, exec, $fallbackterm bind = $mainmod Shift, Return, exec, $floatterm bind = $mainmod Shift, Q, killactive, bind = $mainmod, A, pseudo, # dwindle, A for Artificial bind = $mainmod, B, exec, $HOME/.config/hypr/scripts/browser_focus_or_run.sh -# bind = $mainmod, C, exec, killall fuzzel || cliphist list | fuzzel -d --config=$HOME/.config/fuzzel/fuzzel-emojii.ini --prompt='Copy > ' | cliphist decode | wl-copy -# bind = $mainmod Ctrl, C, exec, foot -a clipse -e clipse bind = $mainmod, C, exec, qs -c noctalia-shell ipc call launcher clipboard bind = $mainmod, D, exec, qs -c noctalia-shell ipc call launcher toggle bind = $mainmod SHIFT, D, exec, killall fuzzel || fuzzel --config=$HOME/.config/fuzzel/fuzzel-centered.ini @@ -34,20 +31,19 @@ bind = $mainmod, G, togglegroup bind = $mainmod SHIFT, G, lockactivegroup, toggle bind = $mainmod CTRL, G, denywindowfromgroup, toggle bind = $mainmod ALT, G, moveoutofgroup, active +bind = $mainmod, I, togglespecialworkspace, overlay +bind = $mainmod SHIFT, I, movetoworkspace, special:overlay bind = $mainmod, P, exec, foot -w 640x400 -a popup -H hyprpicker #color Pipette bind = $mainmod SHIFT, P, pin -bind = $mainmod, S, layoutmsg, swapwithmaster # master -bind = $mainmod, S, togglesplit, # dwindle -bind = $mainmod Shift, S, swapsplit, # dwindle +bind = $mainmod, S, layoutmsg, togglesplit # dwindle +bind = $mainmod Shift, S, layoutmsg, swapsplit # dwindle +bind = $mainmod, S, layoutmsg, colresize +conf # scrolling +bind = $mainmod Shift, S, layoutmsg, colresize -conf # scrolling bind = $mainmod, V, togglefloating bind = $mainmod, W, exec, killall -SIGUSR1 waybar bind = $mainmod SHIFT, W, exec, killall -SIGUSR2 waybar -# bind = $mainmod, grave, exec, ~/.config/hypr/scripts/RofiEmoji.sh +bind = $mainmod, Z, centerwindow # floating only bind = $mainmod, grave, exec, qs -c noctalia-shell ipc call launcher emoji -bind = $mainmod, C, centerwindow -# scratchpad -bind = $mainmod, I, togglespecialworkspace, overlay -bind = $mainmod SHIFT, I, movetoworkspace, special:overlay # suremod keys (prevent fat-fingering 'em by accident) # ─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────── @@ -213,80 +209,3 @@ bind = , catchall, submap, reset submap = reset -# ─────────────────────────────────────────────────────────── -# will switch to a submap called gaps -bind = $mainmod ALT, G, submap, gaps - -# will start a submap called "gaps" -submap = gaps - -# sets repeatable binds for resizing the active window -binde = , i, exec, ~/.config/hypr/scripts/gaps.sh --inc_gaps_in -binde = SHIFT, i, exec, ~/.config/hypr/scripts/gaps.sh --dec_gaps_in -binde = , o, exec, ~/.config/hypr/scripts/gaps.sh --inc_gaps_out -binde = SHIFT, o, exec, ~/.config/hypr/scripts/gaps.sh --dec_gaps_out -binde = CTRL, i, exec, ~/.config/hypr/scripts/gaps.sh --reset_gaps_in -binde = CTRL, o, exec, ~/.config/hypr/scripts/gaps.sh --reset_gaps_out - -# use reset to go back to the global submap -bind = , catchall, submap, reset - -# will reset the submap, which will return to the global submap -submap = reset - - -# ─────────────────────────────────────────────────────────── -# will switch to a submap called resize16-9 -bind = $mainmod, Z, submap, resize16-9 - -# will start a submap called "gaps" -submap = resize16-9 - -# sets repeatable binds for resizing the active window -bind = , 1, exec, hyprctl dispatch 'resizewindowpixel exact 640 360,activewindow' -bind = , 1, exec, submap, reset -bind = , 2, exec, hyprctl dispatch 'resizewindowpixel exact 853 480,activewindow' -bind = , 2, exec, submap, reset -bind = , 3, exec, hyprctl dispatch 'resizewindowpixel exact 1280 720,activewindow' -bind = , 3, exec, submap, reset -bind = , 4, exec, hyprctl dispatch 'resizewindowpixel exact 1920 1080,activewindow' -bind = , 4, exec, submap, reset -bind = , 5, exec, hyprctl dispatch 'resizewindowpixel exact 2400 1350,activewindow' -bind = , 5, exec, submap, reset -bind = , 6, exec, hyprctl dispatch 'resizewindowpixel exact 2560 1440,activewindow' -bind = , 6, exec, submap, reset - -# use reset to go back to the global submap -bind = , catchall, submap, reset - -# will reset the submap, which will return to the global submap -submap = reset - - -# ─────────────────────────────────────────────────────────── -# will switch to a submap called resize16-10 -bind = $mainmod Shift, Z, submap, resize12-10 - -# will start a submap called "gaps" -submap = resize12-10 - -# sets repeatable binds for resizing the active window -bind = , 1, exec, hyprctl dispatch 'resizewindowpixel exact 432 360,activewindow' -bind = , 1, exec, submap, reset -bind = , 2, exec, hyprctl dispatch 'resizewindowpixel exact 576 480,activewindow' -bind = , 2, exec, submap, reset -bind = , 3, exec, hyprctl dispatch 'resizewindowpixel exact 864 720,activewindow' -bind = , 3, exec, submap, reset -bind = , 4, exec, hyprctl dispatch 'resizewindowpixel exact 1296 1080,activewindow' -bind = , 4, exec, submap, reset -bind = , 5, exec, hyprctl dispatch 'resizewindowpixel exact 1620 1350,activewindow' -bind = , 5, exec, submap, reset -bind = , 6, exec, hyprctl dispatch 'resizewindowpixel exact 1728 1440,activewindow' -bind = , 6, exec, submap, reset - -# use reset to go back to the global submap -bind = , catchall, submap, reset - -# will reset the submap, which will return to the global submap -submap = reset - diff --git a/dot-config/hypr/fragments/windowrules.conf b/dot-config/hypr/fragments/windowrules.conf index b0f63dda..ea38b373 100644 --- a/dot-config/hypr/fragments/windowrules.conf +++ b/dot-config/hypr/fragments/windowrules.conf @@ -131,7 +131,7 @@ windowrule { windowrule { name = windowrule-26 float = on - move = ((monitor_w-window_w)-10) (42) + move = ((monitor_w)-813) (55) size = 800 450 no_initial_focus = on group = deny @@ -153,6 +153,7 @@ windowrule { windowrule { name = popup_class float = on + group = deny size = 1280 800 match:class = ^(popup)$ } @@ -161,6 +162,7 @@ windowrule { name = kakpopup float = 1 stay_focused = 1 + group = deny opacity = 1.0 override move = ((monitor_w-window_w)-10) ((monitor_h-window_h)-10) match:class = ^(kakpopup)$ diff --git a/dot-config/hypr/fragments/workspacerules.conf b/dot-config/hypr/fragments/workspacerules.conf index 23685f03..6575136d 100644 --- a/dot-config/hypr/fragments/workspacerules.conf +++ b/dot-config/hypr/fragments/workspacerules.conf @@ -6,7 +6,14 @@ # workspace rules #example: on-created-empty: exec, something" -workspace = 1, default:1 -workspace = 4, gapsout:40, gapsin:20 +workspace = 1, default:1, layout:dwindle +workspace = 2, layout:scrolling +workspace = 3, layout:monocle +workspace = 4, layout:monocle +workspace = 5, layout:scrolling workspace = 6, float +workspace = 7, layout:scrolling +workspace = 8, layout:scrolling +workspace = 9, layout:scrolling +workspace = 0, layout:dwindle workspace = special:magic diff --git a/dot-config/hypr/hyprland.conf b/dot-config/hypr/hyprland.conf index db24dd3c..ce1b5422 100644 --- a/dot-config/hypr/hyprland.conf +++ b/dot-config/hypr/hyprland.conf @@ -26,8 +26,13 @@ monitor=,preferred,auto-center-right,1,vrr,2 # Execute your favorite apps at launch # exec-once = dbus-update-activation-environment --systemd --all exec-once = /usr/libexec/pam_kwallet_init +# exec-once = /usr/libexec/polkit-gnome-authentication-agent-1 +# exec-once = /usr/libexec/polkit-kde-authentication-agent-1 exec-once = hyprpm reload exec-once = openrc --user hyprland # AFTER pam_kwallet_init!!! +exec-once = /usr/bin/qs -c noctalia-shell +exec-once = /usr/bin/nextcloud +exec-once = /usr/bin/keepassxc # exec-once = env XDG_MENU_PREFIX=plasma- kbuildsycoca6 # Unset variables on exit @@ -50,17 +55,30 @@ general { # col.nogroup_border_active = $error } +layout { + single_window_aspect_ratio = 16 9.1 + single_window_aspect_ratio_tolerance = 0.1 +} + dwindle { pseudotile = yes force_split = 2 smart_split = 0 split_width_multiplier = 2.0 - single_window_aspect_ratio = 16 9.1 - single_window_aspect_ratio_tolerance = 0.1 pseudotile = 1 # master switch for pseudotiling. Enabling is bound to mainMod + A in the keybinds section below preserve_split = 1 # you probably want this } +scrolling { + fullscreen_on_one_column = 1 + column_width = 0.5 # default = 0.5 + focus_fit_method = 1 + follow_focus = 1 + follow_min_visible = 0.4 + explicit_column_widths = 0.333,0.5,0.667,1.0 + direction = right +} + master { new_status = slave allow_small_split = 1 diff --git a/dot-config/hypr/scripts/custom-accel-macos.py b/dot-config/hypr/scripts/custom-accel-macos.py deleted file mode 100644 index 48024009..00000000 --- a/dot-config/hypr/scripts/custom-accel-macos.py +++ /dev/null @@ -1,98 +0,0 @@ -#!/usr/bin/env python3 - -# based on https://gist.github.com/fufexan/de2099bc3086f3a6c83d61fc1fcc06c9 - -import struct -import os -import sys -import math - -# ===== PARAMETERS ===== -# set according to your device: -device_dpi = 2048 * 1.5 # mouse dpi -screen_dpi = 163 -screen_scaling_factor = 1 -sample_point_count = 20 -sensitivity_factor = 6 - -def sigmoid(x, a=1.0): - return 1 / (1 + math.exp(-a * (x - 0.5))) - -def find_arg(arg): - for i in sys.argv: - if i == arg: - return True - return False - -def float16x16(num): - return struct.unpack('') - print('To get the device, run `hyprctl devices` and get its name') - exit(0) - -# Make sure the device is passed as the first argument -if len(sys.argv) < 2: - print("Error: device not specified. Usage: