I had some trouble with the ChartTransformer, but I have solved them and
wanted to share my results with fellow cocoon-users:
Context:
======
Cocoon2.1dev
Resin-2.1.6
Linux and Win2K
JDK 1.3.1 (_05 and _06)
(1) The use of GenericDOMImplementation produced weird SVG output:
the SVG elements had no tag names! Very bizzare. So, I thought that it
might be a problem with the DOM implementation. So, I decided to use
the SVGDOMImplementation instead of GenericDOMImplementation.
First, import the SVGDOMImplementation package (part of Batik that
is packaged with 2.1dev):
import org.apache.batik.dom.svg.SVGDOMImplementation;
Then, around line 545 (in method endElement), I made the following
change. (Sorry no patch).
// build the svg
//DOMImplementation domImpl = GenericDOMImplementation.getDOMImplementation();
//Document document = domImpl.createDocument(null , "svg", null);
DOMImplementation domImpl = SVGDOMImplementation.getDOMImplementation();
String svgNS = SVGDOMImplementation.SVG_NAMESPACE_URI;
Document document = domImpl.createDocument(svgNS,"svg",null);
(2) The ChartTransformer works under Win2K, but not under Linux! It turns out
to be a problem with headless Java. Since I am using JDK1.3.1, I had to
remember to set my DISPLAY environment variable appropriately. Duh!
I like the ChartTransformer very much. I am an experienced SVG hacker and
this has a comfortable feel with the rest of my tools. It is simpler to understand
than Wings (althought I should have spent more time with Wings). There is also
the xReporter tool that I have yet to examine carefully. Perhaps a "graph" DTD
or WXS is in our future so that "Chart" Transformers can be interchangable.
-- jack
John R. Callahan, Ph.D.
[EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]