forrest-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kevin <forr...@kegcl.demon.co.uk>
Subject Re: docbook documentation splittet in several chunk
Date Tue, 15 Nov 2005 18:44:01 GMT
On Mon, 2005-11-14 at 02:12 +0100, Fabian Müller wrote:
> I downloaded
> org.apache.forrest.plugin.input.simplifiedDocbook-0.1.zip,
> extracted the file and typed "forrest" in the root directory of the
> extracted directory tree. The build was successful. Then I replaced
> the content of the sample file "sdocbook.xml" with my tutorial.xml
> which is attached to this posting. This time the "validate-xdocs" part
> showed a lot of error messages. Here are only a few of them:
> /home/fabian/src/sd/src/documentation/content/xdocs/samples/sdocbook.xml:5:17: Document
root element "book", must match DOCTYPE root "article".
> /home/fabian/src/sd/src/documentation/content/xdocs/samples/sdocbook.xml:5:17: Element
type "book" must be declared.
> /home/fabian/src/sd/src/documentation/content/xdocs/samples/sdocbook.xml:7:11: Element
type "bookinfo" must be declared.
> /home/fabian/src/sd/src/documentation/content/xdocs/samples/sdocbook.xml:24:10: Element
type "chapter" must be declared.
> /home/fabian/src/sd/src/documentation/content/xdocs/samples/sdocbook.xml:26:10: Element
type "sect1" must be declared.
> /home/fabian/src/sd/src/documentation/content/xdocs/samples/sdocbook.xml:28:12: Element
type "sect2" must be declared.
> 
> So I guess that simplified docbook is not the correct way to go
> here. I appears that it is not possible to use these <sect1> and
> <sect2> tags for example. But these are used in each of my xml docbook
> files.

The simplified docbook input plugin can deal with full docbook (up to
a point) and simplified docbook. The following doctypes are tested for:

        <sourcetype name="docbook-v4.2">
          <document-declaration public-id="-//OASIS//DTD DocBook XML
V4.2//EN" />
        </sourcetype>
        <sourcetype name="docbook-v4.1.2">
          <document-declaration public-id="-//OASIS//DTD DocBook XML
V4.1.2//EN" />
        </sourcetype>
        <sourcetype name="sdocbook-v1.0">
          <document-declaration public-id="-//OASIS//DTD Simplified
DocBook XML V1.0//EN" />
        </sourcetype>

Your tutorial.xml required:
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
"http://www.docbook.org/xml/4.2/docbookx.dtd">
        
specifing book as the root node not article. This now validates agains
the forrest catalogs without the above errors. 

> What I liked before whas the fact that I was able to use the same xml
> file for the xsltproc command and for forrest. It appears that this is
> not possible with simplified docbook. That is not the best thing
> because it is very nice to have an xml file that can be integrated in
> Forrest without the need to change it. That's why I used to docbook
> stylesheets directly.

Forrest can skin single docbook or sdocbook pages referenced from site.xml.
IMO chunked files from the docbook chunker can not be skinned easily. There
is no need to use docbook stylesheets directly to integrate your full docbook
files.

1) I'd suggest not thinking about chunking now and remove any work you have
tried from your sitemap.xmap files. Or better still do a fresh:
forrest seed

2) Add a link to tutorial.html in site.xml
    <doc-tutorial label="OpenPBX Tutorial (docbook)" href="tutorial.html"
                  description="OpenPBX Tutorial by Fabian"/>

3) Add to your forrest.properties file
project.required.plugins=org.apache.forrest.plugin.input.simplifiedDocbook,
 org.apache.forrest.plugin.output.pdf

4) forrest clean; forrest site
You may need an internet connection the first time you do this to get the
plugin. 

I've put a demo up showing two of my test sdocbook pages and two docbook
pages your openPBX tutorial and a Linux howto. It all works nicely to
have these skinned in Forrest. See the docbook tab.
http://www.kegcl.demon.co.uk/forrest/test/

Please stick with it Fabian. Next stage, skinned docbook chunks ;)

Kevin

> I hope you understand what I wrote ...
> 
> Fabian Müller
> 
> 


Mime
View raw message