Auto size of images in Beamer class \usepackage…

Auto size of images in Beamer class.

\usepackage{letltxmacro}
\makeatletter
\def\maxwidth{\ifdim\Gin@nat@width>\linewidth\linewidth\else\Gin@nat@width\fi}
\makeatother
\AtBeginDocument{
  \LetLtxMacro\Oldincludegraphics\includegraphics
  \renewcommand{\includegraphics}[2][]{%
    \Oldincludegraphics[#1,width=\maxwidth]{#2}}
}

http://tex.stackexchange.com/questions/67434/redefine-includegraphics-for-beamer#comment143600_67434

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *