OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: RE: [docbook-apps] SVG how to

> -----Original Message-----
> From: Roger Blum

> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook SVG Module 
> V1.1CR1//EN"
> 	"http://www.oasis-open.org/docbook/xml/svg/1.1CR1/dbsvg.dtd";>
> <article>
>   <section>
>     <title>Certification Charts</title>
>     <para>Sample doc.</para>
>     <mediaobject id="svgTest">
>       <imageobject>
>         <imagedata format="SVG" fileref="test.svg" width="10cm"
>                    height="10cm"/>
>       </imageobject>
>     </mediaobject>
>     <para>Some other text</para>
>   </section>
> </article>

There is no "height" attribute on imagedata; rename it to "depth".

> % jw -b html -d my_config.dsl -u test.xml
> is used to transform the test file.
> The generated HTML code for the SVG graphic is
> <div class="mediaobject"><p></p></div>
> Concerning this I have a couple of questions:
> Can the docbook utils be used for transforming files that contain svg
> (without svg it works fine)?

The DocBook DSSSL stylesheets (whioh are used by docbook-utils) do not
recognize SVG as a valid image format, as far as I can tell. I guess that it
would be fairly easy to fix this, but nowadays the XSLT stylesheets are much
more popular. The DSSSL stylesheets have not been discontinued, but they are
not actively maintained. 

> Is the '<!DOCTYPE ...' correct and necessary or can I use the locally
> installed docbook DTDs?

It seems to be correct (you use the DTD for the DocBook SVG module;
http://www.docbook.org/specs/wd-docbook-svg-1.1CR1.html). And yes, you can
use a locally installed version of that DTD (or any DTD, of course). But if
you don't have any SVG markup in your files, you don't need the SVG module.

> Is there something obvious I'm doing wrong?

See above...

> How to integrate svg directly into the xml file without having an
> external svg file?

Since you use the DocBook SVG module, SVG markup is allowed in imageobject
(it is the whole point of using that module).

Note that DocBook 4.5 is the last version in the DocBook 4.X series. All
current development is aimed at "the next big thing", DocBook 5, and you
might want to read up on that; see http://www.docbook.org/docs/howto/. Among
other things, there are instructions on extending the DocBook 5 RELAX NG
schema with the SVG schema:


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]