docbook: Thread: xml / xsl to pdf or ps or tex


[<<] [<] Page 1 of 2 [>] [>>]
Subject: xml / xsl to pdf or ps or tex
From: Alasdair Hatfield ####@####.####
Date: 23 Jul 2003 09:23:05 -0000
Message-Id: <200307230820.h6N8KMf32199@foureyes.embedded-designs.co.uk>

Hi

Does anyone have experience of getting good quality results going from xml to 
printable formats? I've picked up that .fo is a possible route but results 
are mixed from
pdf (using pdftex with passivetex) which is quite good
to others producing ps which is unreadable
to no method atall to get to tex.

If anyone has experience of any of these, and or other formats, I'd be 
interested to learn how they have done it.

This seems an area where the sgml tools are far stronger than the xml tools 
that I can find.

Thanks
Alasdair


PS Emma Jan - It would be good to see a draft of your new Author's Guide when 
it is in a reasonable form.
Subject: Re: xml / xsl to pdf or ps or tex
From: "Michael Wiedmann" ####@####.####
Date: 23 Jul 2003 09:43:58 -0000
Message-Id: <3F1E58B1.5010301@detewe.de>

Alasdair Hatfield wrote:

> Does anyone have experience of getting good quality results going from xml to 
> printable formats? I've picked up that .fo is a possible route but results 
...
> If anyone has experience of any of these, and or other formats, I'd be 
> interested to learn how they have done it.

