Forum Samples, Tips and Tricks

XSLT for MathML

We are a little bit late as experimental MathML support is already included in recent alpha release of Prince. But in any case there is possibility to format MathML using XSLT + CSS and appropriate XSLT style sheet that produces XML + CSS output suitable for formatting in Prince 5 is available.

Originally it was designed as a part of UserJS for rendering MathML in Opera browser but since the same XML + CSS technique works in Prince 5.0/5.1 decision to post it here was made. As an example see PDF output produced by Prince from XML + CSS obtained using XSLT from XHTML + MathML input.

Note also that similar XSLT style sheet is available for LaTeX-like input.