[Dev-luatex] Typo in functuonref.tex

Aditya Mahajan adityam at umich.edu
Sun Sep 12 17:24:27 CEST 2010


On Sun, 12 Sep 2010, Reinhard Kotucha wrote:

> On 12 September 2010 Khaled Hosny wrote:
>
> > It says \latexlua, though being half a sleep, I'm pretty sure there
> > is no latex in luatex, a Freudian slip? :P
>
> Sure, Taco is secretly working on latexlib.  This allows you to run
> LaTeX directly in Context:
>
> \startLaTeX
> \textbf{hello}
> \stopLaTeX

Oh, you underestimate the power of the dark side. Running latex inside 
context is already possible using the external filter module[1].

\usemodule[filter]

\defineexternalfilter
   [LATEX]
   [filtercommand={pandoc -f latex -t context
                   -o \externalfilteroutputfile\space
                   \externalfilterinputfile}]

\starttext

\startLATEX
   Simple \LaTeX\ (this gets gobbled!)
   commands like \textbf{bold} and \textit{italic} work, as
   does \emph{emphasize}. Even equations work!

   \begin{equation}
     E = mc^2
   \end{equation}
   though we end up loosing the numbering.

   Graphics also work: \includegraphics{dummy} but floats is a different
   story

   \begin{figure}
     \centering
     \includegraphics{dummy}
     \caption{A figure}
   \end{figure}
\stopLATEX

\stoptext

I could also give an actual call to latex and simply include the resultant 
pdf, but this is more fun.

Aditya

[1]: http://www.github.com/adityam/filter



More information about the dev-luatex mailing list