jEdit hangs when using multiple screens
Submitted by Friday, 21 April, 2017 - 12:17
on
Hi!
Jedit version tested: 5.4.0 (compiled from source)
Java version: java-1.8.0-openjdk-amd64 (Debian)
I have tried to find any relevant info by googling, but I couldn't find any:
* Whenever I run jedit on a single screen, there are no problems, and life is happy and the sun shining.
* Whenever I run jedit on a computer using multiple screens, jedit cannot be started, or if it is already
started before, and the second screen is attached afterwards, jedit refuses to open any new windows.
When refusing to open any window, jedit says:
13:55:29 [AWT-EventQueue-1] [error] AWT-EventQueue-1: Exception in thread "AWT-EventQueue-1"
13:55:29 [AWT-EventQueue-1] [error] AWT-EventQueue-1: java.lang.IllegalArgumentException: Width (0) and height (0) must be non-zero
13:55:29 [AWT-EventQueue-1] [error] AWT-EventQueue-1: at java.awt.image.ReplicateScaleFilter.(ReplicateScaleFilter.java:102)
...
13:55:29 [AWT-EventQueue-1] [error] AWT-EventQueue-1: at sun.awt.X11.XToolkit.createCustomCursor(XToolkit.java:1140)
13:55:29 [AWT-EventQueue-1] [error] AWT-EventQueue-1: at org.gjt.sp.jedit.textarea.TextAreaPainter.addNotify(TextAreaPainter.java:181)
13:55:29 [AWT-EventQueue-1] [error] AWT-EventQueue-1: at java.awt.Container.addNotify(Container.java:2773)
...
13:55:29 [AWT-EventQueue-1] [error] AWT-EventQueue-1: at javax.swing.JComponent.addNotify(JComponent.java:4740)
13:55:29 [AWT-EventQueue-1] [error] AWT-EventQueue-1: at org.gjt.sp.jedit.textarea.TextArea.addNotify(TextArea.java:4690)
13:55:29 [AWT-EventQueue-1] [error] AWT-EventQueue-1: at java.awt.Container.addNotify(Container.java:2773)
...
13:55:29 [AWT-EventQueue-1] [error] AWT-EventQueue-1: at java.awt.Window.pack(Window.java:807)
13:55:29 [AWT-EventQueue-1] [error] AWT-EventQueue-1: at org.gjt.sp.jedit.jEdit.newView(jEdit.java:2617)
13:55:29 [AWT-EventQueue-1] [error] AWT-EventQueue-1: at org.gjt.sp.jedit.PerspectiveManager$PerspectiveHandler.endElement(PerspectiveManager.java:363)
Which obviously means that when jEdit makes a newView, it obviously triggers a TextArea.addNotify which triggers a TextAreaPainter.addNotify, which somehow delivers a window with a size of 0,0. I'm inclined to hack this in my personal copy of jEdit, if possible. Anyone have an idea why this occurs?