Re: (dsssl) Heresy

Subject: Re: (dsssl) Heresy
From: Paul Tyson <paul@xxxxxxxxxxxxxxxxxxxxxx>
Date: Sat, 05 Apr 2003 07:46:56 -0600
4/5/03 2:32:20 AM, "John W. Shipman" <john@xxxxxxx> wrote:

[snip]

>Although XSLT can select things, and sort the selected sets, it
>wasn't obvious to me how to cause an element to appear in
>multiple places.

You probably could have done this application in XSLT without 
additional scripting.  You can use <xsl:apply-templates> and 
<xsl:call-templates> as often as you want to process the same nodeset.  
Ask on an XSL list for more details.

>Obligatory DSSSL content:  Could I have done this application
>in DSSSL, assuming I had a few months to spend crawling on my
>hands and knees through the DSSSL specification and another
>few months learning to use it?  I'm assuming that no one has
>yet written a Nutshell Guide to DSSSL or the equivalent, so
>the only way to learn DSSSL is from the spec.

Yes, but DSSSL doesn't make the easy things easier (in fact, it 
probably makes them harder).  DSSSL makes the hard things possible.  
If you only have easy problems, stick with XSLT.

In fact, if you wrote this application using OpenJade, you wouldn't 
really be using the true DSSSL transformation spec.  You would be 
using a neat (but nonstandard) shortcut that James Clark built into 
jade that allows SGML output from a style transformation.  (All that 
means is that the stylesheets you wrote wouldn't be useable by another 
DSSSL processor, just like if you use XSLT extensions you limit the 
portability of the stylesheets.)

But the real DSSSL transformation is model looks like this:
	SGML -> grove -> grove -> SGML (or some other rendition).

The formatting model looks like this:
	SGML -> grove -> flow object tree -> formatted rendition

In each case, the first and last conversions are not covered by the 
DSSSL standard.  By using customized flow objects that look and act 
like SGML constructs, jade (and OpenJade) allow a conversion that 
looks like:
	SGML -> grove -> SGML.

(OpenJade handles the grove-construction and output formatting 
processes automatically.)

This is just to illustrate how DSSSL makes easy things harder, but 
provides the architecture for doing complex transformations of complex 
data structures.

Paul Tyson, Principal Consultant          Precision Documents
paul@xxxxxxxxxxxxxxxxxxxxxx     http://precisiondocuments.com
      "The art and science of document engineering."




 DSSSList info and archive:  http://www.mulberrytech.com/dsssl/dssslist

Current Thread