diff --git a/.config/i3/config b/.config/i3/config index 4adbf31..2594da3 100644 --- a/.config/i3/config +++ b/.config/i3/config @@ -338,6 +338,8 @@ exec --no-startup-id dex -a -s /etc/xdg/autostart/:~/.config/autostart/ # num lock activated #exec --no-startup-id numlockx on +# configure multiple keyboard layouts and hotkey to switch (Alt+CAPSLOCK in this example) +#exec --no-startup-id setxkbmap -layout 'us,sk' -variant altgr-intl,qwerty -option 'grp:alt_caps_toggle' # start conky: #exec_always --no-startup-id conky diff --git a/.config/i3/i3blocks.conf b/.config/i3/i3blocks.conf index 5aa8710..bf39a4e 100644 --- a/.config/i3/i3blocks.conf +++ b/.config/i3/i3blocks.conf @@ -136,6 +136,11 @@ interval=1 full_text= command=~/.config/i3/scripts/keyhint.sh +# display keyboard layout name +#[keyboard-layout] +#command=~/.config/i3/scripts/keyboard-layout.sh +#interval=2 + [time] #label= command=date '+%a %d %b %H:%M:%S' diff --git a/.config/i3/scripts/keyboard-switch.sh b/.config/i3/scripts/keyboard-switch.sh new file mode 100755 index 0000000..9a3e314 --- /dev/null +++ b/.config/i3/scripts/keyboard-switch.sh @@ -0,0 +1,5 @@ +#!/usr/bin/env bash + +KBD=$(/usr/bin/xkblayout-state print '%s') +echo $KBD +