You are not logged in.

#1 2016-02-05 02:24:28

plitter
Member
Registered: 2010-10-07
Posts: 33

AltGr has been mapped to alt

As I'm starting X I run this command

$ setxkbmap -layout us -variant dvp -option caps:swapescape

to set my keyboard layout. After I updated yesterday my AltGr is just an Alt. How do I get AltGr back?

#############################
Solution example
https://wiki.archlinux.org/index.php/Xmodmap
run

 $ xmodmap -pke > "<file of your choice>" 

then change keymap 108 from Alt_R Meta_R to

...
keycode 108 = ISO_Level3_Shift Mode_switch
...

Then try

 $ xmodmap "<filename you chose previously>" 

Now hack until your keyboard is how you want it!

EDIT: This didn't fully work... firefox still can't get my 3 norwegian letters and for some reason I have to use setxkbmap first. Seems I have to read some more...
EDIT: When I do

 $ setxkbmap no 

 $ xmodmap "<filename you chose previously>" 

I get it to work. The setxkbmap -layout us doesn't contain alt-gr and it seems that the xmodmap doesn't change it. I have no idea why it doesn't though.
EDIT: There is something funky going on when I try to changing from US layout to my own layout with xmodmap, the US layout starts with lock Caps_Lock, but when I change it with xmodmap it changes to Escape regardless if I have the clear lock and add lock = Caps_Lock or not. I'll do some more testing when I have time, but I'm starting to think this is a bug.
EDIT: Final solution which is way more clear is to use the flag -option lv3:ralt_switch.

 $ xmodmap -layout us -variant dvp -option caps:swapescape -option lv3:ralt_switch 

Last edited by plitter (2016-03-06 23:23:26)

Offline

Board footer

Powered by FluxBB