You are not logged in.
Hello forum,
WM - Openbox
Panel - Lemonbar
I have (and often change) 3 keyboard layouts. I would like to see a notification on my screen when layout is changed, e.g. "Switched to English/US". I tried to do it via notify-send, but I failed.
Openbox autostart file:
#keyboard
setxkbmap -layout us,ru,ge -variant -option grp:alt_shift_toggle,terminate:ctrl_alt_bksp &layout.sh
#!/bin/bash
lang=$(setxkbmap -query | grep layout | sed 's/layout.* //g')
if [[ $lang == "ru" ]]
then
setxkbmap us
notify-send 'Current Keyboard Layout:' 'US (English)'
elif [[ $lang == "us" ]]
then
setxkbmap ru
notify-send 'Current Keyboard Layout:' 'RU (Russian)'
elif [[ $lang == "ge" ]]
then
setxkbmap us
notify-send 'Current Keyboard Layout:' 'GE (Geprgian)'Thank you.
Offline
but I failed.
What do "I failed" mean? What is the issue?
When is the "layout.sh" file used?
Offline
Est wrote:but I failed.
What do "I failed" mean? What is the issue?
When is the "layout.sh" file used?
When I'm switching keyboard (Alt + Shift).
Offline