I get _very_ good results (PDF) using the XSL stylesheets from the 
DocBook2LaTeX project (http://db2latex.sf.net). We are currently working on 
a large book (about 900+ pages) written in DocBook XML and generate PDF 
using db2latex.
Of course not all DocBook tags are supported yet, but the developers are 
usually very fast in implementing a wanted feature if they get emailed. If 
one has good knowledge of LaTeX one can easily adapt/enhance/extend the 
stylesheets in a custom layer for missing tags, etc.

Use the CVS version and not the 'official' end-user release!

Michael
-- 




     

Subject: Re: xml / xsl to pdf or ps or tex
From: Alasdair Hatfield ####@####.####
Date: 23 Jul 2003 10:48:35 -0000
Message-Id: <200307230945.h6N9jof32409@foureyes.embedded-designs.co.uk>

This works well.

Thanks for the help.

Just one thing - I am using <programlisting> which db2latex translates to 
<Verbatim>. dvips, which I use to get to .ps and then (via pstopdf) to .pdf, 
gets upset by this. Any experience of this and other approaches?

Thanks

Alasdair



On Wednesday 23 July 2003 11:43, you wrote:
> Alasdair Hatfield wrote:
> > Does anyone have experience of getting good quality results going from
> > xml to printable formats? I've picked up that .fo is a possible route but
> > results
>
> ...
>
> > If anyone has experience of any of these, and or other formats, I'd be
> > interested to learn how they have done it.
>
> I get _very_ good results (PDF) using the XSL stylesheets from the
> DocBook2LaTeX project (http://db2latex.sf.net). We are currently working on
> a large book (about 900+ pages) written in DocBook XML and generate PDF
> using db2latex.
> Of course not all DocBook tags are supported yet, but the developers are
> usually very fast in implementing a wanted feature if they get emailed. If
> one has good knowledge of LaTeX one can easily adapt/enhance/extend the
> stylesheets in a custom layer for missing tags, etc.
>
> Use the CVS version and not the 'official' end-user release!
>
> Michael
Subject: Re: xml / xsl to pdf or ps or tex
From: "Michael Wiedmann" ####@####.####
Date: 23 Jul 2003 12:05:39 -0000
Message-Id: <3F1E7A81.3010001@detewe.de>

Alasdair Hatfield wrote:

> Just one thing - I am using <programlisting> which db2latex translates to 
> <Verbatim>. dvips, which I use to get to .ps and then (via pstopdf) to .pdf, 
> gets upset by this. Any experience of this and other approaches?

I generate PDF directly using 'pdflatex' and didn't have any problems with 
<programlistings>. Can you explain in more detail your problems with 'Verbatim'?

Michael
-- 




     

Subject: Re: xml / xsl to pdf or ps or tex
From: Alasdair Hatfield ####@####.####
Date: 23 Jul 2003 12:58:53 -0000
Message-Id: <200307231156.h6NBu9f32710@foureyes.embedded-designs.co.uk>

Hi

The problem occurs with 'example' as well as with 'Verbatim', possibly for 
the same reason in the xsl file.


This is the xml source code:

        <example id="dir-hierarchy"><title>Directory Hierarchy</title>
                <programlisting>
        $(LT_HOME)
            - models
                - model name
                    - model
                    - ...
                - ...
                </programlisting>
        </example>


This is the code created:

\begin{example}%
\hypertarget{dir-hierarchy}{}%
\captionswapskip{}{{\caption{Directory Hierarchy}\label{dir-hierarchy}}}
\captionswapskip{}
\begin{Verbatim}[]

        $(LT_HOME)
            - models
                - model name
                    - model
                    - ...
                - ...

\end{Verbatim}
\end{example}


Here is the error:

! LaTeX Error: Environment example undefined.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...

l.255 \begin{example}
                     %
? x


If I use code without <example> then I suffer the same problem but with 
{Verbatim} in the error instead.

Best regards
Alasdair



On Wednesday 23 July 2003 14:07, you wrote:
> Alasdair Hatfield wrote:
> > Just one thing - I am using <programlisting> which db2latex translates to
> > <Verbatim>. dvips, which I use to get to .ps and then (via pstopdf) to
> > .pdf, gets upset by this. Any experience of this and other approaches?
>
> I generate PDF directly using 'pdflatex' and didn't have any problems with
> <programlistings>. Can you explain in more detail your problems with
> 'Verbatim'?
>
> Michael
Subject: Re: xml / xsl to pdf or ps or tex
From: "Michael Wiedmann" ####@####.####
Date: 23 Jul 2003 13:15:49 -0000
Message-Id: <3F1E8AEE.2000100@detewe.de>

Alasdair Hatfield wrote:
...
> ! LaTeX Error: Environment example undefined.

Look at the generated TeX-file and see whether you find a line like:

\usepackage{fancyvrb}

If not, make sure you have:

<xsl:param name="latex.use.fancyvrb">1</xsl:param>

in your custom XSL file (this is default anyway, but maybe you switched it 
off) and regenerate the TeX-file.

Michael
PS: tomorrow I will be away from my email and can't answer further questions
     before friday.
-- 




     

Subject: Re: xml / xsl to pdf or ps or tex
From: "David Horton" ####@####.####
Date: 23 Jul 2003 13:58:14 -0000
Message-Id: <200307231358.h6NDwDBZ069589@mail5.mx.voyager.net>

> Hi
> 
> Does anyone have experience of getting good quality results going from
xml to 
> printable formats? I've picked up that .fo is a possible route but
results 
> are mixed from
> pdf (using pdftex with passivetex) which is quite good
> to others producing ps which is unreadable
> to no method atall to get to tex.
> 
> If anyone has experience of any of these, and or other formats, I'd be 
> interested to learn how they have done it.
> 
> This seems an area where the sgml tools are far stronger than the xml
tools 
> that I can find.
> 

You can get printable formats using Apache's FOP with the tldp-print.xsl
stylesheet.  So far I've gotten PDF output to work on a windoze platform
and I'm assuming FOP on Linux would give similar results.

The list of supported output formats is on Apache's site at:
http://xml.apache.org/fop/output.html

Dave


Subject: Re: xml / xsl to pdf or ps or tex
From: "Dennis Grace" ####@####.####
Date: 23 Jul 2003 15:07:59 -0000
Message-Id: <OFB1662CA0.3A64493D-ON85256D6C.00524CFF@pok.ibm.com>

I have had much success recently with FOP 0.20.5 and Java SDK 1.4.2 running
on RedHat 9.0. I had been attempting to make PassiveTeX work, but it's been
a losing proposition. Every time Sebastian and the TeX initiative members
fix one PassiveTeX glitch, they create three or four more. Currently, among
other problems, tables are not rendered at all well by PassiveTex.

The latest SDK download is huge, but it installs with InstallShield (which
I didn't realize was available for Linux).

If you use FOP, be sure your customization layer includes

  <xsl:param name="fop.extensions" select="0"/>

For guidance on getting FOP up and running, see Bob Stayton's DocBook XSL
reference: http://www.sagehill.net/docbookxsl/

Dennis Grace

Information Developer
IBM Linux Technology Center
(512) 838-3937  T/L 678-3937  cell: (512)-296-7830
####@####.####

"In a democracy, dissent is an act of faith."
           J William Fulbright



                                                                                                                                       
                      "David Horton"                                                                                                   
                      <dhorton@megsinet        To:       ####@####.####                                                           
                      .net>                    cc:       Alasdair Hatfield ####@####.####                     
                                               Subject:  Re: xml / xsl to pdf or ps or tex                                             
                      07/23/2003 08:58                                                                                                 
                      AM                                                                                                               
                                                                                                                                       
                                                                                                                                       




> Hi
>
> Does anyone have experience of getting good quality results going from
xml to
> printable formats? I've picked up that .fo is a possible route but
results
> are mixed from
> pdf (using pdftex with passivetex) which is quite good
> to others producing ps which is unreadable
> to no method atall to get to tex.
>
> If anyone has experience of any of these, and or other formats, I'd be
> interested to learn how they have done it.
>
> This seems an area where the sgml tools are far stronger than the xml
tools
> that I can find.
>

You can get printable formats using Apache's FOP with the tldp-print.xsl
stylesheet.  So far I've gotten PDF output to work on a windoze platform
and I'm assuming FOP on Linux would give similar results.

The list of supported output formats is on Apache's site at:
http://xml.apache.org/fop/output.html

Dave



______________________
http://lists.tldp.org/






Subject: Re: xml / xsl to pdf or ps or tex
From: Morgon Kanter ####@####.####
Date: 23 Jul 2003 15:18:14 -0000
Message-Id: <20030723111728.5df288a3.morgon@surgo.net>

This one time, at band camp, Alasdair Hatfield ####@####.#### wrote:
> Hi
> 
> Does anyone have experience of getting good quality results going from xml to 
> printable formats? I've picked up that .fo is a possible route but results 
> are mixed from

.fo + FOP from Apache. However, it's unfortunate that Apache uses 
Java for fscking everything and some of this stuff is either 
incredibly difficult or downright impossible to build with gcj. 

I've heard something about some guy over at Red Hat that both got Ant 
to build using gcj and has RPMs for it. Anyone have more information 
on that? Ant in Debian is currently in the contrib section for various 
reasons, and I'd love for it to be able to move to main.

Morgon
-- 
"Man is the only creature capable of hating itself" -- Governor of Japan 
in The End of Evangelion
Subject: Re: xml / xsl to pdf or ps or tex
From: "David Horton" ####@####.####
Date: 23 Jul 2003 15:42:36 -0000
Message-Id: <200307231542.h6NFgZRZ061924@mail5.mx.voyager.net>

> 
> If you use FOP, be sure your customization layer includes
> 
>   <xsl:param name="fop.extensions" select="0"/>
> 
> For guidance on getting FOP up and running, see Bob Stayton's DocBook XSL
> reference: http://www.sagehill.net/docbookxsl/
> 
> Dennis Grace

All I could find about "fop.extensions" in the DocBook XSL reference is
that it has something to do with PDF bookmarks.  Why is it necessary to
turn this off?  Is it broken?  Just curious.

Dave


[<<] [<] Page 1 of 2 [>] [>>]


  ©The Linux Documentation Project, 2014. Listserver maintained by dr Serge Victor on ibiblio.org servers. See current spam statz.