Hi

I am using a JSVGCanvas to load multiple svg files one after the other.The svgCanvas object is contained within a JSVGScrollPane.In addition to the svgCanvas object the scrollpane has a JPanel added to it's West. before I load a new svg file, I try to clear the the cached image from JSVGCanvas by calling
 
pane.hide();
svgCanvas.getUpdateManager().getUpdateRunnableQueue().invokeLater(new Runnable() {
        public void run() {
               svgCanvas.flush() ;
               svgCanvas.flushImageCache();
               svgCanvas.setSVGDocument(null);
        }
 }
but many times the canvas doesn't clear the image and holds on to the previously loaded image.
I tried putting the panel.hide(); inside the updatethread, before as well as after the setSVGDocument statement. but it didn't help.
 is there any sure shot way of clearing the cached image within a svgCanvas?
 
Thanks a bunch
Chandra Srinivasan
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to