Assume that at creation time (of an EPS image) the final 'size' of the image is not known. However, this one EPS is used multiple times in different sizes within different documents.
But the font size of text (e.g., axes labels) should be consistent.
Example: In one .tex
use
\includegraphics[width=0.5\textwidth]{my_plotted_function.eps}
and in another use
\includegraphics[width=0.3\textwidth]{my_plotted_function.eps}
but ensure, that the axes labels are shown with 12pt
in both figures.
Is there another way/vector graphics format to reach this functionality? (pstricks
, tikz
is not a solution, since it's not a supported export format.)
Best Answer
psfrag
allows for this by default since it inserts the<replacement>
of<tag>
at compile-time:So you have to create the document with appropriate tags that can be replaced within your document. Here is a minimal example, taken from the
auto-pst-pdf
package on CTAN. The example image isexample.eps
:It is obvious that the
<replacement>
text maintains a consistent font size, based on the document default. You may have to adjust the placement of the<replacement>
based on the image size.