[Tex/LaTex] eps images turned out to be shifted in pdf file

dvipdfmxepstopdfgraphicshorizontal alignment

I am trying to include an image. This picture should be centered and should not exceed page width:

\documentclass{article}
\usepackage{graphicx}
\usepackage[showframe]{geometry}

\begin{document}

\begin{figure}
\centering
\fbox{\includegraphics[width=.9\textwidth]{image.eps}}
\end{figure}

\end{document}

It looks perfectly in DVI file but fails in PDF during LaTex-DVI-PDF compilation. .eps file is converted to pdf with dvipdfm postprocessor but displays wrong. Here is the output screen.

enter image description here
!

So why is it shifted from the specified position and how it can be fixed?

\usepackage[showframe]{geometry} and \fbox{} commands are unnecessarily here but help me to detect problem. I'm also unsuccessfully tried to use different graphicx package like \usepackage[dvipdfm]{graphicx} and \usepackage[pdftex]{graphicx}.

I'm using MiKTeX 2.9.5105 and TeXnicCenter v2.02.

Best Answer

enter image description here

By default for latex dvips is assumed. texlive doesn't come with a dvipdfm option but does include dvipdfmx.def which seems to work well enough with dvipdfm

\documentclass{article}
\usepackage[dvipdfmx]{graphicx}
\usepackage[showframe]{geometry}

\begin{document}

\begin{figure}
\centering
\fbox{\includegraphics[width=.9\textwidth]{image.eps}}
\end{figure}

\end{document}
Related Question