|
uitable is very very buggy, especially when it was first introduced (I think R2008b). Which version of MATLAB are you using?
"matt dash" wrote in message <igifgh$emu$1@fred.mathworks.com>...
> Hello all,
>
> This is a pretty obscure problem, but maybe someone can make something of it. I havent yet figured out the simplest program that recreates the error as it's difficult to extract the relevant code from the larger gui. Anyway, here's what's happening:
>
> I have an exceedingly complicated gui that contains a uitable in which I have replaced the TableModel, TableCellRenderers, header renderers, and probably some other stuff with custom java classes. When I try to save the state of the gui using saveas, I get a bunch of "could not serialize object" warnings related to the uitable. Ok, I can deal with that (just need to recreate the table after opening the saved .fig file).
>
> Here's where it gets weird... after using saveas, I want to be able to keep working with the gui. However, (after using saveas) every time the gui needs to redraw, I get the java exceptions listed below, usually about a hundred times in a row, basically making the gui unusable. (Though if i open the saved version and recreate the table, it works fine.) Any ideas why using saveas would break the table? I wouldnt expect saveas to make any permanent changes to the figure, but that's what seems to be happening.
>
> here are the java errors:
>
> [ConditionalEventPump] Exception occurred during event dispatching:
> java.lang.NullPointerException
> at com.jidesoft.plaf.basic.BasicCellSpanTableUI.paint(Unknown Source)
> at javax.swing.plaf.ComponentUI.update(Unknown Source)
> at javax.swing.JComponent.paintComponent(Unknown Source)
> at javax.swing.JComponent.paint(Unknown Source)
> at javax.swing.JComponent.paintChildren(Unknown Source)
> at javax.swing.JComponent.paint(Unknown Source)
> at javax.swing.JViewport.paint(Unknown Source)
> at javax.swing.JComponent.paintChildren(Unknown Source)
> at javax.swing.JComponent.paint(Unknown Source)
> at javax.swing.JComponent.paintToOffscreen(Unknown Source)
> at javax.swing.RepaintManager$PaintManager.paintDoubleBuffered(Unknown Source)
> at javax.swing.RepaintManager$PaintManager.paint(Unknown Source)
> at javax.swing.RepaintManager.paint(Unknown Source)
> at javax.swing.JComponent._paintImmediately(Unknown Source)
> at javax.swing.JComponent.paintImmediately(Unknown Source)
> at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
> at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
> at javax.swing.RepaintManager.seqPaintDirtyRegions(Unknown Source)
> at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(Unknown Source)
> at java.awt.event.InvocationEvent.dispatch(Unknown Source)
> at java.awt.EventQueue.dispatchEvent(Unknown Source)
> at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
> at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
> at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
> at java.awt.EventDispatchThread.run(Unknown Source)
>
> or if the table's visibility is "off":
>
> [ConditionalEventPump] Exception occurred during event dispatching:
> java.lang.NullPointerException
> at javax.swing.plaf.basic.BasicTableUI.getPreferredSize(Unknown Source)
> at javax.swing.JComponent.getPreferredSize(Unknown Source)
> at javax.swing.ScrollPaneLayout.layoutContainer(Unknown Source)
> at java.awt.Container.layout(Unknown Source)
> at java.awt.Container.doLayout(Unknown Source)
> at java.awt.Container.validateTree(Unknown Source)
> at java.awt.Container.validateTree(Unknown Source)
> at java.awt.Container.validateTree(Unknown Source)
> at java.awt.Container.validateTree(Unknown Source)
> at java.awt.Container.validateTree(Unknown Source)
> at java.awt.Container.validateTree(Unknown Source)
> at java.awt.Container.validateTree(Unknown Source)
> at java.awt.Container.validateTree(Unknown Source)
> at java.awt.Container.validateTree(Unknown Source)
> at java.awt.Container.validateTree(Unknown Source)
> at java.awt.Container.validateTree(Unknown Source)
> at java.awt.Container.validateTree(Unknown Source)
> at java.awt.Container.validate(Unknown Source)
> at com.mathworks.hg.peer.FigureClientProxy.validateFigure(FigureClientProxy.java:1017)
> at com.mathworks.hg.peer.FigureMediator.validateFigure(FigureMediator.java:370)
> at com.mathworks.hg.peer.FigurePeer.validateFigure(FigurePeer.java:520)
> at com.mathworks.hg.util.HGPeerQueue$HGPeerRunnablesRunner.run(HGPeerQueue.java:281)
> at java.awt.event.InvocationEvent.dispatch(Unknown Source)
> at java.awt.EventQueue.dispatchEvent(Unknown Source)
> at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
> at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
> at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
> at java.awt.EventDispatchThread.run(Unknown Source)
|