[texhax] compile to a small PDF

ap tug at alxp.gr
Tue Sep 9 11:27:16 CEST 2008


Hi all,

Thank you very much for all of your answers. I took a look at the  
various proposals, and I retained the pdfcrop and the preview package  
ones.

Especially the preview package seems absolutely PERFECT for what I  
want. I will stick to that, but I just wonder: is there any reason to  
prefer one or the other solution? Wouldn't pdfcrop, as a perl script  
and as a PDF post-processor, be "less efficient"?

Additionally, there's the need to have perl installed (which isn't a  
problem for me as I'm on Mac OS X), but it could be a problem if I  
want to release my scripts.

Concerning LaTeXiT, yes, I already took a look at its sources, but I  
didn't really understand how it operates (there seems to be a three  
step way of guessing, from the most efficient to the most robust, and  
it seems like the robust method uses PS).

If you're curious about what I was doing, I was writing a script that  
converts a FIG file to a single PDF file (as opposed to the combined  
PDFTEX format, which comes with two files - having one single PDF file  
is more "portable" for sharing with others, for example). I really  
wanted pdflatex because my tex template file (the one to generate the  
preview from) must use the beamer class (which doesn't really behave  
well with latex), as my FIG file may contain overlay specifications.  
In which case I obtain a multi-image PDF that contains each step of  
the FIG file. Additionally, that creates a nice visualiser for a FIG  
file (which can be very complex to understand when you start having a  
lot of special latex text in it, and still more when that text has  
overlay specifications). I might consider in the future creating a  
Quicklook plugin from that (at the moment I'm too lazy to read the doc  
about that).

If anyone is interested, I can post it to the list at a later time,  
when it's well polished.

Regards,

ap

On 8 Sep 2008, at 23:29, Karl Berry wrote:

>    how can I generate a PDF
>    using pdflatex in a way that acts like (latex + dvips -E +  
> epstopdf) ?
>
> Here's what I do:
>
> pdflatex foo.tex
> pdfcrop foo.pdf  # outputs foo-crop.pdf
>
> pdfcrop is a Perl script by Heiko Oberdiek; it's included in TeX Live
> and is available on CTAN.
>
> Best,
> Karl



More information about the texhax mailing list