chore(hyprland): keep things up-to-date, outsource windowrules

This commit is contained in:
fbachus
2025-01-10 02:02:50 +01:00
parent 91f12faec9
commit 7503b7774d
6 changed files with 80 additions and 38 deletions

View File

@@ -1,8 +1,11 @@
# Set programs that you use # Set programs that you use
# $terminal = alacritty -e tmux # $terminal = alacritty -e tmux
$terminal = kitty $terminal = kitty
$spotify = spotify --enable-features=UseOzonePlatform --ozone-platform=wayland
$fileManager = dolphin $fileManager = dolphin
$menu = wofi --show drun $menu = wofi --show drun
$appLauncher = tofi-drun | xargs hyprctl dispatch exec -- $appLauncher = tofi-drun | xargs hyprctl dispatch exec --
$lockscreen = hyprlock $lockscreen = hyprlock --immediate
$lockscreen_timeout = hyprlock
$nextcloud = nextcloud --background $nextcloud = nextcloud --background
$clipboard-manager = cliphist list | awk '{gsub("\t", " "); print}' | tofi --width=800 --font-size=14 --font-features="" --background-color=191A1CE0 | cliphist decode | wl-copy

View File

@@ -19,6 +19,9 @@ waybar &
syncthing & syncthing &
nextcloud --background & nextcloud --background &
# clipboard
wl-paste --watch cliphist store &
# network-manager tray icon # network-manager tray icon
NetworkManager & NetworkManager &
nm-applet & nm-applet &
@@ -27,3 +30,4 @@ polkit-kde-authentication-agent-1 &
dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP & dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP &
hypridle & hypridle &
polkit-qt6 & polkit-qt6 &
xwaylandvideobridge &

View File

@@ -14,14 +14,20 @@ bind = $mainMod ALT_L, K, exec, hyprctl switchxkblayout holtek-usb-hid-keyboard
binde = ,XF86AudioLowerVolume, exec, amixer -M -- set Master Playback Switch 1%- binde = ,XF86AudioLowerVolume, exec, amixer -M -- set Master Playback Switch 1%-
binde = ,XF86AudioRaiseVolume, exec, amixer -M -- set Master Playback Switch 1%+ binde = ,XF86AudioRaiseVolume, exec, amixer -M -- set Master Playback Switch 1%+
bind = ,XF86AudioMute, exec, amixer -M -- set Master Playback Switch toggle
# Reduce effects for performance # Reduce effects for performance
bind = WIN, F1, exec, ~/.config/hypr/gamemode.sh bind = WIN, F1, exec, ~/.config/hypr/gamemode.sh
# Clipboard
bind = $mainMod, V, exec, $clipboard-manager
bind = $mainMod SHIFT, V, exec, cliphist wipe
# Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more # Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more
bind = $mainMod, Q, exec, $terminal bind = $mainMod, Q, exec, $terminal
bind = $mainMod, M, exit, bind = $mainMod, M, exit,
bind = $mainMod, E, exec, $fileManager bind = $mainMod, E, exec, $fileManager
bind = $mainMod, V, togglefloating, bind = $mainMod, F, togglefloating,
bind = $mainMod, R, exec, $menu bind = $mainMod, R, exec, $menu
bind = $mainMod, P, pseudo, # dwindle bind = $mainMod, P, pseudo, # dwindle
bind = $mainMod, C, killactive, bind = $mainMod, C, killactive,
@@ -45,6 +51,9 @@ bind = $mainMod, O, fullscreenstate, 1
# lock # lock
bind = $mainMod, F12, exec, $lockscreen bind = $mainMod, F12, exec, $lockscreen
# swap workspaces between monitors
bind = $mainMod ALT_L, s, swapactiveworkspaces, DP-1 DP-2
bind = $mainMod ALT_L, s, swapactiveworkspaces, eDP-1 HDMI-A-2
# Move window in direction # Move window in direction
bind = $mainMod SHIFT, h, swapwindow, l bind = $mainMod SHIFT, h, swapwindow, l

View File

