But I think your problem is finding an algorithm, not in writing an
XSLT implementation of the algorithm.
I'm not sure if I understand you correctly. Do you mean to
find a generic algorithm for how to implement spans and copy
it in XSLT? Or do you mean having the work done as an
extension function outside XSLT? What would be the input and
output of this function?
I meant that once you have described an algorithm for calculating the
results you want, implementing the algorithm in XSLT shouldn't be
difficult. Which is another way of saying that it's not really an XSLT
problem. Which is unhelpful, for which I apologize.
Michael Kay
Software AG
home: Michael(_dot_)H(_dot_)Kay(_at_)ntlworld(_dot_)com
work: Michael(_dot_)Kay(_at_)softwareag(_dot_)com
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list