duderstadt-lab / mars-fx

BSD 2-Clause "Simplified" License
3 stars 1 forks source link

NPE from rendering NGNodes when changing tabs in a MoleculeArchive #41

Closed karlduderstadt closed 2 years ago

karlduderstadt commented 3 years ago

This NullPointerException happens when changing from the molecules to metadata tab in the GUI. I have a fairly small archive (1 metadata, 29 molecules). It happens every time now for this archive when I change tabs. It is resolved upon re-opening the archive. Also, when this happens, the GUI gets really slow whenever I press another tab. Restarting Fiji completely usually resolves this again. Also, I have the feeling I get this behaviour more often if I try to switch tabs fast or accidentally click multiple times

Screenshot 2021-06-22 at 11 26 08 Screenshot 2021-06-22 at 11 26 14
karlduderstadt commented 2 years ago

These start happening sometimes after a long session and once they start things slow down and Fiji must be restarted. Seems they results from a problem of attempting to draw a pane that is too large perhaps. This issue has happened to me on a MacBook pro intel. It might be related to the video card that is being used because I have never seen this in linux.

Screenshot 2021-11-06 at 10 44 11
karlduderstadt commented 2 years ago

And another one..

Screenshot 2021-11-07 at 08 25 20

..

karlduderstadt commented 2 years ago

I guess the only clue is that these error only happen when changing tabs. So perhaps it is worth reviewing exactly what is called when tabs are changed and to make sure all pane are resonably sized. Hmm..

karlduderstadt commented 2 years ago

I believe this issue might be solve now and was related to using JFXPanel in a JFrame. in https://github.com/duderstadt-lab/mars-fx/commit/cabffc4ad079cecf317c98cb6fad249b44a2d59b and several others we switched to using a Stage and a Frame wrapper for interactions with ImageJ.