Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

My "return" key is broken. I followed the instructions here: http://www.ehow.com/how_2180748_command-linux-swap-keyboard-keys.html - hoping to reassign my | key as the new return key. My .xmodmaprc file reads as follows:

keycode 51 = 36

But the | key does not act as a return key. Nothing has changed. Any ideas what I might be doing wrong? Thanks so much for any suggestions.

share|improve this question
    
Have you tried logging in and out? –  Anarci Oct 18 '11 at 18:43
    
Thank you for replying - I ended up being able to make it work by using Autokey. –  begtognen Nov 1 '11 at 15:00

2 Answers 2

Your xmodmap expression is wrong. It needs to be formatted like this:

keycode [keycode] = [keysym]

The keysym is the symbol name of the key you want the "|" key mapped to, which in your case is "Return". So your xmodmap expression needs to be:

keycode 51 = Return

Putting everything back together, the command you want to run is:

[~]$ xmodmap -e "keycode 51 = Return"

(Don't type the [~]$ part, I'm just indicating that you need to run that from terminal).

If you want this to run each time you log in create a file called ~/.Xmodmap with the following contents:

keycode 51 = Return

I hope that works.

share|improve this answer

You need to run the following in a terminal:

xmodmap ~/.xmodmaprc

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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