You are not logged in.
Pages: 1
Hey,
I have a problem with keyboard settings. I am trying to make right Meta key (rwin) to act as a Hyper key (menu). It worked OK with xmodmap (xmodmap -e "keycode 134 = Menu"), but since I switched to Openbox, xmodmap is no option anymore - Openbox overwrites its configs.
So I want to try the same thing with setxkbmap, but after reading through manual, countless forum topics and searching through a bunch of config files I still have no idea how. Any help will be appreciated.
Thanks.
Last edited by YanDoroshenko (2016-09-03 15:36:00)
Offline
Have you tried this?
Offline
Have you tried this?
Yes, I have tried that. It does not work, unfortunately. For some reason Openbox seems to be overriding all the xmodmap settings some time during or shortly after the startup.
Last edited by YanDoroshenko (2016-09-02 21:10:24)
Offline
It worked OK with xmodmap (xmodmap -e "keycode 134 = Menu"), but since I switched to openbox, xmodmap is no option anymore - openbox overwrites its configs.
How are you starting Openbox?
The solution linked by @Markus00000 will only work if `exec openbox-session` is used rather than just `exec openbox` (if started via ~/.xinitrc).
EDIT: You should probably add "openbox" to the thread title.
Last edited by Head_on_a_Stick (2016-09-02 20:46:10)
Para todos todo, para nosotros nada
Online
How are you starting Openbox?
I'm starting it with SDDM.
EDIT: You should probably add "openbox" to the thread title.
Yes, you're right, I should do that, but I don't know how (to edit the topic title). I'm a bit new here on the forum. Sorry for being a dumb ass.
Offline
I'm starting it with SDDM.
Try adding your xmodmap command to ~/.config/openbox/autostart -- copy the file from /etc/xdg/openbox/autostart if you don't already have it.
I don't know how (to edit the topic title)
Click on the "Edit" button on your first post in this thread to edit the title.
Para todos todo, para nosotros nada
Online
Try adding your xmodmap command
Not working. Tried xmodmap -e 'keycode 134 = Menu' and xmodmap ~/.Xmodmap. Neither works.
Click on the "Edit" button on your first post in this thread to edit the title.
Done, thanks.
Offline
Not working. Tried xmodmap -e 'keycode 134 = Menu' and xmodmap ~/.Xmodmap. Neither works.
Does that first command work when run from a shell?
Please post the full content of ~/.config/openbox/autostart
We use that file in BunsenLabs under LightDM and `xmodmap` works just fine:
https://github.com/BunsenLabs/bunsen-co … ostart#L35
You should also check SDDM and make sure that "openbox-session" is selected rather than just "openbox".
Para todos todo, para nosotros nada
Online
Does that first command work when run from a shell?
Yes, it does work from a shell.
Please post the full content of ~/.config/openbox/autostart
lxpanel &
xfce4-clipman &
plank &
xcompmgr &
nitrogen --restore &
xmodmap -e "keycode 134 = Menu"
You should also check SDDM and make sure that "openbox-session" is selected rather than just "openbox".
SDDM looks for sessions in /usr/share/xsessions and the openbox.desktop file references the /usr/bin/openbox-session which seems fine to me.
Last edited by YanDoroshenko (2016-09-03 06:51:58)
Offline
Is the menu or rwin key defined in ~/.config/openbox/rc.xml?
If so, try commenting out the relevant stanza.
Para todos todo, para nosotros nada
Online
Is the menu or rwin key defined
Neither of them was defined but I tried commenting out the whole <keyboard> block. Did not help.
Offline
We could eliminate SDDM temporarily:
# systemctl isolate multi-user.target
Then start the desktop with:
startx /usr/bin/openbox-session
To restart SDDM, use:
# systemctl isolate graphical.target
Para todos todo, para nosotros nada
Online
OK, progress.
I've made an xterm with an xmodmap command pop up once Openbox starts. An xterm launches fine, does its stuff and closes. And AFTER that the keyboard config is being altered. Like Openbox runs something (which looks like parameterless setxkbmap that wipes all the xmodmap settings) after the autostart script is done.
Last edited by YanDoroshenko (2016-09-02 22:07:34)
Offline
So, the workaround has been found.
sleep 15 && xmodmap -e "keycode 134 = Menu" &
in the autostart file seems to work fine.
Offline
UPD: it does work fine. The problem is that damn Openbox resets it after some time. Try to get rid of everything keyboard related and then just install what I need.
Offline
Solved. Went to /usr/share/X11/xkb/keycodes/evdev and swapped 134 and 135. Yes, I know that it's a big no-no but I don't care.
Offline
If you want to dig any further, I would recommend removing the layers of abstraction in your system.
First, try stopping the display manager using the technique outlined in https://bbs.archlinux.org/viewtopic.php … 2#p1651662
If the problem still occurs then you could try bypassing the openbox-session script by creating ~/.xinitrc and calling the window manager with:
exec openbox
If this fixes it then the problem may lie in your XDG autostarted programs, check /etc/xdg/autostart & ~/.config/autostart for any .desktop files.
Para todos todo, para nosotros nada
Online
Pages: 1