Skip to content

An XSLT extension to invoke the liblouis Braille translation library from XSLT

License

Notifications You must be signed in to change notification settings

sbsdev/LiblouisSaxonExtension

 
 

Repository files navigation

Liblouis Saxon Extension

This project provides a saxon extension that allows to translate text nodes to braille using liblouis from within xsl.

It does this by providing a specialized javax.xml.transform.sax.SAXTransformerFactory that can be used to configure applications that respect the System property "javax.xml.transform.TransformerFactory".

It uses saxon with a java extension that offers translating text into braille using liblouis.

Usage org.liblouis.LouisExtensionTransformerFactoryImpl

java -Djavax.xml.transform.sax.SAXTransformerFactory YourAppThatUsesJaxp

Examples can be found in the xsl tests which are performed using utf-x (we're using the svn version, which has been ported to work with saxon9he). See utfx.sh shell script in the project dtbook2sbsform.

Usage org.liblouis.LouisTransform

java org.liblouis.LouisTransform -s:yourSource.xml -xsl:yourXSLT.xsl

An example can be found in the dtbook2sbsform.sh shell script.

Debugging your XSLT

To print debug info, use Saxon's TraceListener mechanism:

java org.liblouis.LouisTransform -s:yourSource.xml -xsl:yourXSLT.xsl \
                                 -T:org.liblouis.LiblouisTraceListener \
                                 2> file/to/redirect/stderr/to

Prerequisite installs

Authors

Christian Egli

Bernhard Wagner

Bert Frees

License

Copyright 2011 SBS.

Licensed under GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

About

An XSLT extension to invoke the liblouis Braille translation library from XSLT

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 88.5%
  • XSLT 11.5%