Texcaller Python interface

Synopsis
import texcaller
texcaller.convert(source, source_format, result_format, max_runs)  # returns a pair (result, info)
texcaller.escape_latex(s)

Description
These Python functions are simple wrappers around the Texcaller C interface library functions, making TeX typesetting easily accessible from Python.

Example
# coding: UTF-8

import texcaller

latex = ur'''\documentclass{article}
\begin{document}
Hello world!
\end{document}'''

pdf, info = texcaller.convert(latex, 'LaTeX', 'PDF', 5)
print 'PDF size:     %.1f KB' % (len(pdf) / 1024.0)
print 'PDF content:  %s ... %s' % (pdf[:5], pdf[-6:])

s = u'Téxt → "with" $peciäl <characters>'

print 'Original:  %r' % s
print 'Escaped:   %r' % texcaller.escape_latex(s)

Generated on Thu Mar 31 22:46:11 2011 for Texcaller by  doxygen 1.5.6