I have an eps file: "model.eps" here:
http://petitlien.fr/my_test_file
The content preview is here:
http://apercu.petitlien.fr/my_test_file
I wish to make label replacements in the eps file using the psfrag commands as follows:
\psfrag{A}{$m$}
\psfrag{B}{$k$}
\psfrag{Y}{inner boundary}
This is relatively easy to do with the psfrag package loaded such as in:
\documentclass[]{article}
\usepackage[dvips]{graphicx,color}
\usepackage{psfrag}
\begin{document}
\thispagestyle{empty}
\begin{figure}
\psfrag{A}{$m$}
\psfrag{B}{$k$}
\psfrag{Y}{inner boundary}
\includegraphics{E:/test/model.eps}
\end{figure}
\end{document}
But the above code will create an A4 paper with the figure in the middle. I don't want this.
What I would like to have is:
An new EPS file with the labels replaced by the psfrag commands. This new EPS file must have the same bounding box as the file "model.eps". This means if in GSView, I activate options > EPS Clip, then I must just see a tight bounding box around the new EPS file as in "model.eps". So this will result in a standalone EPS file with the labels properly replaced.
A method to convert this EPS file say to a PDF file but with the resulting file having the same "bounding box" size as the EPS file.
Psfrag is a wonderful tool and it would be great to be able to produce a standalone EPS with a tight bounding box and with all appropriate labels included via Psfrag.
Thank you for any suggestions and answers
Update
I have been looking at psfragger
http://www.ctan.org/tex-archive/support/psfragger
but it doesn't work. It is not maintained anymore.
A solution
The standalone package seems to work fine. I can obtain a tight pdf file through latex > dvips > ps2pdf.
\documentclass{standalone}
\usepackage[dvips]{graphicx,color}
\usepackage{psfrag}
\begin{document}
\psfrag{A}{$m$}
\psfrag{B}{$k,c$}
\psfrag{Y}{inner stator bore}
\includegraphics{E:/test/jeffcott.eps}
\end{document}
However the ps generated in the process (with dvips) does not appear well. Any reason for that?