This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
When running NetBeans 5.5 and JDK 1.6 on SuSE Linux 10.2, they keyboard stops responding after pressing Ctrl+F and then Esc twice. At first I thought it was due to the Beryl window manager, but I've confirmed it happens using metacity, or even twm. Everything works fine with JDK 1.5.0_10. The problem is also present with the current 6.0dev version of NetBeans. The problem also happens when there are existing windows open when I start NetBeans. Double-clicking a tab to maximize the tab reactivates the keyboard until I press CTRL+F and Escape twice again. To reproduce: 1. Load NetBeans 2. Open a .java file 3. Exit NetBeans 4. Load NetBeans again 5. Keyboard is frozen 6. Double-click file tab to maximize 7. Keyboard is unfrozen 8. Press CTRL+F and find 'abc' 9. Press Escape to close the Find dialog 10. Press Escape to clear the red status bar 11. Keyboard is frozen 12. Double-click file tab to restore. 13. Keyboard is unfrozen again.
I am sorry, but I could not reproduce this behavior neither with 5.5 nor 6.0. Are you sure that it's Netbeans and not something else interfering. I have FC5, Gnome, JDK1.5.0_07 and JDK1.6.0-beta2.
I don't have the issues with any other application. I'm using: java version "1.6.0" Java(TM) SE Runtime Environment (build 1.6.0-b105) Java HotSpot(TM) Client VM (build 1.6.0-b105, mixed mode, sharing) SuSE 10.2, Linux 2.6.18.2-34-bigsmp #1 SMP Using Beryl window manager, Gnome, nVidia GeForce 6800, TwinView Same configuration works perfectly with JDK 1.5.0_10 but fails with JDK 1.6.0-b105.
Hmm, something could be wrong with focus. Can you confirm that the focus is in editor (ie. blinking cursor, editors tab colored)? Do you really have to double-click the tab to fix the problem or would it be enough to just single-click it (ie. place the focus in the editor pane)?
The problem #2 reported in the issue #87467 looks similar to yours. Are you setting the AWT_TOOLKIT environment variable?
I've just googled this - http://wiki.beryl-project.org/wiki/Java. There seem to be some issues with using Beryl in JDK6, which are likely to affect Netbeans as well. Afterall Netbeans is just a swing application like any other. Also please see the bugreport here - http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6509038. I am sorry, but we might not be able to help you if this is a general Beryl vs JDK6 issue.
Closing as invalid since this is caused by the jdk issue with Beryl very likely. If fixing of the jdk issue would not help to resolve this problem please reopen this issue. Thanks.
Hi - sorry, I'd like to reopen this. I initially figured this was a Beryl-related issue. However, if you read my initial message closely, I've confirmed it happens using metacity, or even twm window managers, so it doesn't appear to be specific to Beryl. I also tried all the advice, even patching JDK 1.6. I tried again today, and confirmed that the focus is in the editor. Cursor is blinking, and the editor tab is colored. Single clicking a tab, alt+tabbing and clicking in the window don't seem to make a difference. I'm a developer and I'd be happy to try and debug this if you give me some guidance. How can I help further diagnose the problem?
OK, could you please edit netbeans.conf and add -J-Dnetbeans.debug.editor.caret.focus=true so that we know more regarding focus handling? Thanks.
Okay, I added -J-Dnetbeans.debug.editor.caret.focus=true and tried with Metacity (note: not Beryl. I did pkill beryl and loaded metacity instead). I observed tail-f messages.log on my second monitor: 1. Loaded NetBeans: BaseCaret.focusGained(); doc=/files1/data/projects/scratch/src/scratch/Main.java 2. Tried typing. It accepted my characters. Nothing logged. 3. Pressed CTRL+F: BaseCaret.focusLost(); doc=/files1/data/projects/scratch/src/scratch/Main.java FOCUS GAINER: javax.swing.plaf.metal.MetalComboBoxEditor$1[,0,0,247x23,layout=javax.swing.plaf.basic.BasicTextUI$UpdateHandler,alignmentX=0.0,alignmentY=0.0,border=javax.swing.plaf.metal.MetalComboBoxEditor$EditorBorder@5eae58,flags=8388904,maximumSize=,minimumSize=,preferredSize=,caretColor=sun.swing.PrintColorUIResource[r=51,g=51,b=51],disabledTextColor=javax.swing.plaf.ColorUIResource[r=184,g=207,b=229],editable=true,margin=javax.swing.plaf.InsetsUIResource[top=0,left=0,bottom=0,right=0],selectedTextColor=sun.swing.PrintColorUIResource[r=51,g=51,b=51],selectionColor=javax.swing.plaf.ColorUIResource[r=184,g=207,b=229],columns=9,columnWidth=10,command=,horizontalAlignment=LEADING] 4. Pressed ESC: BaseCaret.focusGained(); doc=/files1/data/projects/scratch/src/scratch/Main.java 5. Tried to type. Nothing happened. Cursor just blinks at me. Nothing logged. 6. Double-clicked tab for Main.java. It maximed and logged nothing. 7. Tried to type. Accepted characters.
Thanks, so it seems that the caret gets a regular focus event but the keystrokes do not go to the editor pane. I have no idea what could be wrong but I doubt it would be related to the editor. Reassigning to core/winsys in a hope that they could advice some additional logging that would help to identify the problem. Thanks.
This is just confirming that the problem still exists with JDK 1.6.0_01.
Hi, I just wanted to add that I'am seeing the same problem and I'm also using jdk 1.6.0. By following the reproduction stages in this thread I can consistently reproduce the problem. I'm running Ubuntu Feisty Fawn 7.0.4 and Netbeans 5.5
Confirming this still exists with JDK 1.6.0_02. I also want to report that steps 1-10 work fine for me with JDK 1.6.0 and JDK 1.6.0_01 now. I guess it is project-dependent whether it is locked up as soon as I load NB. However, I can always reproduce this starting from step 8 (Ctrl+F) on any JDK 1.6.
Confirmed it also still exists with m10 of NetBeans 6
It started to happen on my Ubuntu feisty 7.04 too...hm, there might be a problem deeper in Swing code, I will look at it after I return from vacation. Definitely P2, not being able to write in editor or do anything with keyboard is a serious error...
*** Issue 101520 has been marked as a duplicate of this issue. ***
Hello here, After some evaluation and trying, I was able to reproduce the bug even with SwingSet2 demo in JDK. So it's JDK issue, not directly NetBeans related. I entered new JDK bug http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6598651 and wrote here all I know. I still think that installation of Beryl WM is triggering the bug, even if WM is switched to Metacity later. Closing as wontfix, will see what happens in http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6598651 markroth8, don't be afraid to wrote further observation or help JDK guys if you know why. We both can reproduce 100% so we have the chance to chase it down :-)
Hi, I am an engineer who is responsible for http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6598651. It would be nice to recheck if the problem really reproducible with metacity (btw which version do you use?) But it would be better to not kill Beryl, but start your session with metacity (to have clean environment). Also, I wonder if the problem is reproducible with Compiz. thanks in advance.
Hi Oleg, Yes, that's what I tried - start clean session with Metacity, selecting on login screen after machine reboot. But even with that setup, error is 100% reproducible for me. But we tried on very similar configuration of my colleague and error was not reproducible here, with only main difference between our setups that he didn't have Beryl installed in his Ubuntu 7.04. I will check with compiz on Monday when I'm near my Linux, but I guess error will be reproducible for me, as always :-)
*** Issue 94316 has been marked as a duplicate of this issue. ***
*** Issue 98071 has been marked as a duplicate of this issue. ***
*** Issue 107120 has been marked as a duplicate of this issue. ***
Hi Oleg, As you can see from a lot of duplicates, our customers are facing the problem quite frequently. If you could install beryl , you'll be able to reproduce easily and you would have the chance to fix the problem. I actually think that beryl WM just helps the error to appear always, but bug isn't only beryl specific.
I will (try) to install the Beryl, though it is unclear for me how it can cause the problem if it is not executed. Anyway will try to reproduce the problem.
Good news (for NB) and bad news for me: I've installed Beryl and was able to reproduce the problem (w/o running Beryl itself). Will investigate what is the cause of the problem.
Thanks Oleg, I'm glad to hear this and hope that error won't be hard to fix.
It looks like in my case the problem is caused not by Beryl, but by scim (input method engine). As soon as I uninstall it I can not reproduce the problem :( Can someone who can reproduce the problem run java with level for sun.awt.X11.kye logger set to FINEST and send me back (or attach to this issue). I just want to check if the problem I see is the same as you have or not. Thanks in advance
Oleg, i tried to enable logging, but with no success. I think i would need more guidance... I run netbeans with J-Dsun.awt.X11.kye.level=0 (as I learned from http://bits.nbextras.org/dev/javadoc/org-openide-util/org/openide/util/doc-files/logging.html) but no logs on the console... However, I find out that I can reproduce the error only on some JDK version, specifically: JDK 1.5.0_12 - OK JDK 1.6.0_02 - bug occurs JDK 1.6.0_05 build 5 - OK JDK 1.7.0 (build 1.7.0-ea-b11) - bug occurs. Huh, strange...
I usually use config file for this: handlers= java.util.logging.FileHandler, java.util.logging.ConsoleHandler .level= INFO java.util.logging.FileHandler.pattern = java%u.log java.util.logging.FileHandler.limit = 50000 java.util.logging.FileHandler.count = 1 java.util.logging.FileHandler.level = FINEST java.util.logging.FileHandler.formatter = java.util.logging.SimpleFormatter java.util.logging.ConsoleHandler.level = FINEST java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter sun.awt.X11.kye.level = FINEST ------------ And than specify it using -Djava.util.logging.config.file=myfile after this you should have output in console and java<digit>.log in the current directory (at least Ihope so ;)
I finally managed to get some logs - but I was unable to get just sun.awt.X11.kye logs, it seems that no logger of name "sun.awt.X11.kye" exists. So I'm attaching log from all loggers, set global .level= FINEST What I did: - opened SwingSet2 demo - move and click mouse into "Frame title" text field - wrote "aaa" text - press Alt+F, then arrow and enter to invoke About box - finish About box with mouse click on OK button - tried to write into "Frame title" again (nothing happened, bug is showing there) - ended SwingSet2 by Alt + F4 press all is under jdk 1.7.0, (build 1.7.0-ea-b11)
Created attachment 53592 [details] java log
Uff, I found what is causing problems on my machine - phrebejk told me several days ago, but I didn't pay necessary attention :-( Problem is related to the line export AWT_TOOLKIT=MToolkit, which I added to my .bashrc in order to fix java problems under Beryl, especially "blank windows" problem. After removing AWT_TOOLKIT=MToolkit, keyboard works OK for me and I can't reproduce this issue. (yes I had to patch jdk to get rid of "blank windows" problem, but that's another story). I read http://forums.java.net/jive/thread.jspa?messageID=246986&tstart=0 and it seems there are some more problems, but i'm not sure I can help with reproduction of these...
Ok, so now we know that this is a focus problem with MToolkit. I have update the AWt bug with this information.
*** Issue 87467 has been marked as a duplicate of this issue. ***
v/c
I just want to add that Float/Dock fix focus problem. I'm on Linux chl-devworkl6 2.6.32-24-jump2.00 #1 SMP Fri Mar 11 08:33:22 CST 2011 x86_64 GNU/Linux java -version java version "1.6.0_18" OpenJDK Runtime Environment (IcedTea6 1.8) (6b18-1.8-0ubuntu1) OpenJDK 64-Bit Server VM (build 14.0-b16, mixed mode) But I would like to know the "FIX", not the workaround.