1

I have an us altgr-intl layout.

with this command :

>_xmodmap -e "keycode 113 = Left NoSymbol U21BC NoSymbol U21BC U21BC U21BC"

(Or just 6 combinations, I tried many things ...)

  • AltGr+ still act like alone and AltGr+Shift+ still act like Shift+
  • Mode_shift+ works well.

I have some Fn's functions related to my arrows.

If I assign the formula above to a key without Fn's functions, it will work.

Is it a problem solvable at software level?

AdminBee
  • 22,803
pillule
  • 65
  • 5
  • I have had a similar problem. AltGr only works after making it Mode_switch, like so: xmodmap -e "keysym Alt_R = Mode_switch Mode_switch Mode_switch". – Ned64 May 16 '20 at 22:02
  • thx but I am fine with my -layout us -variant AltGr-intl; and I am just exploring how to use more modifiers. – pillule May 19 '20 at 22:24

1 Answers1

1

You cannot extend extend behavior of any key to use AltGr :

Each key have a type, and those one are ONE_LEVEL.

The solution is to mess with xkb.

$ xkbcomp  $DISPLAY output.dump

will dump your full keymap.

We see here :

key <LEFT> { [      Left ] };

We can modify it as :

    Key <LEFT> {
type[group1]= "FOUR_LEVEL",
type[group2]= "TWO_LEVEL",
symbols[group1]= [      Left,   Left,    Right,   Down],
symbols[group2]= [      Prior,  End ] };

There is two type handled by two group :

'FOUR_LEVEL' is here Base, Shift, AltGr, AltGr+shift

'TWO_LEVEL' is here Mode_switch, Mode_switch+Shift

Then test the map :

$ xkbcomp output.dump $DISPLAY

Everything works ... almost ... well, my Virtual Machines grabs now the default layout instead of mine and,

And I always have a strange behavior with some combinations of Fn's key (I have two of them and one don't accept some modifiers).

pillule
  • 65
  • 5