PageSeeder supports the rendering of TeX expressions in documents, fragments and inline labels.
Use the file extension .tex
for TeX documents.
PageSeeder automatically renders xrefs of type math
pointing to TeX documents or fragments.
To let users select TeX documents to include in their content, you need to create a math xref config.
<!-- To insert an expression stored in TeX document -->
<xref-config name="tex" title="TeX">
<xref display="document"
frag="default"
type="math" />
<target filters="+psmediatype:application/x-tex" />
</xref-config>
For further information, see PSML xref config in the developer documentation.
Use the media type application/x-tex
for tex media fragments.
Example
<media-fragment mediatype="application/x-tex">
\left[
\begin{matrix}
1 & 0\\
0 & 1
\end{matrix}
\right]
</media-fragment>
Renders as:
\left[ \begin{matrix} 1 & 0\\ 0 & 1 \end{matrix} \right]
Use the tex
inline label to render a portion of content within a paragraph or list.
Example
<para>This formula <inline label="tex">f(x) = x^2</inline> is an example.</para>
Renders as:
This formula f(x) = x^2 is an example.
Similar to AsciiMath, PageSeeder supports TeX in both Word and PDF by first converting it to MathML at the beginning of the publish process.
Microsoft Word supports OMML (Office Math Markup Language), so MathML is converted to OMML when exporting to a Word document. When publishing to PDF, PageSeeder uses JEuclid to render MathML.
To be consistent with the user interface, publish supports the KaTeX functions except:
align
, alignat
, gather
). Instead use aligned
, alignedat
and gathered
.aligned
, alignedat
or gathered
math structure. However, Word will always center equations rather than aligning them.
The PageSeeder user manual
© Allette Systems (Australia)