4 ms·
I was sad to see that the option to swap caps lock and escape was gone (I think I'm blaming GNOME here). But on the other hand I ought to be doing that program
by Symmetry 13y ago
I was sad to see that the option to swap caps lock and escape was gone (I think I'm blaming GNOME here). But on the other hand I ought to be doing that programaticly in my setup script, so I finally just got around to adding that there.
EDIT: I almost decided to switch to Xubuntu, but then I installed xfce, tried it out, and found that they didn't provide that option either. Besides, using xmonad with xfce is much more complicated than with GNOME.
- cmiles74 13y agoI call out to setxkbmap to get this done. It should work with any window manager and desktop environment.[0] setxkbmap -option ctrl:nocaps [0] https://gist.github.com/Spoygg/3122226 https://gist.github.com/Spoygg/3122226
- djeikyb 13y agoLast time I was using Ubuntu+Unity as my main desktop (11.xx), I used `xmodmap` to swap my keys, and found that every so often it'd be reverted. Have you experienced similar problems with this technique?
- SEMW 13y agoIIRC I didn't finding any easy way of making xmodmap settings persist over reboot, so I just took had a script that runs "xmodmap ~/.Xmodmap" run at startup. (Of course then I switched to xfce on my laptop, which seems to run its own xmodmap command after its run startup scripts or something which overrides them, which is kinda annoying, haven't found a nice way to get around that).
- oinksoft 13y agoTry putting your `xmodmap' command in `~/.xinitrc'. It gets read whenever the X server starts (`startx').
- SEMW 13y agoThanks, but Xfce's startup applications list (which is just a frontend for ~/.config/autostart) is already executed after the X server starts, and after .xinitrc. (Apologies if me saying 'runs at startup' was misleading -- obviously if I had tried to do it from a script that ran on boot, before X starts (rather than on session start) it could never have worked in the first place!). Edit: now I've started thinking about it again, I've changed the autostart script to call another which sleeps for 10s before xmodmap, which seems to have fixed the problem.
- djeikyb 13y agoI do expect a reboot to require somehow reloading my settings via xmodmap. More troubling is during an X session with Unity, my settings would be reverted, and I'd have to reload with xmodmap. Other desktop environments didn't have this issue. I really should have done my part and written a bug report.
- cmiles74 13y agoI put it in my startup script, it runs every login.
- garretraziel 13y agoGNOME only moved it into gnome-tweak-tools. Not sure with Unity though.