Anton Ryazantsev created BATIK-1078: ---------------------------------------
Summary: SVGDocument not showing Key: BATIK-1078 URL: https://issues.apache.org/jira/browse/BATIK-1078 Project: Batik Issue Type: Bug Reporter: Anton Ryazantsev Here is the part of code, working with Batik: SAXSVGDocumentFactory svgDocumnetFactory = new SAXSVGDocumentFactory(XMLResourceDescriptor.getXMLParserClassName()); SVGDocument svgDoc = svgDocumnetFactory.createSVGDocument(new File("").toURI().toString(), new StringReader(svgText)); JSVGCanvas currentCanvas = new JSVGCanvas(someSVGUserAgentAdapter, true, false); currentCanvas.setDocument(svgDoc); currentCanvas.setDocumentState(JSVGCanvas.ALWAYS_DYNAMIC); Sometimes I get an exception and my svg document not showing. Here is the exception: java.lang.NullPointerException at sun.font.FileFontStrike.getCachedGlyphPtr(FileFontStrike.java:441) at sun.font.FileFontStrike.getGlyphImagePtr(FileFontStrike.java:357) at sun.font.FileFontStrike.getGlyphMetrics(FileFontStrike.java:724) at sun.font.FileFontStrike.getGlyphMetrics(FileFontStrike.java:707) at sun.font.CompositeStrike.getGlyphMetrics(CompositeStrike.java:120) at sun.font.StandardGlyphVector$GlyphStrike.addDefaultGlyphAdvance(StandardGlyphVector.java:1757) at sun.font.StandardGlyphVector.initPositions(StandardGlyphVector.java:1295) at sun.font.StandardGlyphVector.getGlyphPosition(StandardGlyphVector.java:416) at org.apache.batik.gvt.font.AWTGVTGlyphVector.performDefaultLayout(Unknown Source) at org.apache.batik.gvt.text.GlyphLayout.doExplicitGlyphLayout(Unknown Source) at org.apache.batik.gvt.text.GlyphLayout.adjustTextSpacing(Unknown Source) at org.apache.batik.gvt.text.GlyphLayout.getAdvance2D(Unknown Source) at org.apache.batik.gvt.renderer.StrokingTextPainter.getTextChunk(Unknown Source) at org.apache.batik.gvt.renderer.StrokingTextPainter.computeTextRuns(Unknown Source) at org.apache.batik.gvt.renderer.StrokingTextPainter.getTextRuns(Unknown Source) at org.apache.batik.gvt.renderer.StrokingTextPainter.getBounds2D(Unknown Source) at org.apache.batik.gvt.TextNode.getPrimitiveBounds(Unknown Source) at org.apache.batik.gvt.AbstractGraphicsNode.getTransformedPrimitiveBounds(Unknown Source) at org.apache.batik.gvt.AbstractGraphicsNode.getTransformedBounds(Unknown Source) at org.apache.batik.gvt.CompositeGraphicsNode.getPrimitiveBounds(Unknown Source) at org.apache.batik.gvt.CompositeGraphicsNode.getTransformedPrimitiveBounds(Unknown Source) at org.apache.batik.gvt.AbstractGraphicsNode.getTransformedBounds(Unknown Source) at org.apache.batik.gvt.CompositeGraphicsNode.getPrimitiveBounds(Unknown Source) at org.apache.batik.gvt.CompositeGraphicsNode.getTransformedPrimitiveBounds(Unknown Source) at org.apache.batik.gvt.AbstractGraphicsNode.getTransformedBounds(Unknown Source) at org.apache.batik.gvt.CompositeGraphicsNode.getPrimitiveBounds(Unknown Source) at org.apache.batik.gvt.filter.GraphicsNodeRable8Bit.getBounds2D(Unknown Source) at org.apache.batik.gvt.filter.GraphicsNodeRable8Bit.createRendering(Unknown Source) at org.apache.batik.gvt.renderer.StaticRenderer.renderGNR(Unknown Source) at org.apache.batik.gvt.renderer.DynamicRenderer.updateWorkingBuffers(Unknown Source) at org.apache.batik.gvt.renderer.StaticRenderer.clearOffScreen(Unknown Source) at org.apache.batik.swing.gvt.GVTTreeRenderer.run(Unknown Source) There is nothing else in log. What could be wrong? I think it's a bug. -- This message was sent by Atlassian JIRA (v6.2#6252) --------------------------------------------------------------------- To unsubscribe, e-mail: batik-dev-unsubscr...@xmlgraphics.apache.org For additional commands, e-mail: batik-dev-h...@xmlgraphics.apache.org