GNOME Bugzilla – Bug 105963
Arrow keys are being ignored in Java Applications
Last modified: 2004-12-22 21:47:04 UTC
For some reason arrow key movements with Java Applications are somehow being consumed by gnopernicus. This is making java apps quite unusable.
Hi. I need more information about, in which application, on which OS (Solaris v linux), and how can reproduce this bug.
Specifically, I'm using Java's JFC demo program StylePad. I'm using Linux RedHat 7.1 with the GNOME 2.0 nightly from Feb 2, 2003. (And a slightly more recent build of gnopernicus). To reproduce, run StylePad using a JDK with GNOME accessibility enabled: java -jar $JAVA_HOME/demo/jfc/StylePad/StylePad.jar Run Gnopernicus. Now focus the StylePad window and type in text, then try to use the arrow keys (not the Num Pad arrows, but the seperate keys beside the NumPad) to move the caret around the text. This fails to do anything.
I made a workaround to does not eat the not interested keys, but the issue is in the java-access-bridge because it is return a not register keyevents. The modificatioin on CVS head.
Didn't mean to close this one, yet... Sorry..
note: these are desired for key echo.
Paul, Are you saying that there is a bug in the Java Access Bridge? If so, can you give more detail as I do not understand it.
Padraig: I think the problem is that somehow gnopernicus is consuming the 'regular' arrow keys when java apps are running. gnopernicus needs to consume the numberpad keys, but not the 'normal' arrow keys. I suspect that the problem may be that for some reason gnopernicus' request for numpad arrow keys is resulting in notifications for (non-KP) arrow keys as well, resulting in those keys being consumed. Assuming this is so, there are several potential causes and several possible approaches. Next step I guess is to identify exactly which events are affected and why they are reported&consumed, and whether there's a way to distinguish between them in Java. If there is, then j-a-b needs code to do this filtering I guess; or possibly there is a j-a-b bug at work. If there is not, then we may be blocked on Java.
Hi Bill: The arrows keys did NOT consumed by the gnopernicus. Gnopernicus after he get a event, it return the key event for other application. Gnopernicus consume only the numpad keys and the user defined keys. Padraig: I checked it again this bug whit a version of gnome 2.2 stack from 09_05_2003. This bug I can not reproduce now. I think it fixed in at-spi or in j-a-b in the time. I describe what is the bug: At gnopernicus can regester key combinations, called user keys. (ex CTRL-a). Gnopernicus register this combinations.The registartion are made with keystring registartion. On gnome toolkit the keylistener listened only the registered keys, but on java toolkit was occure key event which is not regitered, in our example the arrows keys. In this listener all keys are consumed. And in this case the arrows keys was comsumed. I thinks the problem was with a registartion of keystrings, because at-spi returned "_" keystring in java toolkit for arrows keys, perhaps one of the registration was made incorrect in server from at-spi/j-a-b, and the at-spi/j-a-b are registered whit this "_" string. After the client listened all keys which has a returned keystring "_". I say again. I checked it again, and I don't see this bug with this version of stack.
when Paul mentions "_" keystrings, what he was really seeing were ASCII/UNICODE control codes which are properly returned in the "string" field for control-key combinations. It may be that JABG returned control-strings in the "string" field for arrow keys. I think this should be investigated once more so that we understand what was happenning here. Paul, your description of why events were being consumed (i.e. returned to the "wrong" listener) matches with what I was trying to say earlier, when I said "gnopernicus is consuming the arrow keys"; gnopernicus was possibly consuming them because they were being returned to a listener which had registered for some OTHER keys, I did not mean that the error was in gnopernicus.
I have checked the name reported when arrow keys are pressed in a Java application. The names are "Up" "Down" "Left" and "Right".
As this bug cannot be reproduced with gnome 2.2 stack from 09_05_2003 I am closing it.