[FreeNX-kNX / X++ Booster] Problem with some keys in Java apps with NX

Achim Bursian abu.aud at siemens.com
Mon Jul 16 18:12:50 UTC 2007


(Sorry, my first post went to the wrong thread due to my mistake, excuse me 
for reposting it)

Hi everybody,
we are running the nxagent on a Solaris box, and the client on Windows with
german keyboard. Some characters like {, [, | have to be generated with the
"AltGr" key on such a keyboard. This works fine for all apps, xev shows the
correct events and keysyms, see below (Mode_switch is the AltGr key)

But all Java apps we are running do *not* recognize these chars.Instead of {
(which is on the "7" key), they simply show "7", as if AltGr hadn't been
pressed. Very frustrating, especially if you want to write code in a
Java-based editor (we use JEdit, and SunStudio11 as IDE).
With Java 1.6, the problem is gone, but we can't use that due to performance
bottlenecks in that version with SunStudio :( We have to stick with 1.4.2 or
1.5 JVM.

The problem is ONLY present in NX sessions, of course.

Does anybody here have an idea how to solve this? Do Java apps do their own
keycode translation, not using XLib? Why is the behaviour under NX so
different? Actually, the same misbehaviour is present if I only use nxproxy
on both sides, without nxagent. So it seems to be a problem of the transport
layer???

The weirdest thing is: Some keys do work with AltGr, it's simply not
consistent. E.g. the "2" key has this xmodmap entry:

    keycode  11 = 2 quotedbl twosuperior oneeighth

If I press AltGr-2, I get the twosuperior even in a Java app. But
AltGr-Shift-2 does not yield oneeighth, only "2".

Now look at the "7" key:
    keycode  16 = 7 slash braceleft seveneighths
No matter what I press, I never get braceleft or seveneighths :(

Sorry for the long post, but I'm desperate!
Any help?
    -Achim

KeyPress event, serial 27, synthetic NO, window 0x1a00001,
      root 0x56, subw 0x0, time 3479972052, (10,576), root:(53,639),
      state 0x0, keycode 113 (keysym 0xff7e, Mode_switch), same_screen YES,
      XLookupString gives 0 characters:  ""

KeyPress event, serial 30, synthetic NO, window 0x1a00001,
      root 0x56, subw 0x0, time 3479972468, (10,576), root:(53,639),
      state 0x2000, keycode 16 (keysym 0x7b, braceleft), same_screen YES,
      XLookupString gives 1 characters:  "{"





More information about the FreeNX-kNX mailing list