aboutsummaryrefslogtreecommitdiffstats
path: root/sway
diff options
context:
space:
mode:
Diffstat (limited to 'sway')
-rw-r--r--sway/config39
-rw-r--r--sway/input.cfg11
-rw-r--r--sway/output.cfg4
3 files changed, 38 insertions, 16 deletions
diff --git a/sway/config b/sway/config
index 52926f6..153260c 100644
--- a/sway/config
+++ b/sway/config
@@ -8,7 +8,7 @@ set $down j
set $up k
set $right l
set $term alacritty
-set $menu rofi -font "Iosevka Term 12" -show combi | xargs swaymsg exec
+set $menu rofi -font "Iosevka Term Nerd Font 12" -show combi | xargs swaymsg exec
# Colours
set $cl_high #4d4d4d
@@ -17,15 +17,11 @@ set $cl_back #1c1c1c
set $cl_fore #ffffff
set $cl_urge #ee2e24
-# Output names
-set $monitor1 DP-1
-set $monitor2 HDMI-A-1
-
#############
# Display #
#############
-font pango:Iosevka Term 11
+font pango:Iosevka Term Nerd Font 11
gaps inner 15
@@ -36,19 +32,13 @@ client.urgent $cl_urge $cl_urge $cl_fore $cl_urge $cl_urge
output * background ~/.config/sway/wallpaper.jpg fill
+include output.cfg
+
############
# Inputs #
############
-input type:keyboard {
- xkb_layout "gb"
- repeat_delay 300
- repeat_rate 30
-}
-
-input type:pointer {
- pointer_accel -0.7
-}
+include input.cfg
##############
# Workspaces #
@@ -67,10 +57,16 @@ workspace 5 output $monitor1 # thunderbird
bindsym $mod+Return exec $term
bindsym $mod+d exec $menu
-bindsym $mod+Shift+q kill
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'
+# Politely quit
+bindsym $mod+q kill
+# Rudely kill
+bindsym $mod+Shift+q exec swaymsg -t get_tree | \
+ jq '.. | select(.type?) | select(.focused==true).pid' | \
+ xargs -L 1 kill -9
+
floating_modifier $mod normal
# Move around
@@ -144,6 +140,10 @@ bindsym $mod+minus scratchpad show
# Screenshot
bindsym Print exec /usr/share/sway/scripts/grimshot copy area
+bindsym $mod+Shift+equal exec /usr/share/sway/scripts/grimshot copy area
+
+bindsym $mod+bracketleft exec pactl set-sink-volume @DEFAULT_SINK@ -5%
+bindsym $mod+bracketright exec pactl set-sink-volume @DEFAULT_SINK@ +5%
mode "resize" {
bindsym $left resize shrink width 10px
@@ -168,6 +168,13 @@ exec mako
# Make sure env vars are imported into D-Bus
exec dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=sway
+# Swayidle
+exec swayidle -w \
+ before-sleep "swaylock"
+
+# Chromium hotkey fix
+for_window [app_id="^chrome-.*-.*$"] shortcuts_inhibitor disable
+
############
# Waybar #
############
diff --git a/sway/input.cfg b/sway/input.cfg
new file mode 100644
index 0000000..a4746f7
--- /dev/null
+++ b/sway/input.cfg
@@ -0,0 +1,11 @@
+# Manually change this file
+
+input type:keyboard {
+ xkb_layout "gb"
+ repeat_delay 300
+ repeat_rate 30
+}
+
+input type:pointer {
+ pointer_accel -0.7
+}
diff --git a/sway/output.cfg b/sway/output.cfg
new file mode 100644
index 0000000..dc504a2
--- /dev/null
+++ b/sway/output.cfg
@@ -0,0 +1,4 @@
+# Manually change this file
+
+set $monitor1 DP-1
+set $monitor2 HDMI-1