JDK: 1.4.1-rc
OS: Windows 98
The following code should let native IME to process all the input method events. But on some Chinese Windows98 environment, the Java's input window(for Chinese input) will still show up.
-------- Start -----------
import java.awt.*;
import java.awt.im.*;
import javax.swing.*;
class PassiveSwing extends JFrame {
public static void main(String[] s) {
new PassiveSwing();
}
PassiveSwing() {
Container c = getContentPane();
c.setLayout(new BorderLayout());
c.add(new JTextPane() {
public InputMethodRequests getInputMethodRequests() {
return null;
}
});
setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
setSize(200, 100);
setVisible(true);
}
}
-------- End -----------