8

I had to make some changes to the xmodmap in my home directory. When i execute xmodmap ./.Xmodmap everthing works as expected. But i can't figure out how to apply this permanently. I tried to add it to a file called .xinitrc liek suggested in other questions here but it's just not working.

My system is freshly installed 13.04 64bit.

4

You can use gnome-session-properties (in the Dash can be found by typing Startup - it will find the Startup Applications Preferences application:

see:

screenshot

Then add a new command for xmodmap. Use the absolute path to the file you want to launch with xmodmap:

see:

screenshot

You can also switch back to a “normal” layout using: setxkbmap -layout fr (replace “fr” with “us” or your keyboard layout variant).

6
  • That sounds promising but theres no program found in the dash typing Startup... – Chris Aug 18 '13 at 16:44
  • If the interface is in another language, you might not find the brogram through the Dash. Please try to launch the app by typing its name, gnome-session-properties from a Terminal window. – Cosmin Saveanu Aug 18 '13 at 17:05
  • Id used the program to configure the way you suggested but it does not work. It does not seem to execute the program at all. Will this be executed on each login or do i have to reboot the machine? – Chris Aug 18 '13 at 18:10
  • A reboot should not be necessary but a log out is required to see if it works. Also, please check that the command works from the Terminal and that the path to the .Xmodmap file is complete (something like /home/yourusername/.Xmodmap). As a last resort, you can look just after logging in in the system log file: /var/log/syslog for any kind of encountered errors. – Cosmin Saveanu Aug 18 '13 at 20:57
  • Still not working, no errors occured in the syslog. This is driving me nuts... it used to be so easy. .Xmodmap in the home directory has been read automaticly before... why did they make ubuntu stopping this? Is there maybe a new way this can be configured? – Chris Aug 23 '13 at 14:56
2

Any changes to the key bindings using xmodmap or xkb will be trampled if you suspend or change keymap. Also, on login, they won't work in the first few seconds (since GNOME will load its own keymap later).

See here for details and a few workarounds; personally I'm using dedalu's script.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.