Overview & Features
SnuggleTeX is a free and open-source Java library for converting fragments
of LaTeX to XML (usually XHTML + MathML).
- SnuggleTeX converts math mode LaTeX to MathML, generating Presentation
MathML by default.
- As of SnuggleTeX 1.1.0, SnuggleTeX can also attempt to generate
Content MathML and Maxima notation if it can make sense of the input.
(This is aimed primarily at secondary/early tertiary UK Education contexts.)
- SnuggleTeX converts text mode LaTeX to XHTML.
- SnuggleTeX converts standard LaTeX inputs containing a mixture of text and math mode
LaTeX to XHTML with embedded MathML.
- SnuggleTeX can output either a DOM fragment, an XML fragment or create a full
standalone web page.
- SnuggleTeX has optional features for converting the resulting MathML to images
(using the JEuclid library) and attempting to convert simple MathML expressions
into a mixture of XHTML and CSS.
- Web page outputs can be configured in various ways and SnuggleTeX provides
a number of useful web page templates that can be used to target certain browsers
and rendering options.
- Outputs can be fully standalone (e.g. with all CSS styling done inline) to enable
XML fragments to be imported into other XML applications and/or systems
which support XHTML+MathML.
- Error reporting is configurable and error messages are internationalisable and
provide detailed contextual information.
- SnuggleTeX supports \newcommand and \newenvironment and
friends, making it easy to create custom commands and environments. There are
also lower-level Java hooks for defining new commands and environments.
- SnuggleTeX also includes some experimental utility code to convert the raw MathML
generated by ASCIIMathML
to Content MathML and Maxima notation.