I use pdflatex in order to use microtype. However, I have to import pdf figures and not eps. The problem is that the scale option seems to be ignored because in the pdf file I see the figure in the original size.

\DisableLigatures{encoding = T1, family = tt*}
\SetTracking{shape = sc}{10}
\SetTracking{encoding = *}{100}



I tried all suggestions, also that in the accepted answer, but I confirm that it does not work. Moreover, the scale option is creepy: the image position is strange and difficult to understand why.

  • Your code does not compile. If I add an \usepackage{graphicx}, it works and does not show your problem. – Martin Schröder Feb 15 '14 at 14:16
  • @giuseppe: I wonder that your document is compiled at all using pdflatex without using usepackage{graphicx}. I used your example, added the above mentioned line exchanged your graphic pdf by one of my files -- it scaled correctly. Perhaps there is something strange in your Mad1.pdf file? – user31729 Feb 15 '14 at 14:16
  • 1
    I edited the question, sorry. How can I check if the problem is with the figure? I converted Mad1.eps to Mad1.pdf by using ps2pdf. – giuseppe Feb 15 '14 at 14:27
  • @giuseppe: ps2pdf should work but please try epstopdf as well. Have you already opened that Mad1.pdf with a pdf viewer? Does it show correctly on screen? – user31729 Feb 15 '14 at 14:35
  • You are master: epstopdf is the right command! Thanks – giuseppe Feb 15 '14 at 14:37

If an EPS file is converted with ps2pdf, the result is usually a PDF file with a full page, because EPS files are not allowed to change the media size. Therefore it is better to use option -dEPSCrop:

ps2pdf -dEPSCrop Mad1.eps

Then ghostscript will look at a comment %%BoundingBox to set the media size. Alternatively, epstopdf can be used that does a similar job and calls ghostscript:

epstopdf Mad1.eps

If the bounding box is not correctly recorded by the comment and white margins are left, then they can be removed with pdfcrop:

pdfcrop Mad1.pdf

The result is Mad1-crop.pdf.

At LaTeX level, you can check for white margins by putting the image inside \fbox:

  • I still cannot scale the figure! – giuseppe Feb 15 '14 at 15:14
  • @giuseppe: Which program generated the original Mad1.eps file? Please try to make an 'ordinary' latex file, include your Mad1.eps file and run the 'ordinary' latex command on your file, but omit that microtype commands first. – user31729 Feb 15 '14 at 15:32
  • I used both convert and gimp. – giuseppe Feb 15 '14 at 17:25
  • @giuseppe Am I supposing correctly, that your original file was a photograph stored as jpg? If that is true, you could just include the original file-- there is no need of converting to eps and then to pdf. – user31729 Feb 15 '14 at 18:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.