@@ -8,17 +8,14 @@ autogenerated = 0 # remove this line to remove the warning
# See https://wiki.hyprland.org/Configuring/Monitors/ # See https://wiki.hyprland.org/Configuring/Monitors/
#monitor=name,resolution,offset, scale #monitor=name,resolution,offset, scale
#offset scales with scale XC #offset scales with scale XC
#monitor=DP-2,3840x2160,-2560x0,auto, bitdepth, 10, vrr, 1 #monitor=DP-1,3840x2160@60,320x-1440,auto, bitdepth, 10, vrr, 1 #320=(2560-1920)/2
#monitor=DP-1,3840x2160@144,auto,auto, bitdepth, 10, vrr, 1 #monitor=DP-1,3840x2160@144,auto,auto, bitdepth, 10, vrr, 1
monitor=DP-1,3840x2160@60,320x-1440,auto, bitdepth, 10, vrr, 1 #320=(2560-1920)/2 #monitor=DP-2,3840x2160,-2560x0,auto, bitdepth, 10, vrr, 1
monitor=DP-1,3840x2160@144,auto,auto, bitdepth, 10, vrr, 1 monitor=eDP-1,1920x1080,auto,1,vrr, 1
monitor=DP-2,3840x2160,-2560x0,auto, bitdepth, 10, vrr, 1
monitor=eDP-1,1920x1080,0x0,1
monitor=HDMI-A-1,2560x1440@60.00,0x-1440,1 monitor=HDMI-A-1,2560x1440@60.00,0x-1440,1
monitor=HDMI-A-2,1920x1080@74.97,0x-1080,1 monitor= ,highres@highrr,auto-up,1
#monitor=HDMI-A-2,2560x1440@60.00,0x-1440,1 monitor=DP-1,highres@highrr,auto-right,auto, bitdepth, 10, vrr, 1
#monitor=HDMI-A-2,3840x2160@60.00,0x-2160,auto monitor=DP-2,highres@highrr,auto-left,auto, bitdepth, 10, vrr, 1
#monitor=HDMI-A-2,3840x2160,0x-1080,2,bitdepth, 10, vrr, 1
# See https://wiki.hyprland.org/Configuring/Keywords/ for more # See https://wiki.hyprland.org/Configuring/Keywords/ for more
@@ -26,7 +23,6 @@ monitor=HDMI-A-2,1920x1080@74.97,0x-1080,1
# Execute your favorite apps at launch # Execute your favorite apps at launch
# exec-once = waybar & hyprpaper & dunst & syncthing & $nextcloud & $terminal # exec-once = waybar & hyprpaper & dunst & syncthing & $nextcloud & $terminal
exec-once = $HOME/.config/hypr/autostart exec-once = $HOME/.config/hypr/autostart
exec-once = /usr/lib/polkit-kde-authentication-agent-1
exec-once = gsettings set org.gnome.desktop.interface gtk-theme "Adwaita-dark" # for GTK3 apps exec-once = gsettings set org.gnome.desktop.interface gtk-theme "Adwaita-dark" # for GTK3 apps
exec-once = gsettings set org.gnome.desktop.interface color-scheme "prefer-dark" # for GTK4 apps exec-once = gsettings set org.gnome.desktop.interface color-scheme "prefer-dark" # for GTK4 apps
@@ -35,14 +31,15 @@ exec-once = gsettings set org.gnome.desktop.interface color-scheme "prefer-dark"
source = ~/.config/hypr/background.conf source = ~/.config/hypr/background.conf
source = ~/.config/hypr/hyprbindings.conf source = ~/.config/hypr/hyprbindings.conf
source = ~/.config/hypr/apps.conf source = ~/.config/hypr/apps.conf
source = ~/.config/hypr/windowrules.conf
# Some default env vars. # Some default env vars.
env = XCURSOR_SIZE,32 env = XCURSOR_SIZE,32
env = GSK_RENDERER,ngl
env = GTK_THEME,Adwaita-dark
env = QT_QPA_PLATFORM,wayland # here for calibre, with debatable effect env = QT_QPA_PLATFORM,wayland # here for calibre, with debatable effect
env = QT_QPA_PLATFORMTHEME,qt6ct # change to qt6ct if you have that env = QT_QPA_PLATFORMTHEME,qt6ct # change to qt6ct if you have that
env = QT_AUTO_SCREEN_SCALE_FACTOR,1 env = QT_AUTO_SCREEN_SCALE_FACTOR,1
env = GSK_RENDERER,ngl
env = GTK_THEME,Adwaita-dark
# For all categories, see https://wiki.hyprland.org/Configuring/Variables/ # For all categories, see https://wiki.hyprland.org/Configuring/Variables/
input { input {
@@ -57,10 +54,12 @@ input {
repeat_delay = 300 repeat_delay = 300
# Follow mouse 1 2 3 : # Follow mouse 1 2 3 :
follow_mouse = 2 follow_mouse = 2 # see also float_switch_override_focus
float_switch_override_focus = 0
touchpad { touchpad {
natural_scroll = yes natural_scroll = yes
clickfinger_behavior = true
} }
scroll_factor = 1.0 scroll_factor = 1.0
@@ -90,7 +89,7 @@ general {
decoration { decoration {
# See https://wiki.hyprland.org/Configuring/Variables/ for more # See https://wiki.hyprland.org/Configuring/Variables/ for more
rounding = 3 rounding = 0
blur { blur {
enabled = true enabled = true
@@ -100,11 +99,12 @@ decoration {
vibrancy = 0.3 vibrancy = 0.3
vibrancy_darkness = 0.8 vibrancy_darkness = 0.8
} }
shadow {
drop_shadow = no enabled = no
shadow_range = 4 range = 4
shadow_render_power = 3 render_power = 3
col.shadow = rgba(1a1a1aee) color = rgba(1a1a1aee)
}
} }
group { group {
groupbar{ groupbar{
@@ -113,9 +113,12 @@ group {
font_size = 11 font_size = 11
gradients = false gradients = false
scrolling = false scrolling = false
col.active = rgba(ea1d4e77) render_titles = false
col.active = rgba(33ccffaa)
col.inactive = rgba(00ff9933)
} }
col.border_active = rgba(ea1d4ebb) rgba(fd7000bb) 45deg #col.border_active = rgba(ea1d4ebb) rgba(fd7000bb) 45deg
col.border_active = rgba(00ff99ee) rgba(33ccffee) 30deg
} }
animations { animations {
@@ -167,18 +170,5 @@ device {
accel_profile = flat accel_profile = flat
} }
# Example windowrule v1 # execute at end
# windowrule = float, ^(kitty)$ exec-once=dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP
# Example windowrule v2
# windowrulev2 = float,class:^(kitty)$,title:^(kitty)$
# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more
# now invalid: # windowrulev2 = nomaximizerequest, class:.* # You'll probably like this.
windowrule = float, pinned, ^(dunst)$
windowrule = float, pinned, ^(notification)$
windowrulev2 = float, pinned, title:^(Nextcloud)$
windowrulev2 = float, title:^(Volume Control)$
windowrulev2 = float, title:^(Network Connections)$
windowrulev2 = float, stayfocused, dimaround, fullscreenstate, 0, title:^(Bitwarden - Vivaldi)$
windowrulev2 = float, pin, workspace unset, noinitialfocus, suppressevents [fullscreen, maximize, activate, activatefocus], title:^(notificationtoasts)
windowrulev2 = workspace 6, noinitialfocus, class:^(steam)$
windowrulev2 = noinitialfocus, class: ^(steam)$

View File

@@ -1,5 +1,10 @@
disable_loading_bar = false disable_loading_bar = false
general {
grace = 20
text_trim = false
}
background { background {
monitor = # empty for all monitors monitor = # empty for all monitors
#path = /home/felix/Pictures/backgrounds/arch_linux_bg.png #path = /home/felix/Pictures/backgrounds/arch_linux_bg.png

View File

@@ -0,0 +1,31 @@
# Example windowrule v1
# windowrule = float, ^(kitty)$
# Example windowrule v2
# windowrulev2 = float,class:^(kitty)$,title:^(kitty)$
# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more
# now invalid: # windowrulev2 = nomaximizerequest, class:.* # You'll probably like this.
windowrule = float, pinned, ^(dunst)$
windowrule = float, pinned, ^(notification)$
windowrulev2 = float, pinned, title:^(Nextcloud)$
windowrulev2 = float, title:^(Volume Control)$
windowrulev2 = float, title:^(Network Connections)$
windowrulev2 = float, size 300 700, stayfocused, dimaround, fullscreenstate, 0, title:(Bitwarden - Vivaldi)
windowrulev2 = float, pin, workspace unset, noinitialfocus, suppressevents [fullscreen, maximize, activate, activatefocus], title:^(notificationtoasts)
windowrulev2 = workspace 6 silent, noinitialfocus, class:^(steam)$
windowrulev2 = workspace special:A silent, noinitialfocus, class:^(org.telegram.desktop)$
windowrulev2 = workspace special:A silent, noinitialfocus, class:^(zapzap)$
windowrulev2 = workspace special:A silent, noinitialfocus, class:^(discord)$
windowrulev2 = workspace special:A silent, noinitialfocus, class:^(Slack)$
windowrulev2 = workspace special:S silent, noinitialfocus, class:^(spotify)$ # not capitalised on PC
windowrulev2 = workspace special:S silent, noinitialfocus, class:^(Spotify)$ # capitalised on laptop
windowrulev2 = workspace special:S silent, noinitialfocus, class:^(com.sayonara-player.Sayonara)$
windowrulev2 = opacity 0.0 override, class:^(xwaylandvideobridge)$
windowrulev2 = noanim, class:^(xwaylandvideobridge)$
windowrulev2 = noinitialfocus, class:^(xwaylandvideobridge)$
windowrulev2 = maxsize 1 1, class:^(xwaylandvideobridge)$
windowrulev2 = noblur, class:^(xwaylandvideobridge)$
windowrulev2 = nofocus, class:^(xwaylandvideobridge)$
windowrulev2 = workspace special:X silent, noinitialfocus, class:^(xwaylandvideobridge)$