For anyone looking for something to do: Take a look at how we are messing up the handling of NumLock. For a simple test case, install the lesstif package via Cygwin's setup.exe, run mwm.exe as your window manager, make sure NumLock is on, then try to move a MWM managed window. The window won't budge. Turn NumLock off and the window can move freely.
It may be incorrect to treat NumLock as a 'modifier key', see xc/programs/Xserver/hw/xwin/winkeybd.c/winGetKeyMappings (), but not treating NumLock as a modifier key causes the NumLock key to have no effect on whether the numerical keypad gives you numbers (NumLock on behavior) or arrows (NumLock off behavior). I think that both states of NumLock give you arrows in that case. For clues you can take a look at other servers, such as XDarwin over in xc/programs/Xserver/hw/darwin/darwinKeyboard.c. Notice that they use modifier masks LockMask (CapsLock), ShiftMask, ControlMask, AltMask, MetaMask and FunctionMask. But they don't use NumLockMask. What gives? Is NumLock a modifier key or not? If not, why doesn't it do anything in Cygwin/XFree86 when we don't treat it as a modifier? Hopefully that provides enough food for thought. Good luck, Harold
