aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dotfiles/.config/sway/config2
-rwxr-xr-xdotfiles/.config/sxiv/exec/key-handler5
-rwxr-xr-xdotfiles/.local/bin/setbg13
3 files changed, 17 insertions, 3 deletions
diff --git a/dotfiles/.config/sway/config b/dotfiles/.config/sway/config
index 0645b2e..c8da8ea 100644
--- a/dotfiles/.config/sway/config
+++ b/dotfiles/.config/sway/config
@@ -107,6 +107,7 @@ input 2:10:TPPS/2_IBM_TrackPoint pointer_accel 1
# Outputs
output "*" background ~/.config/wall1.png fill
+output "HDMI-A-2" background ~/.config/wall2.png fill
# Laptop display
output "eDP-1" scale 1.6 pos 0 0 scale_filter linear
# Two monitor layout
@@ -336,6 +337,7 @@ bindsym --to-code {
# Gaps
$mod+semicolon gaps inner current set 15; gaps outer current set 0
$mod+Shift+semicolon gaps inner current set 0; gaps outer current set 0
+ $mod+Ctrl+semicolon gaps inner current set 45; gaps outer current set 15
$mod+period gaps outer current plus 5
$mod+Shift+period gaps outer current minus 5
$mod+comma gaps inner current plus 5
diff --git a/dotfiles/.config/sxiv/exec/key-handler b/dotfiles/.config/sxiv/exec/key-handler
index 6e17c5a..8fa1bdb 100755
--- a/dotfiles/.config/sxiv/exec/key-handler
+++ b/dotfiles/.config/sxiv/exec/key-handler
@@ -2,9 +2,12 @@
while read file; do
case "$1" in
- "C-a")
+ "C-a" | "C-1")
setbg "$file"
exit ;;
+ "C-2")
+ setbg "$file" "2"
+ exit ;;
"C-s")
setbglblur "$file"
exit ;;
diff --git a/dotfiles/.local/bin/setbg b/dotfiles/.local/bin/setbg
index 351ac3d..eb319d0 100755
--- a/dotfiles/.local/bin/setbg
+++ b/dotfiles/.local/bin/setbg
@@ -1,4 +1,13 @@
#!/bin/sh
-cp $1 ~/.config/wall1.png
-swaymsg output "*" background ~/.config/wall1.png fill
+mon="1"
+[ -n "$2" ] && mon="$2"
+
+cp $1 "$HOME/.config/wall$mon.png"
+
+IFS=$'\n'
+outputcf=$(grep '^output .* background.*$' ~/.config/sway/config)
+
+for line in $outputcf; do
+ swaymsg $line
+done