xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From thomas.dewe...@kodak.com
Subject Re: Batik problems in Cocoon 2.2
Date Thu, 21 Oct 2010 11:27:24 GMT
Hi Fawzib,

Fawzib Rojas <f_rojas@spectron-msim.com> wrote on 10/20/2010 03:37:18 PM:

> I don't know how to do that, never worked with Batik until now. The 
> source of the cocoon-batik-block is
> at http://www.megaupload.com/?d=NQBUKM9W

        I took a quick look at the code here, in particular SVGBuilder.
The code in that class looks really questionable to me.  It subclasses
our SAXSVGDocumentFactory and tries to manipulate the base classes state.
This is in general a bad idea and exactly the sort of hacks that tend to 
cause breakage when the baseclass code changes.

        So the one thing I noticed that at least looks like real trouble 
in the override of startDocument the class tries to set the base classes
'document' member.  But it then calls the baseclasses startDocument 
which is just going to 'null' out the document member.

        Also the attempts to manipulate the set of namespace prefixes
seems problematic to me.

> SAXSVGDocumentFactory derived object. SVGSerializerNG.java is where the 
> transcoding code is (notify function). 

        I took a look at SVGSerializerNG and I didn't see anything
wrong but since the problem with the document probably occured 
before that I don't think that means much. 

        BTW I would try printing the namespace and tag name for the root
element of the document passed to the serializer and see if that is 
(I suspect it isn't).
Thomas DeWeese | CDG Advanced Development | 
Eastman Kodak Company | 343 State Street | Rochester, NY 14650-0128 | 
Thomas.DeWeese@Kodak.com | 585 724-0294 | 

> been pulling my hair with this for over a month. The change to cocoon 
> 2.2 was painful enough (i dont like maven) I hope i can solve this last 
> problem. :)
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org

View raw message