[Mac OS X TeX] TEX -> EPDF?

Claus Gerhardt gerhardt at math.uni-heidelberg.de
Thu Dec 6 01:28:35 CET 2001


>So, I'm curious whether anyone knows a good way to get a single TeX
>equation as a piece of embedded PDF?  I'm envisioning a package that works
>like this:
>
>\usepackage{pdfout}
>\include{allmywackytexmacros.tex}
>
>\begin{document}
>
>\begin{pdfout}{exp1.pdf}
>\[ 1+1 = 2 \]
>\end{pdfout}
>
>\begin{pdfout}{exp2.pdf}
>\[ A = \pi \cdot r^2\]
>\end{pdfout}
>
\end{document}

My solution to the problem is to use the package mfpic with the 
option metapost. Below is a complete latex source file for a formula.

\documentclass[a4paper]{article}
\usepackage[metapost]{mfpic}
\opengraphsfile{myname}

\begin{document}

\begin{mfpic}[20]{0}{4}{0}{4}
%the numbers are arbitrary but reasonable in the present context.


\tlabel(0,0){ $\int_a^b=f(x) dx$ }


\end{mfpic}

\closegraphsfile
\end{document}

After the first run of the document a file myname.mp is created which 
one has to transform via the terminal using the command

mpost myname

After the second run of the document the file myname.pdf contains the 
formula. One can then open this file with Adobe Illustrator and save 
it as an .eps file.


Claus
>


-- 


Claus Gerhardt
Institut für Angewandte Mathematik
Ruprecht-Karls-Universität Heidelberg
Im Neuenheimer Feld 294
69120 Heidelberg
Germany

Homepage: http://www.math.uni-heidelberg.de/studinfo/gerhardt/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/macostex-archives/attachments/20011206/8791856d/attachment.html>


More information about the macostex-archives mailing list