Suppose I wanted to map the command :!python % <ENTER>
to pressing the keys Alt Gr
and j
together?
Suppose I wanted to map the command :!python % <ENTER>
to pressing the keys Alt Gr
and j
together?
Due to the way that the keyboard input is handled internally, many key combinations cannot be used, even in GVIM. This is a known pain point, and the subject of various discussions on vim_dev and the #vim IRC channel.
A basic rule is: If the key combination yields a visible character in command-line mode, it can be mapped. But in particular for AltGr, it may be the same mapping as Alt, depending on what your OS returns when it's combined with the other key.
Some people (foremost Paul LeoNerd Evans) want to fix that (even for console Vim in terminals that support this), and have floated various proposals, cp. http://groups.google.com/group/vim_dev/browse_thread/thread/626e83fa4588b32a/bfbcb22f37a8a1f8
But as of today, no patches or volunteers have yet come forward, though many have expressed a desire to have this in a future Vim 8 major release.