# generic mode colors
set $mode_color_foreground $light0
set $mode_color_action $bright_green
# RESIZE
set $mode_resize " \
Resize (↑ ↓ ← →) \
Increase Gaps (+) \
Decrease Gaps (-)"
mode --pango_markup $mode_resize {
# left will shrink the containers width
# right will grow the containers width
# up will shrink the containers height
# down will grow the containers height
$bindsym $left resize shrink width $resizestepsize
$bindsym $down resize grow height $resizestepsize
$bindsym $up resize shrink height $resizestepsize
$bindsym $right resize grow width $resizestepsize
$bindsym $left_alt resize shrink width $resizestepsize
$bindsym $down_alt resize grow height $resizestepsize
$bindsym $up_alt resize shrink height $resizestepsize
$bindsym $right_alt resize grow width $resizestepsize
$bindsym Shift+$left resize shrink width $resizestepsize
$bindsym Shift+$down resize grow height $resizestepsize
$bindsym Shift+$up resize shrink height $resizestepsize
$bindsym Shift+$right resize grow width $resizestepsize
$bindsym Shift+$left_alt resize shrink width $resizestepsize
$bindsym Shift+$down_alt resize grow height $resizestepsize
$bindsym Shift+$up_alt resize shrink height $resizestepsize
$bindsym Shift+$right_alt resize grow width $resizestepsize
## Resize // Window Gaps // + - ##
$bindsym minus gaps inner current minus 5px
$bindsym plus gaps inner current plus 5px
# Return to default mode
$bindsym Return mode "default"
$bindsym Escape mode "default"
}
# SHUTDOWN
set $mode_shutdown "\
\
\
(h)hibernate \
(l)lock \
(e)logout \
(r)reboot \
(u)suspend \
(s)shutdown \
"
set $purge_cliphist [ $purge_cliphist_logout == 'true' ] && rm -f $HOME/.cache/cliphist/db || exit 0
mode --pango_markup $mode_shutdown {
# lock
$bindsym l mode "default", exec $locking
# logout
$bindsym e exec $purge_cliphist; exec loginctl terminate-user $USER
# suspend
$bindsym u mode "default", exec systemctl suspend
# hibernate
$bindsym h mode "default", exec systemctl hibernate
# shutdown
$bindsym s exec $purge_cliphist; exec systemctl poweroff
# reboot
$bindsym r exec $purge_cliphist; exec systemctl reboot
# Return to default mode.
$bindsym Escape mode "default"
}
# AUDIO
# some nice symbols to try here: 0| 論b籠i錄
set $mode_audio "Audio - + 0 y"
mode $mode_audio {
# Increase / decrease volume for the running sink only
$bindsym k exec $volume_up
# Decrease
$bindsym j exec $volume_down
# Mute sound
$bindsym 0 exec $volume_mute
# Start mps-youtube
$bindsym y exec --no-startup-id urxvt -e mpsyt, mode "default"
# Toggle pause/play
$bindsym space exec playerctl play-pause
#bindsym XF86AudioPause exec playerctl pause
#bindsym XF86AudioNext exec playerctl next
#bindsym XF86AudioPrev exec playerctl previous
# back to normal: Enter or Escape
$bindsym Return mode "default"
$bindsym Escape mode "default"
}
#set $mode_keyboard "us-intl (a), us-altgr-intl (b)"
#mode $mode_keyboard {
# bindsym a exec swaymsg input type:keyboard xkb_variant intl
# bindsym b exec swaymsg input type:keyboard xkb_variant altgr-intl
# bindsym return mode "default"
# bindsym escape mode "default"
#}
#
# do a nice menu for keyboard layouts
# TODO convert to wayland, using dconf-editor perhaps?
set $mode_keys "keys"
mode $mode_keys {
bindsym Return mode "default"
bindsym Escape mode "default"
}
# do a nice menu for keyboard layouts
# TODO convert to wayland, using dconf-editor perhaps?
set $mode_xkbmap "Layout aus bus-intl cus-altgr dgb egb-intl fdvorak"
mode $mode_xkbmap {
bindsym a exec --no-startup-id setxkbmap us, mode "default"
bindsym b exec --no-startup-id setxkbmap us intl, mode "default"
bindsym c exec --no-startup-id setxkbmap us altgr-intl, mode "default"
bindsym d exec --no-startup-id setxkbmap gb, mode "default"
bindsym e exec --no-startup-id setxkbmap gb intl, mode "default"
bindsym f exec --no-startup-id setxkbmap dvorak, mode "default"
# back to normal: Enter or Escape
bindsym Return mode "default"
bindsym Escape mode "default"
}
# do a nice menu for custom exec launches
set $mode_launch " adefault start-up bnoise-fix cdual dhorizontal etearing"
mode $mode_launch {
# These are all the default programs launching at startup.
bindsym a exec thunderbird, exec signal-desktop, exec ferdi, exec obsidian mode "default", exec teams --no-sandbox, exec slack
# execute default horizontal layout of monitors
bindsym d exec autorandr horizontal, mode "default"
# this fixes tearing on nvidia
bindsym e exec nvidia-settings --assign CurrentMetaMode="nvidia-auto-select +0+0 { ForceFullCompositionPipeline = On }"
# back to normal: Enter or Escape
bindsym Return mode "default"
bindsym Escape mode "default"
}