cleanup sway config

This commit is contained in:
stev 2024-06-25 23:59:32 +02:00
parent 1c8901e7a0
commit 2c86c5ccfa

View file

@ -1,5 +1,5 @@
### Variables ### Variables
#include /etc/sway/config.d/* include /etc/sway/config.d/*
include ~/.config/sway/config.d/* include ~/.config/sway/config.d/*
# #
# Logo key. Use Mod1 for Alt. # Logo key. Use Mod1 for Alt.
@ -9,20 +9,23 @@ set $left h
set $down j set $down j
set $up k set $up k
set $right l set $right l
set $term kitty set $term alacritty
set $menu rofi -show drun | xargs swaymsg exec -- set $menu fuzzel --font=undefined
set $browser firefox set $browser firefox
set $wallpaper "~/pics/wp_vaporwave.jpg" set $wallpaper "./wallpaper"
set $wp_locked "~/pics/wp_vaporwave_blurred.jpg" set $wp_locked "./wallpaper_blurred"
set $lock swaylock -f -i $wp_locked
### Output configuration ### Output configuration
# #
output * bg $wallpaper fill output * bg $wallpaper fill
output "Dell Inc. DELL P2319H BMNX5R2" pos 0,0
output eDP-1 pos 1920,0
### Idle configuration ### Idle configuration
# #
exec_always swayidle -w \ exec_always swayidle -w \
before-sleep 'swaylock -f -i $wp_locked --inside-color $base03' before-sleep '$lock'
# timeout 600 'swaylock -f -i $wp_locked --inside-color $base03' \ # timeout 600 'swaylock -f -i $wp_locked --inside-color $base03' \
# timeout 900 'swaymsg "output * dpms off"' resume 'swaymsg "output * dpms on"' \ # timeout 900 'swaymsg "output * dpms off"' resume 'swaymsg "output * dpms on"' \
# #
@ -32,15 +35,19 @@ exec_always swayidle -w \
### Input configuration ### Input configuration
# #
input "type:pointer" {
accel_profile "flat"
pointer_accel 0
}
input "type:touchpad" { input "type:touchpad" {
dwt enabled dwt enabled
tap enabled tap enabled
natural_scroll enabled natural_scroll enabled
middle_emulation enabled middle_emulation enabled
pointer_accel 0.3
} }
input "type:keyboard" { input "type:keyboard" {
xkb_layout "us" xkb_layout "us"
#xkb_variant "altgr-intl"
xkb_options "compose:ralt" xkb_options "compose:ralt"
} }
@ -51,12 +58,12 @@ input "type:keyboard" {
bindsym $mod+Backspace exec makoctl dismiss --all bindsym $mod+Backspace exec makoctl dismiss --all
# Start applications # Start applications
bindsym $mod+d exec $menu bindsym $mod+d exec $menu
#bindsym $mod+b exec $browser
bindsym $mod+Return exec $term bindsym $mod+Return exec $term
bindsym $mod+Shift+q kill bindsym $mod+Shift+q kill
floating_modifier $mod normal floating_modifier $mod normal
bindsym $mod+Shift+Backspace exec '$lock'
bindsym $mod+Shift+c reload bindsym $mod+Shift+c reload
bindsym $mod+Shift+e exec swaynag -t warning -m 'You pressed the exit shortcut. Do you really want to exit sway? This will end your Wayland session.' -B 'Yes, exit sway' 'swaymsg exit' bindsym $mod+Shift+e exec swaynag -t warning -m 'You pressed the exit shortcut. Do you really want to exit sway? This will end your Wayland session.' -B 'Yes, exit sway' 'swaymsg exit'
@ -69,8 +76,6 @@ input "type:keyboard" {
# Control Brightness # Control Brightness
bindsym --locked XF86MonBrightnessDown exec light -T 0.72 bindsym --locked XF86MonBrightnessDown exec light -T 0.72
bindsym --locked XF86MonBrightnessUp exec light -T 1.4 bindsym --locked XF86MonBrightnessUp exec light -T 1.4
# bindsym --locked XF86MonBrightnessDown exec light -U 5
# bindsym --locked XF86MonBrightnessUp exec light -A 5
# Take a screenshot # Take a screenshot
bindsym $mod+p exec grim -g "$(slurp)" - | swappy -f - bindsym $mod+p exec grim -g "$(slurp)" - | swappy -f -
@ -120,15 +125,20 @@ input "type:keyboard" {
# #
# Layout stuff: # Layout stuff:
# #
# to get more info on opened window, use the following command
# swaymsg -t get_tree
for_window [class="PacketTracer"] floating enable for_window [class="PacketTracer"] floating enable
for_window [class="VirtualBox"] floating enable for_window [class="VirtualBox"] floating enable
for_window [class="^Minecraft*"] floating enable for_window [class="^Minecraft*"] floating enable
for_window [class="Lxappearance"] floating enable
for_window [app_id="python3"] floating enable
bindsym $mod+b splith bindsym $mod+b splith
bindsym $mod+v splitv bindsym $mod+v splitv
bindsym $mod+s layout stacking bindsym $mod+s layout stacking
bindsym $mod+w layout tabbed bindsym $mod+t layout tabbed
bindsym $mod+e layout toggle split bindsym $mod+e layout toggle split
bindsym $mod+f fullscreen bindsym $mod+f fullscreen
@ -162,6 +172,16 @@ mode "resize" {
} }
bindsym $mod+r mode "resize" bindsym $mod+r mode "resize"
#
# Assign to Workspaces
#
assign [class="Signal"] workspace 10
#
# Autostart
#
exec signal
# #
# Status Bar: # Status Bar:
# #
@ -169,6 +189,6 @@ bindsym $mod+r mode "resize"
bar swaybar_command waybar bar swaybar_command waybar
default_border pixel default_border pixel
gaps inner 20 gaps inner 0
bindsym $mod+Shift+u exec 'swaymsg gaps inner all minus 5' bindsym $mod+Shift+u exec 'swaymsg gaps inner all minus 5'
bindsym $mod+Shift+i exec 'swaymsg gaps inner all plus 5' bindsym $mod+Shift+i exec 'swaymsg gaps inner all plus 5'