0

I have a spanish (european) Apple Aluminum keyboard hooked to my ubuntu'd Mac Mini, it works fine but the keys for < and º/ª are swapped, and they remain swapped, even though my keyboard seems to be configured correctly. How do I swap 'em (or unswap them, I guess)?

btw this is º/ª (think spanish equivalent of -nd, -rd) not degree as far as I know (usually comes with a line under it but some fonts render both symbols exactly the same.)

Thank you so much in advance, guys.

0

For anyone struggling: I have pieced together a solution.

First step: use xev to capture both keys, takes out the guesswork. For me they were 49 & 94.

once you have the key codes, do this:

xmodmap -pke | grep -Pw "49|94" > mychanges

Or whatever your keycodes are instead of 49 & 94, though, they're probably the same if you have the problem with º & < on a spanish keyboard.

Then, edit "mychanges" to swap the keys. You probably have something like:

keycode  49 = masculine ordfeminine grave asciitilde backslash backslash
keycode  94 = less greater less greater bar brokenbar bar brokenbar

Swap the numbers for those two, then xmodmap mychanges, try it out, if you like it do cat mychanges >> ~/.Xmodmap

Sources:

Getting character key code mappings in ubuntu

Apple keyboard swap

| improve this answer | |

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.