[Biojava-l] How to Use SixFrameRenderer and related classes? (fwd)
hywang
hywang at scbit.org
Mon Aug 4 21:10:47 EDT 2003
Hi,
Ok.
I had just test the codes again and found that among the code to set
sixframe renderer below:
zml.addRenderer(new OverlayRendererWrapper(new StopRenderer(sixFramePane,
0, StrandedFeature.POSITIVE)));
zml.addRenderer(new OverlayRendererWrapper(new StopRenderer(sixFramePane,
1, StrandedFeature.POSITIVE)));
zml.addRenderer(new OverlayRendererWrapper(new StopRenderer(sixFramePane,
2, StrandedFeature.POSITIVE)));
zml.addRenderer(new OverlayRendererWrapper(new StopRenderer(sixFramePane,
0, StrandedFeature.NEGATIVE)));
zml.addRenderer(new OverlayRendererWrapper(new StopRenderer(sixFramePane,
1, StrandedFeature.NEGATIVE)));
//********erro seems exist the line below*****
zml.addRenderer(new StopRenderer(sixFramePane, 2,
StrandedFeature.NEGATIVE));
The bug seems lies in the line:
zml.addRenderer(new StopRenderer(sixFramePane, 2,
StrandedFeature.NEGATIVE));
I have committed the lines of code one by one ,and the error info
won't disappear until I commented the that line codes. I wonder if
it is beacause it's difference with others, so then I change it into:
zml.addRenderer(new OverlayRendererWrapper(new StopRenderer(sixFramePane,
2, StrandedFeature.NEGATIVE)));
But the same error info still came out, I have read the code of
sixframerenderer.java , but still no idea to me.;-(
Thanks a lot, and waiting for your help ;-).
Haiyan Wang,
The whole error info is :
java.lang.IndexOutOfBoundsException: Index out of range: 0
at
org.biojava.bio.seq.io.SubArraySymbolList.symbolAt(SubArraySymbolList.java:7
7)
at
org.biojava.bio.seq.impl.SimpleSequence.symbolAt(SimpleSequence.java:101)
at org.biojava.bio.gui.sequence.StopRenderer.isStop(StopRenderer.java:123)
at
org.biojava.bio.gui.sequence.StopRenderer.renderOneFrame(StopRenderer.java:1
61)
at org.biojava.bio.gui.sequence.StopRenderer.paint(StopRenderer.java:197)
at
org.biojava.bio.gui.sequence.OverlayRendererWrapper.paint(OverlayRendererWra
pper.java:145)
at
org.biojava.bio.gui.sequence.LayeredRenderer.paint(LayeredRenderer.java:186)
at
org.biojava.bio.gui.sequence.MultiLineRenderer.paint(MultiLineRenderer.java:
186)
at
org.biojava.bio.gui.sequence.SequencePanel.paintComponent(SequencePanel.java
:471)
at javax.swing.JComponent.paint(JComponent.java:808)
at javax.swing.JComponent.paintChildren(JComponent.java:647)
at javax.swing.JComponent.paint(JComponent.java:817)
at javax.swing.JViewport.paint(JViewport.java:707)
at javax.swing.JComponent.paintChildren(JComponent.java:647)
at javax.swing.JComponent.paint(JComponent.java:817)
at javax.swing.JComponent.paintWithOffscreenBuffer(JComponent.java:4771)
at javax.swing.JComponent.paintDoubleBuffered(JComponent.java:4724)
at javax.swing.JComponent._paintImmediately(JComponent.java:4668)
at javax.swing.JComponent.paintImmediately(JComponent.java:4477)
at javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:410)
at
javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(SystemEventQu
eueUtilities.java:117)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:178)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:448)
at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.ja
va:197)
at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java
:150)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:144)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:136)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:99)
java.lang.IndexOutOfBoundsException: Index out of range: 0
at
org.biojava.bio.seq.io.SubArraySymbolList.symbolAt(SubArraySymbolList.java:7
7)
at
org.biojava.bio.seq.impl.SimpleSequence.symbolAt(SimpleSequence.java:101)
at org.biojava.bio.gui.sequence.StopRenderer.isStop(StopRenderer.java:123)
at
org.biojava.bio.gui.sequence.StopRenderer.renderOneFrame(StopRenderer.java:1
61)
at org.biojava.bio.gui.sequence.StopRenderer.paint(StopRenderer.java:197)
at
org.biojava.bio.gui.sequence.OverlayRendererWrapper.paint(OverlayRendererWra
pper.java:145)
at
org.biojava.bio.gui.sequence.LayeredRenderer.paint(LayeredRenderer.java:186)
at
org.biojava.bio.gui.sequence.MultiLineRenderer.paint(MultiLineRenderer.java:
186)
at
org.biojava.bio.gui.sequence.SequencePanel.paintComponent(SequencePanel.java
:471)
at javax.swing.JComponent.paint(JComponent.java:808)
at javax.swing.JComponent.paintChildren(JComponent.java:647)
at javax.swing.JComponent.paint(JComponent.java:817)
at javax.swing.JViewport.paint(JViewport.java:707)
at javax.swing.JComponent.paintChildren(JComponent.java:647)
at javax.swing.JComponent.paint(JComponent.java:817)
at javax.swing.JComponent.paintChildren(JComponent.java:647)
at javax.swing.JSplitPane.paintChildren(JSplitPane.java:1021)
at javax.swing.JComponent.paint(JComponent.java:817)
at javax.swing.JComponent.paintChildren(JComponent.java:647)
at javax.swing.JSplitPane.paintChildren(JSplitPane.java:1021)
at javax.swing.JComponent.paint(JComponent.java:817)
at javax.swing.JComponent.paintChildren(JComponent.java:647)
at javax.swing.JSplitPane.paintChildren(JSplitPane.java:1021)
at javax.swing.JComponent.paint(JComponent.java:817)
at javax.swing.JComponent.paintChildren(JComponent.java:647)
at javax.swing.JSplitPane.paintChildren(JSplitPane.java:1021)
at javax.swing.JComponent.paint(JComponent.java:817)
at javax.swing.JComponent.paintChildren(JComponent.java:647)
at javax.swing.JComponent.paint(JComponent.java:817)
at javax.swing.JComponent.paintChildren(JComponent.java:647)
at javax.swing.JComponent.paint(JComponent.java:817)
at javax.swing.JLayeredPane.paint(JLayeredPane.java:552)
at javax.swing.JComponent.paintChildren(JComponent.java:647)
at javax.swing.JComponent.paintWithOffscreenBuffer(JComponent.java:4778)
at javax.swing.JComponent.paintDoubleBuffered(JComponent.java:4724)
at javax.swing.JComponent.paint(JComponent.java:798)
at java.awt.GraphicsCallback$PaintCallback.run(GraphicsCallback.java:21)
at sun.awt.SunGraphicsCallback.runOneComponent(SunGraphicsCallback.java:60)
at sun.awt.SunGraphicsCallback.runComponents(SunGraphicsCallback.java:97)
at java.awt.Container.paint(Container.java:1309)
at sun.awt.RepaintArea.paint(RepaintArea.java:177)
at sun.awt.windows.WComponentPeer.handleEvent(WComponentPeer.java:260)
at java.awt.Component.dispatchEventImpl(Component.java:3699)
at java.awt.Container.dispatchEventImpl(Container.java:1623)
at java.awt.Window.dispatchEventImpl(Window.java:1590)
at java.awt.Component.dispatchEvent(Component.java:3480)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:450)
at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.ja
va:197)
at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java
:150)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:144)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:136)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:99)
David Huen wrote:
> On Sat, 2 Aug 2003, hywang wrote:
>
> Could we have the whole stack trace please? The top end seems missing so
> I don't even know the Exception thrown.
>
More information about the Biojava-l
mailing list