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:


Thanks in advance!

migrated from stackoverflow.com Aug 2 '12 at 16:14

This question came from our site for professional and enthusiast programmers.

  • I used the demo option for graphicx, and I do not get a blank page in the start of my document using your code. – J M Aug 2 '12 at 16:18
  • 3
    Use \usepackage{geometry} to set the margin and type block. – Sveinung Aug 2 '12 at 16:19
  • 1
    At a guess, I'd say your pictures are bigger than the page size that you've defined. Try using the geometry package to get better control over the page size and make it big enough that your pictures fit on the page. – Loop Space Aug 2 '12 at 16:19
  • @AndrewStacey: this was also my suspicion; @ozu: you can test this very easily if you replace the first \includegraphics{...} with \rule{17.7cm}{35cm}. When you change the height to a smaller value, e.g. 25 cm, no blank page is generated. – hakaze Aug 2 '12 at 16:23
  • My pictures are exactly the same height as the page height I defined, and it turns out I simply had to set it a little higher, changing it from \setlength{\textheight}{25.8cm} to \setlength{\textheight}{25.9cm} did the trick. Thanks a lot! However, I'd like to know why does it work this way. Do the images get some minimal border/margin by default? – ozu Aug 2 '12 at 16:46

Even a tiny difference in the computed dimensions may produce an overfull box. So I suggest another approach: zero margin and vertical centering.










  • 1
    I already solved the problem somehow, but this is clearly a far more elegant solution, I didn't know you could use geometry to set all margins to 0 at once. I guess I should actually sit down and make some effort to learn LaTeX properly instead of trying to stitch a pdf in 15 minutes with no prior experience. Thanks again – ozu Aug 2 '12 at 17:27
  • 1
    @ozu I think most of us started out my trying to stitch a pdf in 15 minutes with no prior experience ... so you're currently following the tried-and-tested route for learning LaTeX! – Loop Space Aug 2 '12 at 19:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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