You are viewing a plain text version of this content. The canonical link for it is here.
Posted to batik-users@xmlgraphics.apache.org by Sean Wheller <se...@inwords.co.za> on 2007/01/02 17:59:38 UTC

flowRegion

Hi,

Whenever I have a document with a flowRegion batik is failing. Is there a work 
around?

Sample from SVG

<flowRoot
     xml:space="preserve"
     id="flowRoot1347"
     transform="translate(-320.5221,-275.8703)"><flowRegion
       id="flowRegion1349"><rect
         id="rect1351"
         width="93.008842"
         height="76.461258"
         x="358.91141"
         y="347.66333" /></flowRegion><flowPara
       id="flowPara1353">Your FAF numbers are 
081123456,082479628,083635846,084695691,085965555,086789654</flowPara></flowRoot>  

output of batik.

Converting ussd-faf-get-response.svg 
to ../build/images/ussd-faf-get-response.png ... 
org.apache.batik.transcoder.TranscoderException: null
Enclosed Exception:
The current document is unable to create an element of the requested type 
(namespace: http://www.w3.org/2000/svg, name: flowRoot).
	at org.apache.batik.transcoder.XMLAbstractTranscoder.transcode(Unknown 
Source)
	at org.apache.batik.transcoder.SVGAbstractTranscoder.transcode(Unknown 
Source)
	at org.apache.batik.apps.rasterizer.SVGConverter.transcode(Unknown Source)
	at org.apache.batik.apps.rasterizer.SVGConverter.execute(Unknown Source)
	at org.apache.batik.apps.rasterizer.Main.execute(Unknown Source)
	at org.apache.batik.apps.rasterizer.Main.main(Unknown Source)
... error (SVGConverter.error.while.rasterizing.file)
-- 
Sean Wheller
Technical Author
email: sean@inwords.co.za
im: seanwhe@jabber.org
skype: seanwhe
cel: +27-84-854-9408
web: http://www.inwords.co.za

---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org


Re: flowRegion

Posted by th...@kodak.com.
Hi Sean,

Sean Wheller <se...@inwords.co.za> wrote on 01/03/2007 09:01:25 AM:

> On Wednesday 03 January 2007 13:06, thomas.deweese@kodak.com wrote:
> > you need to mark your SVG Document as being version 
> > 1.2 (the version attribute must be on root svg element):
> >
> >         <svg version="1.2"

> OK, now that looks like a problem in Inkscape.

   Yes, Inkscape should add the version attribute if it 
is using features from SVG 1.2.

   However, even if Inkscape fixes this you still have
this problem:

> >    We also require that the 'flowPara' element be wrapped
> > in  a 'flowDiv' element.

   Which is why I earlier suggested, that you look into
preprocessing your SVG with an XSLT script in docbook. I
don't know much about DocBook but I would be surprised if
you couldn't set it up to run your source SVG through a
stylesheet before rendering it.  This would let you take
care of all this stuff (Adding the onload script, wrapping
the flowPara with a flowDiv, and setting the version attribute).

RE: [Inkscape-user] flowRegion

Posted by J....@ewi.utwente.nl.
> Sean Wheller wrote:
> 
> On Wednesday 03 January 2007 13:06, thomas.deweese@kodak.com wrote:
> >
> > So you need to mark your SVG Document as being version
> > 1.2 (the version attribute must be on root svg element):
> >
> >         <svg version="1.2"
[...]
> I am using Inkscape 0.43 (Mar  9 2006) on Kubuntu 6.0.6 
> (Dapper). Inkscape automatically creates the svg as follows:
> 
> <svg
>    xmlns:dc="http://purl.org/dc/elements/1.1/"
>    xmlns:cc="http://web.resource.org/cc/"
>    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
>    xmlns:svg="http://www.w3.org/2000/svg"
>    xmlns="http://www.w3.org/2000/svg"
>    xmlns:sodipodi="http://inkscape.sourceforge.net/DTD/sodipodi-0.dtd"
>    xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
>    width="744.09448819"
>    height="1052.3622047"
>    id="svg2"
>    sodipodi:version="0.32"
>    inkscape:version="0.43"
>    sodipodi:docbase="/home/sean"
>    sodipodi:docname="test.svg">
> 
> Note it does not supply @version but does create @id with 
> value of svg2.

After a quick test: v0.45+devel does the same when saving as "Inkscape SVG" but not when saving as "Plain SVG". In a "Plain SVG", @version is present but it is set to "1.0". I do not know enough about the SVG standard to know whether the version number Inkscape writes is correct or not.
Indeed I think Inkscape should also write @version in "Inkscape SVG"s, could you please post a bug report?

Regards,
Johan

---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org


Re: flowRegion

Posted by Sean Wheller <se...@inwords.co.za>.
On Wednesday 03 January 2007 13:06, thomas.deweese@kodak.com wrote:
> Hi Sean,
>
> Sean Wheller <se...@inwords.co.za> wrote on 01/02/2007 11:59:38 AM:
> > Whenever I have a document with a flowRegion batik is failing. Is
> > there a work around?
> >
> > <flowRoot
>
>    flowRoot was from SVG 1.2 (be warned it is no longer part of
> SVG 1.2).
>
> So you need to mark your SVG Document as being version 
> 1.2 (the version attribute must be on root svg element):
>
>         <svg version="1.2"
>
> >          y="347.66333" /></flowRegion><flowPara
> >        id="flowPara1353">Your FAF numbers are
> > 081123456,082479628,083635846,084695691,085965555,
> > 086789654</flowPara></flowRoot>
>
>    We also require that the 'flowPara' element be wrapped
> in  a 'flowDiv' element.

OK, now that looks like a problem in Inkscape.

I am using Inkscape 0.43 (Mar  9 2006) on Kubuntu 6.0.6 (Dapper). Inkscape 
automatically creates the svg as follows:

<svg
   xmlns:dc="http://purl.org/dc/elements/1.1/"
   xmlns:cc="http://web.resource.org/cc/"
   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
   xmlns:svg="http://www.w3.org/2000/svg"
   xmlns="http://www.w3.org/2000/svg"
   xmlns:sodipodi="http://inkscape.sourceforge.net/DTD/sodipodi-0.dtd"
   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
   width="744.09448819"
   height="1052.3622047"
   id="svg2"
   sodipodi:version="0.32"
   inkscape:version="0.43"
   sodipodi:docbase="/home/sean"
   sodipodi:docname="test.svg">

Note it does not supply @version but does create @id with value of svg2.

-- 
Sean Wheller
Technical Author
email: sean@inwords.co.za
im: seanwhe@jabber.org
skype: seanwhe
cel: +27-84-854-9408
web: http://www.inwords.co.za

---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org


Re: flowRegion

Posted by th...@kodak.com.
Hi Sean,

Sean Wheller <se...@inwords.co.za> wrote on 01/02/2007 11:59:38 AM:

> Whenever I have a document with a flowRegion batik is failing. Is 
> there a work around?
> 
> <flowRoot

   flowRoot was from SVG 1.2 (be warned it is no longer part of 
SVG 1.2).  So you need to mark your SVG Document as being version 
1.2 (the version attribute must be on root svg element):

        <svg version="1.2"

>          y="347.66333" /></flowRegion><flowPara
>        id="flowPara1353">Your FAF numbers are 
> 081123456,082479628,083635846,084695691,085965555,
> 086789654</flowPara></flowRoot> 

   We also require that the 'flowPara' element be wrapped
in  a 'flowDiv' element.