Hello !
I've been searching everywhere for the following exception, but still don't find the answer. Please help !
I'm using Nimbus Look and Feel, and I get follow exception (GTKLookAndFeel has the same problem, whereas Metal, MotifLookAndFeel work well) :
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
at javax.swing.plaf.synth.SynthTableUI.paintCell(Synt hTableUI.java:625)
at javax.swing.plaf.synth.SynthTableUI.paintCells(Syn thTableUI.java:521)
at javax.swing.plaf.synth.SynthTableUI.paint(SynthTab leUI.java:305)
at javax.swing.plaf.synth.SynthTableUI.update(SynthTa bleUI.java:234)
at javax.swing.JComponent.paintComponent(JComponent.j ava:752)
at javax.swing.JComponent.paint(JComponent.java:1029)
at javax.swing.JComponent.paintChildren(JComponent.ja va:862)
at javax.swing.JComponent.paint(JComponent.java:1038)
at javax.swing.JViewport.paint(JViewport.java:747)
at javax.swing.JComponent.paintChildren(JComponent.ja va:862)
at javax.swing.JComponent.paint(JComponent.java:1038)
at javax.swing.JComponent.paintChildren(JComponent.ja va:862)
at javax.swing.JSplitPane.paintChildren(JSplitPane.ja va:1030)
at javax.swing.JComponent.paint(JComponent.java:1038)
at javax.swing.JComponent.paintChildren(JComponent.ja va:862)
at javax.swing.JComponent.paint(JComponent.java:1038)
at javax.swing.JComponent.paintChildren(JComponent.ja va:862)
at javax.swing.JComponent.paint(JComponent.java:1038)
at javax.swing.JLayeredPane.paint(JLayeredPane.java:5 67)
at javax.swing.JComponent.paintChildren(JComponent.ja va:862)
at javax.swing.JComponent.paint(JComponent.java:1038)
at javax.swing.JComponent.paintChildren(JComponent.ja va:862)
at javax.swing.JComponent.paint(JComponent.java:1038)
at javax.swing.JComponent.paintChildren(JComponent.ja va:862)
at javax.swing.JComponent.paint(JComponent.java:1038)
at javax.swing.JLayeredPane.paint(JLayeredPane.java:5 67)
at javax.swing.JComponent.paintChildren(JComponent.ja va:862)
at javax.swing.JComponent.paint(JComponent.java:1038)
at javax.swing.JLayeredPane.paint(JLayeredPane.java:5 67)
at javax.swing.JComponent.paintChildren(JComponent.ja va:862)
at javax.swing.JComponent.paintToOffscreen(JComponent .java:5131)
at javax.swing.BufferStrategyPaintManager.paint(Buffe rStrategyPaintManager.java:278)
at javax.swing.RepaintManager.paint(RepaintManager.ja va:1224)
at javax.swing.JComponent.paint(JComponent.java:1015)
at java.awt.GraphicsCallback$PaintCallback.run(Graphi csCallback.java:21)
at sun.awt.SunGraphicsCallback.runOneComponent(SunGra phicsCallback.java:60)
at sun.awt.SunGraphicsCallback.runComponents(SunGraph icsCallback.java:97)
at java.awt.Container.paint(Container.java:1780)
at java.awt.Window.paint(Window.java:3375)
at javax.swing.RepaintManager.paintDirtyRegions(Repai ntManager.java:796)
at javax.swing.RepaintManager.paintDirtyRegions(Repai ntManager.java:713)
at javax.swing.RepaintManager.seqPaintDirtyRegions(Re paintManager.java:693)
at javax.swing.SystemEventQueueUtilities$ComponentWor kRequest.run(SystemEventQueueUtilities.java:125)
at java.awt.event.InvocationEvent.dispatch(Invocation Event.java:209)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.j ava:641)
at java.awt.EventQueue.access$000(EventQueue.java:84)
at java.awt.EventQueue$1.run(EventQueue.java:602)
at java.awt.EventQueue$1.run(EventQueue.java:600)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectio nPrivilege(AccessControlContext.java:87)
at java.awt.EventQueue.dispatchEvent(EventQueue.java: 611)
at java.awt.EventDispatchThread.pumpOneEventForFilter s(EventDispatchThread.java:269)
at java.awt.EventDispatchThread.pumpEventsForFilter(E ventDispatchThread.java:184)
at java.awt.EventDispatchThread.pumpEventsForHierarch y(EventDispatchThread.java:174)
at java.awt.EventDispatchThread.pumpEvents(EventDispa tchThread.java:169)
at java.awt.EventDispatchThread.pumpEvents(EventDispa tchThread.java:161)
at java.awt.EventDispatchThread.run(EventDispatchThre ad.java:122)
I've tried :
- add SwingWorker thread for the long process
- call UIManger.setLookAndFeel("com.sun.java.swing.plaf.n imbus.NimbusLookAndFeel") after initialize my Frame
- add :
EventQueue queue = Toolkit.getDefaultToolkit().getSystemEventQueue();
queue.push(new EventQueue() {
@Override
protected void dispatchEvent(AWTEvent event) {
try {
super.dispatchEvent(event);
} catch (Throwable t) {
System.out.println(super.getCurrentEvent());
System.out.println(event.getSource());
t.printStackTrace();
System.out.println(t.getMessage() );
}
}
});
and I get java.awt.event.InvocationEvent[INVOCATION_DEFAULT,runnable=javax.swing.SystemEven tQueueUtilities$ComponentWorkRequest@64959a7a,noti fier=null,catchExceptions=false,when=1360338783958] on sun.awt.X11.XToolkit@472462b3
java.lang.NullPointerException
sun.awt.X11.XToolkit@472462b3
null
Someone can help me ?