On Sun, Dec 15, 2002 at 06:43:01PM -0500, Rodent of Unusual Size wrote:
> Steven Noels wrote:
> >
> > Seriously: while I see some value in this verbatim inclusion of
> > external, non-XML fragments, I don't see much value in conditional
> > behaviour. It's the kind of stuff which gets thrown back in your face, IMHO.
>
> i find this position contradictory given the recent discussion
> about presentation versus semantics. some people are going
> to want .. no, *need* to take control over some presentation-level
> aspects. you've already gone on record as saying you don't think
> that should go into the general markup; how can i interpret
> your quoted remark above as anything other than an opinion that
> content-developers/forrest-users should have no control over presentation
> whatsoever? maybe i'm seeing things in too few shades of grey.
>
> for example: one external fragment may be appropriate if the target
> format is equation-capable, like *roff; another is better for
> html; still a third is better for audio presentation for the
> blind. please don't assume that a) the transformation stylesheets
> are going to make the best choices in these cases, nor that b) the
> contenr-developers have the least idea or desire to frob the
> stylesheets.
>
> give 'em rope.
I think we should:
- first work out how to solve the problem
- THEN worry about whether the solution ends up in Forrest's core.
We could establish a contrib/ directory for non-mainstream setups. I
have a few to contribute.
Soo..
There were two separate proposals on this thread:
a) A mechanism for including raw content in the output:
<pre>
<include-verbatim src="sample.raw"/>
</pre>
If sample.raw is XML, I'd use the XIncludeTransformer. If it isn't, I'd
use an entity:
<!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.1//EN"
"document-v11.dtd" [
<!ENTITY raw-content SYSTEM "sample.raw">
]>
<document>
...
<p xml:space="preserve">
&raw-content;
</p>
...
</document>
Non-XML characters in sample.raw can be escaped with <![CDATA[&raw-content;]]>
Would that solve the problem?
b) Conditional inclusion of a section depending on output type:
<if target="html"> .. </if>
Seems fairly straightforward to add to the DTD, and exclude from the
copy-everything template in the stylesheet. I can make an example if you like.
To become part of Forrest would require some solid use-cases though.
--Jeff
|