I just installed LaTeX with TeXworks today. I need to create a simple PDF out of a couple large images, I realize this is likely very crude and roundabout but I somehow managed to get the thing done. However, LaTeX inserts a blank page before the stuff I want, and I can't find a way to get rid of it. I thought it may simply be the title page and tried adding notitlepage
in documentclass
, but that's not it. Here's the whole thing:
\documentclass[a4paper]{article}
\usepackage{graphicx}
\setlength{\oddsidemargin}{0pt}
\setlength{\topmargin}{0pt}
\setlength{\headheight}{0pt}
\setlength{\headsep}{0pt}
\setlength{\marginparsep}{0pt}
\setlength{\marginparwidth}{0pt}
\addtolength{\voffset}{-20pt}
\addtolength{\hoffset}{-22pt}
\setlength{\textheight}{25.8cm}
\graphicspath{{A:/Desktop/pdf/1/}}
\DeclareGraphicsExtensions{.png}
\pagenumbering{gobble}
\begin{document}
\centering
\includegraphics[width=17.7cm]{pg1}
\newpage
\includegraphics[width=17.7cm]{pg2}
\newpage
\includegraphics[width=17.7cm]{pg3}
\newpage
\includegraphics[width=17.7cm]{pg4}
\newpage
\includegraphics[width=17.7cm]{pg5}
\end{document}
Thanks in advance!
Best Answer
Even a tiny difference in the computed dimensions may produce an overfull box. So I suggest another approach: zero margin and vertical centering.