You are not logged in.

#1 2020-12-19 08:37:26

allhavebrainimplantsnmore
Member
Registered: 2020-07-07
Posts: 13

[WORKED AROUND]xephyr openbox autostart setxkbmap layout doesn't work

when I run

setxkbmap -layout ru

from within xephyr's openbox terminal, my keyboard layout changes.
when I add

setxkbmap -layout "us,ru" -option "grp:alt_shift_toggle" &

to ~/.config/openbox/autostart (or to /etc/xdg/openbox) my keyboard layout does not change when Alt+Shift is pressed.
How can one get the keyboard layout to change with a shortcut?

Last edited by allhavebrainimplantsnmore (2020-12-19 09:59:10)

Offline

#2 2020-12-19 09:58:20

allhavebrainimplantsnmore
Member
Registered: 2020-07-07
Posts: 13

Re: [WORKED AROUND]xephyr openbox autostart setxkbmap layout doesn't work

Ok, the only way I managed to achieve keyboard layout switching via a shortcut was by:
1) adding a keybinding to ~/.config/openbox/rc.xml that runs a custom script
2) custom script executes:

(setxkbmap -query | grep -q "layout:\s\+us") && setxkbmap ru || setxkbmap us

Hope this helps someone out one day.

Offline

Board footer

Powered by FluxBB