-
Notifications
You must be signed in to change notification settings - Fork 866
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Netbeans 14 freezes spuriously when r-clicking at Design View #4231
Comments
i believe I saw that too. It happens more often if the context menu is cascaded. Might have potentially something to do with the FlatLAF update since it added some features specific to context menus (#3983). Have to check if there is a flag for that to toggle it off for testing purposes. (or test with a different look and feel enabled) |
@DevCharly do you know of any issues with context menus? Is it possible to disable the submenu feature via a flag for testing? |
Does "Netbeans freezes" mean that the whole IDE is dead and you have to kill it?
No.
Yes, add |
For some reason I could not uploaded the thread dump when filing this issue. Here it is I captured it with visualvm, whose original extension is tdump. I edited the extension so I could upload it here |
@rapastranac thanks for the thread dump. Are there any exceptions in the NetBeans log file? I'm still not sure what you mean with "suddenly freezes". |
It freezes out of a sudden and the only pattern I found was when r-clicking.
I stopped using NetBeans 14 after that many interruptions. |
Same here since Netbeans 14 maybe two times. |
Hmm, this problem would be very good to fix. Could either of you try to see if you could manage to reliably reproduce the bug? And perhaps take a screenshot of NetBeans in the frozen state? It might be good to try another thread dump as well. |
I'm using Apache NetBeans IDE 14 with this: https://draculatheme.com/netbeans I had the same issue happen to me once I started creating and editing JFrames. Same thing: change something upon context menu (particularly the Auto Resize option) and it just freezes up everything. You have to kill NetBeans through Task Manager and open again. I just now changed NetBeans Look and Feel theme from FlatLaf Dark to something else, checked the option "Maximize use of native look and feel". It removed that front color theme I downloaded from Dracula so I added it again and changed Look and Feel back to FlatLaf Dark. I still didn't get any freeze ever since; It seemed to have solved the problem for me. So what we know from this is it's clearly something to do with themes, perhaps compatibility issues with custom themes. |
@cts93 thanks for your report and for mentioning JFrame. I can now reproduce it. I thought that it could be related to JFrame and played around and had a freeze. Steps to reproduce:
It is indeed related to FlatLaf submenu usability improvements: JFormDesigner/FlatLaf#490 (used in NB 14 since PR #3983) There are no exceptions. The stack looks OK. |
Following line in NB form designer causes the problem:
When showing a preview, the designer creates a second instance of the current L&F (either class The freeze happens because there are two listeners that both temporary install event queues:
Will add some checks to FlatLaf to prevent duplicate execution of |
@DevCharly Whoa! I didn't know you were the creator himself. Thanks for your reply and effort into improving it for all of us. |
@DevCharly I suppose we could disable the submenu improvements (as you mentioned here) for one release in NB, so that we don't have to rush fixes into FlatLaf (no need to hurry). I had the feeling it might have something to do with it, I just couldn't reproduce the exact conditions - great job for making the connection with the form designer. Btw when the freeze happens my entire xserver freezes. I have to ctrl+alt+F2 into a second session and terminate the process to recover (cinnamon desktop environment, nv drivers). |
…times, which can freeze the application caused pushing multiple event queues and popping wrong event queue first (e.g. NetBeans Form Editor invokes `FlatLaf.initialize()` but not `uninitialize()`) (PR #490; apache/netbeans#4231)
For NetBeans GUI builder, which invokes `FlatLaf.initialize()` multiple times for preview, but never invokes `FlatLaf.uninitialize()`. (apache/netbeans#4231)
PR #4375 fixes this issue 😄 |
Apache NetBeans version
Apache NetBeans latest daily build
What happened
When editing forms, when I right-click on the form and the menu is expanded, it suddenly freezes at any of the menu items
How to reproduce
When I right-click on the form and the menu is expanded, it suddenly freezes at any of the menu items, but it does not happens consistently. Maybe a multi-thread issue.
Did this work correctly in an earlier version?
Apache NetBeans 13
Operating System
Windows 10
JDK
13
Apache NetBeans packaging
Apache NetBeans provided installer
Anything else
No response
Are you willing to submit a pull request?
No
Code of Conduct
Yes
The text was updated successfully, but these errors were encountered: