TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am facing a weird problem. I am trying to include an eps file into my thesis. The code I am using is as follows:



      \caption{Final image}
  \end{figure} %working code, page does not rotate. just image rotates.


This code works. But when I rotate the image with 90 deg., the image rotates but the page also rotates. If I rotate it by an angle less than or equal to 45, then the page does not rotate and only the image rotates. When the rotation is greater than 45, the page and image both rotate.

      \caption{Final image}
  \end{figure} % non-working code, image as well as page rotates.

      \caption{Final image}
  \end{figure} % non-working code, image as well as page rotates.

I want to rotate the image by 90 deg but not the page. Since each page has a header, page rotation is annoying me. Due to rotation of the page, the header comes to the right side, instead of being on the top. Can somebody help?

share|improve this question
sure, i have edited the question. – maths-help-seeker Jul 28 '12 at 21:59
Can you make the eps file available for download? – Ian Thompson Jul 28 '12 at 22:01
ce is a template done by my faculty. I think it is a custom template. – maths-help-seeker Jul 28 '12 at 22:02
up vote 8 down vote accepted

Probably you are using Ghostscript/ps2pdf. It has the feature that it inspects the page to determine in which orientation the page if viewed best. This can be turned off:

ps2pdf -dAutoRotatePages=/None

(In the command shell of Windows you might need # instead of =).

Edit: Value fixed (thanks Higgs Boson).

share|improve this answer
-dAutoRotatePages#/None or -dAutoRotatePages#false? I used the former and it works. – kiss my armpit Jul 28 '12 at 22:28
Bingo! it worked! Thank you all for your help!! – maths-help-seeker Jul 28 '12 at 22:48
Another method by invoking ghostscript directly: run gswin**c -dCompatibilityLevel=1.5 -dAutoRotatePages=/None -dPDFSETTINGS=/prepress -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=output.pdf input.ps where ** is either 32 or 64 depending which one you have installed. No need to change = to # for sure. – kiss my armpit Jul 29 '12 at 16:43

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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