key mapping not working since upgrade

hi forum members,

I am new to this forum, hopefully I give you enough information to explain the problem.

Recently, I changed my distribution from debian wheezy to debian jessie. In doing that, fvwm was upgraded:

In .fvwmrc, I had two key mappings defined that did the same page switch:

Key F20 A N GotoDeskAndPage prev Key Pause A N GotoDeskAndPage prev

In .xmodmaprc, I have redefined the SysRq key so that it generates a F20 event. This worked fine. However, after the upgrade, the mapping of those redefined keys (like F20) stopped working (I have more of them).

The xev utility currently shows me that the key redefinition works correctly; when I press SysRq, I get

KeyRelease event, serial 40, synthetic NO, window 0x2c00001, root 0x9a, subw 0x0, time 52361709, (141,-10), root:(202,403), state 0x0, keycode 107 (keysym 0xffd1, F20), same_screen YES, XLookupString gives 0 bytes: XFilterEvent returns: False

The current situation is: The Pause key does a the page switch, but the SysRq key (F20) does no page switch. When I am in a editor, the key results in some garbage in the text, so fvwm clearly does not ‘consume’ them any more.

I hope you can guide me on tracking down what is going on and what I can do to solve this.

thanks for your help, Ruud

hi,
it looks if the timing has changed. Whenever I change my xmodmaprc, I have to reload fvwm in order to get the change to be effective.

In the same manner, when I start fvwm, I immediately have to reload it in order to load the events that xev shows within the same fvwm session.

I start fvwm using startx, and that uses .xinitrc, basically containing this:

#!/bin/sh xmodmap ~/.xmodmaprc & fvwm2

… and my .xmodmaprc contains this:

! scroll lock-toets keycode 78 = F21 keycode 77 = NoSymbol ! sysrq => F20 keycode 107 = F20

So in the previously installed version of fvwm, this worked all right. And right now, fvwm does not see F20 nor F21 after starting (although xev does show it). Fvwm does so if I reload it.
When this is a new feature, most probably I have to move the xmodmap bit to another place. Any suggestions?

thanks, Ruud

Hallo and welcome,
as far as I’ve understood you, after you restart FVWM (or what do you mean by “reload”?), your settings all work correctly.
What happens if you remove (rename) your .xmodmaprc and load it manually after you have started X and FVWM.

Wouldn’t it be an acceptable workaround to use the keys in question directly in .fvwm2rc without reassigning them, such as:

Key Sys_Req A N GotoDeskAndPage prev Key Scroll_Lock A N DoSomethingCrazy
(You probably know that you find the correct key names in /usr/include/X11/keysymdef.h, removing the XK_ prefixes.)

Hi Tronar,

your ‘workaround’ is a better thing to do. It works perfectly. And what’s more: after restarting fvwm, I could not reproduce the problem anymore. That is: I changed oly F21 to Scroll_Lock as you suggested, but left F20 alone.
After stopping fvwm, disabling F21 in .xmodmaprc and logging out, logging in and starting fvwm again, all keys worked well.

I can not explain what has happened, but thanks to your suggestion, both fvwm and xmodmaprc are now simplified with this level of indirection removed.

Thanks for helping Tronar,
Ruud