Java AWT problem with less-than key
Hello, I've been fighting with a Java problem that only appears on Intel SuSE Pro 9.0-9.2 machines running KDE (as far as I know). When using the keyboard to enter text into an AWT TextField. Less-than "<" is getting converted to greater-than ">". Yast says keyboard is set to "English (US)". For fun, I tried "export LANG=en_US" (as opposed to en_US.UTF-8) to no avail. I am not (knowingly) messing with keymaps anywhere. Java appears to recognize the keycodes properly, as it correctly interprets the un-SHIFT-ed key as comma ",". A preloaded less-than sign is correctly displayed, but when the less-than key (SHIFT-comma) is entered at the keyboard, it gets converted to greater-than. Anybody else experienced this, or worked around it? Any helpful comments would be much appreciated. Maybe I'm just dense, but I can't find any key combination that will put a less-than sign in the TextField. Here's a sample program to illustrate the problem. Run the program and try keying a less-than sign into the TextField: 8X-------------- Test7.java ----------------------------X8 // Compiled with: /usr/lib/java/bin/javac Test7.java // Executed from Konsole window with: /usr/lib/java/bin/java Test7 import java.awt.*; public class Test7 { public static void main( String argv[] ) { Dialog d = new Dialog( new Frame() ); TextField ts = new TextField( "Try typing a < in here" ); d.add( ts ); d.pack(); d.setVisible( true ); } } 8X-------------- Test7.java ----------------------------X8 Java version: $ rpm -qa | grep java java-1_4_2-sun-1.4.2.05-9 java-1_4_2-sun-devel-1.4.2.05-9
On Monday 10 January 2005 21:51, Peter Szaban wrote:
Hello,
I've been fighting with a Java problem that only appears on Intel SuSE Pro 9.0-9.2 machines running KDE (as far as I know). When using the keyboard to enter text into an AWT TextField. Less-than "<" is getting converted to greater-than ">". I concur with your observation. I get the same result. -- Jerry Feldman <gaf@blu.org> Boston Linux and Unix user group http://www.blu.org PGP key id:C5061EA9 PGP Key fingerprint:053C 73EC 3AC1 5C44 3E14 9245 FB00 3ED5 C506 1EA9
participants (2)
-
Jerry Feldman
-
Peter Szaban