In my ~/.fvwm2rc, I have some keyboard shortcuts, e.g.
Key n A C exec xterm -fn 7x14 -geometry 103x58+535+90
so that CTRL-n brings up a new xterm. However, when I run Illustrator (e.g.) under Win4Lin, I want it to interpret CTRL-n in its usual way. So for the X functions (e.g. the one shown above), I’d like to use a modifier that isn’t CTRL, SHIFT, or ALT.
I changed .fvwm2rc to show the Meta key
Key n A M exec xterm -fn 7x14 -geometry 103x58+535+90
and now I get a new window with ALT+i (ALT apparently acting as the meta key). However, I’d like to use the L Windows/Super key as a new modifier but haven’t succeeded. xev tells me that its keycode is 115, so I tried
xmodmap -e “keycode 115 = Meta_L”
According to xev, this does succeed in assigning Meta_L to key 115, but it doesn’t appear to have any modifier function. If I hold down the Super_L key and the i' key, I just get an i’.
xmodmap -pm shows Super_L/R as mod4 and shows nothing for mod3 or mod5.
Is there any way I can have the L Super key act as a new modifier and then list it in my .fvwm2rc? Thanks.
The second line didn’t work, perhaps because I’m running fvwm2-2.4.15. not 2.5.X. (I got 2.4.15 a couple of years ago because RPMs were easier than compiling, but maybe I’ll try the latter now.)
I’d still be interested to try setting up a new modifier for these functions. The reference you cited suggested
Right. Window-specific key-bindings are a feature of FVWM 2.5.X. I suggest you use FVWM 2.5.16. This is why the second line above doesn’t work. Note that the name you put in brackets should correspond to the window of the key-binding you want ignored. I have a hard time believing it’s called ‘Windows’. If you’re not sure what it’s called, run FvwmIdent, or xwininfo, or xprop on the window.
You replace “C” with whatever the modifier number is, for the key you’re adding the modifier for. Note that in the above (and in my instructions posted to you earlier), the keysym is derived from the keycode that the key generates – this is ascertained via xev(1) typically. If you want to know the next logical modifier mapping, look to the following:
[n6tadam@workstation ~]$ xmodmap -pm
xmodmap: up to 3 keys per modifier, (keycodes in parentheses):
shift Shift_L (0x32), Shift_R (0x3e)
lock Caps_Lock (0x42)
control Control_L (0x25), Control_R (0x6d)
mod1 Meta_L (0x40), Meta_L (0x7d), Meta_L (0x9c)
mod2 Num_Lock (0x4d)
mod3 Super_L (0x73), Super_L (0x7f)
mod4 Super_L (0x7f), Hyper_L (0x80), Menu (0x75)
mod5 Mode_switch (0x5d), ISO_Level3_Shift (0x7c)
Hence I could if I wanted declare another key as modifier 6. As far as FVWM is concerned, to use such a new modifier (let’s take modifier 4):
Key i A 4 Iconify
Does that help? Note that this is also mentioned upon in the main FVWM FAQ via the fvwm.org website.
As it turns out, this was all I needed. Super_L was already set to be mod4, so all I had to do was list mod4 in .fvwm2rc. Now it all works just as I wanted.
Thanks for your prompt and articulate help. I have done a lot of spotty reading but haven’t found a good, clear reference that defines the basic terminology and explains the relation between the Linux keymaps and the X ones. Fortunately I only needed to worry about X for this. And I’ll try to bring up 2.5.16.