You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Joel Gwynn <jo...@digipress.net> on 2002/11/05 18:13:36 UTC
Quark workflow
Hello all. I do variable data for a printing company. I'm trying to
design a workflow as follows:
Quark template -> Quark XML -> [???] -> FOP -> PDF
How do I get from Quark XML to XSL-FO. Also, I need a connection to
SQL-Server somewhere in there too, of course.
Thanks for helping a newbie.
Joel Gwynn
Variable Data
Spire
617 832-1957
Re: Quark workflow
Posted by clholm <vp...@earthlink.net>.
You may want to consider Apache Cocoon. Look here:
http://xml.apache.org/cocoon/index.html
and (more specifically) here:
http://xml.apache.org/cocoon/userdocs/serializers/pdf-serializer.html
- Carl Holm
Joel Gwynn wrote:
> Hello all. I do variable data for a printing company. I'm trying to
> design a workflow as follows:
>
> Quark template -> Quark XML -> [???] -> FOP -> PDF
>
> How do I get from Quark XML to XSL-FO. Also, I need a connection to
> SQL-Server somewhere in there too, of course.
>
> Thanks for helping a newbie.
>
> Joel Gwynn
> Variable Data
> Spire
> 617 832-1957
RE: Quark workflow
Posted by Joel Gwynn <jo...@digipress.net>.
That looks like a much more promising "avenue". Thanks a lot!
Joel Gwynn
Variable Data
Spire
617 832-1957
> -----Original Message-----
> From: Oleg Tkachenko [mailto:olegt@multiconn.com]
> Sent: Wednesday, November 06, 2002 1:40 PM
> To: fop-user@xml.apache.org
> Subject: Re: Quark workflow
>
>
> Joel Gwynn wrote:
>
> > Well, since you asked ... I uploaded the files to my server for
> > perusal, just in case you're interested. These are the
> files from the
> > quark.avenue tutorial. http://joelman.com/avenue-xml/
>
> Well that's not a bad format, xml + css, but unfortunaly css
> in not xml hence
> one can say it's browser oriented format. If you want to
> process it by xslt
> the main burden is css parsing. I developed such stuff
> recently, but that was
> for a commercial project and I cannot share the code. The
> main idea is to
> write URIResolver, which reads css file, parses it somehow,
> e.g. using w3c's
> SAC (Simple API for CSS) and represents css in xml format,
> e.g. each selector
> is element and each propery is its attribute. Then you can use such
> URIResolver from within xsl stylesheet and generate xsl-fo
> attributes from css
> properties (they happily almost coincide).
> I mean
> xml
> <head_L1>avenue.quark White Paper</head_L1>
>
> css
> head_L1 {
> font-size : 18pt;
> font-family : Arial;
> font-weight : Bold;
> color : Blue;
> background-color : Aqua;
> display : block;
> line-height : 40pt;
> }
>
> xsl:
> <xsl:template match="head_L1">
> <fo:block>
> <xsl:copy-of
> select="document('css:my-css-name')/head_L1/@*"/>
> <xsl:apply-templates/>
> </fo:block>
> </xsl:template>
>
> result:
>
> <fo:block font-size="18pt"
> font-family="Arial"
> font-weight="Bold"
> color="Blue"
> background-color="Aqua"
> display="block"
> line-height="40pt">
> ...content...
> </fo:block>
>
> It's feasible but requires a lot of careful work. I'd suggest
> you to look
> around for another quark export tool, which doesn't use css
> but pure xml, that
> would be big relief, e.g. google pointed out to http://www.attd.com.
>
> --
> Oleg Tkachenko
> eXperanto team
> Multiconn Technologies, Israel
>
>
Re: Quark workflow
Posted by Oleg Tkachenko <ol...@multiconn.com>.
Joel Gwynn wrote:
> Well, since you asked ... I uploaded the files to my server for perusal,
> just in case you're interested. These are the files from the
> quark.avenue tutorial. http://joelman.com/avenue-xml/
Well that's not a bad format, xml + css, but unfortunaly css in not xml hence
one can say it's browser oriented format. If you want to process it by xslt
the main burden is css parsing. I developed such stuff recently, but that was
for a commercial project and I cannot share the code. The main idea is to
write URIResolver, which reads css file, parses it somehow, e.g. using w3c's
SAC (Simple API for CSS) and represents css in xml format, e.g. each selector
is element and each propery is its attribute. Then you can use such
URIResolver from within xsl stylesheet and generate xsl-fo attributes from css
properties (they happily almost coincide).
I mean
xml
<head_L1>avenue.quark White Paper</head_L1>
css
head_L1 {
font-size : 18pt;
font-family : Arial;
font-weight : Bold;
color : Blue;
background-color : Aqua;
display : block;
line-height : 40pt;
}
xsl:
<xsl:template match="head_L1">
<fo:block>
<xsl:copy-of select="document('css:my-css-name')/head_L1/@*"/>
<xsl:apply-templates/>
</fo:block>
</xsl:template>
result:
<fo:block font-size="18pt"
font-family="Arial"
font-weight="Bold"
color="Blue"
background-color="Aqua"
display="block"
line-height="40pt">
...content...
</fo:block>
It's feasible but requires a lot of careful work. I'd suggest you to look
around for another quark export tool, which doesn't use css but pure xml, that
would be big relief, e.g. google pointed out to http://www.attd.com.
--
Oleg Tkachenko
eXperanto team
Multiconn Technologies, Israel
RE: Quark workflow
Posted by Joel Gwynn <jo...@digipress.net>.
> -----Original Message-----
> From: Oleg Tkachenko [mailto:olegt@multiconn.com]
> Sent: Wednesday, November 06, 2002 12:45 PM
> To: fop-user@xml.apache.org
> Subject: Re: Quark workflow
>
>
> Joel Gwynn wrote:
>
> > So, to continue down this winding road a little further ...
> >
> > Quark seems to produce three documents: a css, dtd, and xml.
>
> What are in them?
>
> > The goal
> > is to produce an xsl file that can transform the xml to xsl-fo.
> > Should I be writing a script that takes that dtd and css
> and produces
> > an xsl file?
>
> Don't forget xml :)
>
> > Would it be possible to write an xsl file that can read the dtd,
> > css, and xml and produce the xsl-fo file?
>
> No, xslt processor needs xml (dtd is for parser) as input,
> but there are a lot
> of tricks. Details greatly depend on what is in those files
> and how they are
> interconnected.
>
> --
> Oleg Tkachenko
> eXperanto team
> Multiconn Technologies, Israel
>
>
Well, since you asked ... I uploaded the files to my server for perusal,
just in case you're interested. These are the files from the
quark.avenue tutorial. http://joelman.com/avenue-xml/
I'll probably have to take them down eventually, but if you wanted to
take a look and offer suggestions, I'd be hugely appreciative.
Re: Quark workflow
Posted by Oleg Tkachenko <ol...@multiconn.com>.
Joel Gwynn wrote:
> So, to continue down this winding road a little further ...
>
> Quark seems to produce three documents: a css, dtd, and xml.
What are in them?
> The goal
> is to produce an xsl file that can transform the xml to xsl-fo. Should
> I be writing a script that takes that dtd and css and produces an xsl
> file?
Don't forget xml :)
> Would it be possible to write an xsl file that can read the dtd,
> css, and xml and produce the xsl-fo file?
No, xslt processor needs xml (dtd is for parser) as input, but there are a lot
of tricks. Details greatly depend on what is in those files and how they are
interconnected.
--
Oleg Tkachenko
eXperanto team
Multiconn Technologies, Israel
RE: Quark workflow
Posted by Joel Gwynn <jo...@digipress.net>.
So, to continue down this winding road a little further ...
Quark seems to produce three documents: a css, dtd, and xml. The goal
is to produce an xsl file that can transform the xml to xsl-fo. Should
I be writing a script that takes that dtd and css and produces an xsl
file? Would it be possible to write an xsl file that can read the dtd,
css, and xml and produce the xsl-fo file?
Sorry if it sounds like I'm flailing. I am.
Joel Gwynn
Variable Data
Spire
617 832-1957
> -----Original Message-----
> From: Oleg Tkachenko [mailto:olegt@multiconn.com]
> Sent: Tuesday, November 05, 2002 3:28 PM
> To: fop-user@xml.apache.org
> Subject: Re: Quark workflow
>
>
> Joel Gwynn wrote:
>
> > Quark template -> Quark XML -> [???] -> FOP -> PDF
> >
> > How do I get from Quark XML to XSL-FO.
> Well, there is no magic here, Quark XML can be transformed
> into xsl-fo
> as any other xml using XSL Transormations language. Learn Quark XML
> syntax and semantics, develop such a stylesheet and many people will
> thank you.
>
> --
> Oleg Tkachenko
> eXperanto team
> Multiconn Technologies, Israel
>
>
RE: Quark workflow
Posted by Stephan Wiesner <st...@stephan-wiesner.de>.
A better way would probably be to transform QuarkXML to DocBook. There
is a wide support for DocBook to PDF conversion and we all read
somewhere how easy it is to transform one XML format into another :-)
Framemaker actually can work with DocBook, though I have not tried it
out.
Stephan
> -----Original Message-----
> From: Oleg Tkachenko [mailto:olegt@multiconn.com]
> Sent: Dienstag, 5. November 2002 21:28
> To: fop-user@xml.apache.org
> Subject: Re: Quark workflow
>
>
> Joel Gwynn wrote:
>
> > Quark template -> Quark XML -> [???] -> FOP -> PDF
> >
> > How do I get from Quark XML to XSL-FO.
> Well, there is no magic here, Quark XML can be transformed
> into xsl-fo
> as any other xml using XSL Transormations language. Learn Quark XML
> syntax and semantics, develop such a stylesheet and many people will
> thank you.
>
> --
> Oleg Tkachenko
> eXperanto team
> Multiconn Technologies, Israel
>
>
Re: Quark workflow
Posted by Oleg Tkachenko <ol...@multiconn.com>.
Joel Gwynn wrote:
> Quark template -> Quark XML -> [???] -> FOP -> PDF
>
> How do I get from Quark XML to XSL-FO.
Well, there is no magic here, Quark XML can be transformed into xsl-fo
as any other xml using XSL Transormations language. Learn Quark XML
syntax and semantics, develop such a stylesheet and many people will
thank you.
--
Oleg Tkachenko
eXperanto team
Multiconn Technologies, Israel