Re: [xsl] xsl: preserving spaces preserves only one space?

Subject: Re: [xsl] xsl: preserving spaces preserves only one space?
From: josh higgins <doopsterus@xxxxxxxxx>
Date: Mon, 4 Apr 2005 08:46:01 -0700 (PDT)
Thanks buddy but I did just what you suggested and it
does not seem to work. Below is the code where I made
the modification.  Does this not seem correct?  Does
the order of attribute specification matter.  I would
assume not b/c the scope is propably the same.  Ideas.
 Oh if you know of any good resource to read to become
more firmilar with xsl then please let me know.


<xsl:template name="detail">
	<xsl:for-each select="/invoice/detail/row">
		<fo:block font-size="10pt"
white-space-treatment="preserve">
			<xsl:value-of select="transaction_detail"/>
		</fo:block>
	</xsl:for-each> 
</xsl:template>


--- David Carlisle <davidc@xxxxxxxxx> wrote:
> 
> 
>   <xsl:preserve-space
> elements="transaction_detail"/>
> 
> That presves white space nodes during the
> transformation stage although
> that will have no effect on your resulting FO file
> as you never have any
> select expressions that would be affected by the
> presence of white space
> text nodes.
> 
> So (presumably) the white space that you want to
> preserver _is_
> preserved by your XSLT transformation and appears in
> the resulting FO
> file.
> 
> FO in common with HTML, CSS, TeX and many other
> typesetting systems will
> by default render any run of white space just as a
> single word space.
> 
> If you don't want that you need to set the white
> space properties on the
> surrounding fo:block, there are several of them,
> giving control of line
> break and white space normalization but
> white-space-treatment="preserve"
> is probably a place to start.
>
http://www.w3.org/TR/xsl/slice7.html#white-space-treatment
> 
> David
> 
>
________________________________________________________________________
> This e-mail has been scanned for all viruses by
> Star. The
> service is powered by MessageLabs. For more
> information on a proactive
> anti-virus service working around the clock, around
> the globe, visit:
> http://www.star.net.uk
>
________________________________________________________________________
> 
> 

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

Current Thread