Overview
XSLTXT provides a java implementation of an compact way to write XSLT stylesheets. It is hosted by savannah at XSLTXT. Take a look at the XSLT fragement below:
<xsl:choose>
<xsl:when test="$count > 1">
<xsl:call-template name="by-columns">
<xsl:with-param name="column-count" select="$count"/>
</xsl:call-template>
</xsl:when>
<xsl:otherwise>
<para>
<text>No columns</text>
</para>
<xsl:otherwise>
</xsl:choose>
In XSLTXT it can be written as
choose
when .test "$count > 1"
call "by-columns" ("column-count":"$count")
otherwise
<para>
"No columns"
XSLTXT increases the signal to noise ratio in XSLT stylesheets so that they are easier to write and hopefully easier to read. This project provides
- Code to convert from standard XSLT encoded in XML to XSLTXT format.
- Code to convert from XSLTXT to standard XSLT in XML.
- An implementation of the SAX 2.0 XMLReader interface that lets you use XSLTXT format stylesheets directly. No need to convert to xml before processing.
Currently the code is all working and is able to process the docbook xsl stylesheets correctly. Work is now concentrating on better documentation and providing a style workshop application to help develop and edit stylesheets.
For more information look at the current documentation and a list of all of the statements supported. Both of these documents where produced from xml marked up using docbook and processed by XSLTXT versions of the docbook XSLT stylesheets.