[texhax] Converting LaTeX files into MS Word

Joel Salomon joelcsalomon at gmail.com
Wed Nov 22 20:46:27 CET 2006

> > I have a little script I wrote for use with pstricks that takes a minimal
> > TeX file --- I had one pstricks image, but you can put a single equation in
> > instead --- and produces an embeddable pdf.
> I've been lurking on this thread...Such a script would be extremely handy,
> if you were willing to share!

Here is figtex.cmd:
	latex %1.tex
	dvips -E %1.dvi -o %1.ps
	epstool --copy --bbox %1.ps %1.eps
	epstopdf %1.eps
It should be easily modifiable to other systems.  You'll need
ghostscript and epstool (I recommend ghostview as well); dvips and
epstopdf come with MiKTeX.  I have a fuller version at home with some
error checking, but this should do for the nonce.
The LaTeX source file should use \pagestyle{empty} and have a single
object (figure, equation, table, &c.) in the document.  For example:
You might use \documentclass{article} rathe than {minimal} if there's
an issue with loading packages.

Hope this helps,
-------------- next part --------------
latex %1.tex
dvips -E %1.dvi -o %1.ps
epstool --copy --bbox %1.ps %1.eps
epstopdf %1.eps

More information about the texhax mailing list