0

I was wandering if there is a command that will let you define the size of graphics globally throughout then entire document. Most of my images are photos and should all be the same size and it would be good if I could change one thing that will affect the size of them all, rather than having to do it manually. For the odd picture here and there that has different dimensions I can adjust their size manually.

Question content copied with permission from a post on /r/latex.

Sean Allred
  • 27,421

1 Answers1

1

Use graphicx's keyval group:

\setkeys{Gin}{width=25cm}

Stick that in your preamble after you load graphicx. If you're not loading it explicitly, put it right after \begin{document}.

After this, you shouldn't have to supply the width key at all when you use \includegraphics. Of course, if you do supply the width key, that value will take precedence.

\documentclass{article}
\usepackage{graphicx}

\setkeys{Gin}{width=.25\linewidth} % or whatever

\begin{document}
\includegraphics{example-image-a}
\end{document}
Sean Allred
  • 27,421