Ok, I will have a look at it, thanks!
regards Thomas Tonny Kohar <[EMAIL PROTECTED]> 15.03.2007 09:45 Bitte antworten an batik-users@xmlgraphics.apache.org An batik-users@xmlgraphics.apache.org Kopie Thema Re: error messages from JSVGCanvas Hi, On Thu, 2007-03-15 at 08:10 +0100, [EMAIL PROTECTED] wrote: > I've a question about the "error messages" shown by the JSVGCanvas. > When something goes wrong during rendering a document (basically when > calling the setDocument() method on the JSVGCanvas) like running out > of memory or missing of a required svg attribute the JSVGCanvas shows > an error dialog. > > Now in my application (where I use a JSVGCanvas) I would rather have > the canvas throwing an exception then showing theses messages so I can > handle these problems myself in the application. Is there any way I > can do something about it? > I do not use JSVGCanvas directly so I do not know how to apply it. But by looking at Batik Source Code, I think you could handle the error by extending and registered your own user agent Please look at the following: - org.apache.batik.swing.JSVGCanvas.CanvasUserAgent the methods displayError - org.apache.batik.swing.svg.SVGUserAgentGUIAdapter the methods displayError - org.apache.batik.util.gui.JErrorPane Regards Tonny Kohar -- Sketsa SVG Graphics Editor http://www.kiyut.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]