This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: Operation of indent="yes" in Saxon 6.5.2 vs MSXML


> 
> Am I correct in assuming you don't look at the whitespace 
> already present between tags before deciding what whitespace to add?
> 
Almost. Saxon outputs indentation (newline + spaces) before a start tag
if there have been no non-whitespace characters output since the last
start or end tag. It applies the same rule to end tags, except that end
tags are written on the same line as their start tag if there are no
newlines or child elements in the element content.

I agree this could be refined, but there is no obviously correct
algorithm. I would advise using xsl:strip-space when you use
indent="yes" for best results.

Michael Kay
Software AG
home: Michael.H.Kay@ntlworld.com
work: Michael.Kay@softwareag.com 


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]