5

I want a long page length, and even though the PDF output shows the long page, I can only get text placed on a portion of it. I used code from this question about repeating a long block of text until it fills a page, and added the geometry package along with the adjustments for the width and height that I want. But, this does not fill up the page as I want. This is not a problem with the code in the above example, as I am seeing similar behavior in my own files: the page looks long, but has a lot of blank space and things get moved to the next page.

\documentclass{article}
\usepackage[left=10px,right=10px,top=10px,bottom=10px]{geometry}
\setlength{\paperwidth}{8.0in}
\setlength{\paperheight}{33.0in}

\usepackage{lipsum}
\newsavebox\widgetbox
\begin{document}

\setbox\widgetbox\vbox
  {\vspace*{6pt}\noindent Type of Widget: \dotfill \break
  Observations: \dotfill \break
  \null\dotfill\par}

\lipsum[1]

\cleaders\copy\widgetbox\vskip0pt plus 1fill
\end{document}

Also, any idea why the lipsum text is getting cut of on the right? I would have though that LaTeX would have adjusted for the narrower text?

8

You can solve both problems by using the paperwidth and paperheight options geometry provides instead of setting the values "manually" with \setlength:

\documentclass{article}
\usepackage[left=10px,right=10px,top=10px,bottom=10px,paperwidth=8in,paperheight=33in]{geometry}

\usepackage{lipsum}
\newsavebox\widgetbox
\begin{document}

\setbox\widgetbox\vbox
  {\vspace*{6pt}\noindent Type of Widget: \dotfill \break
  Observations: \dotfill \break
  \null\dotfill\par}

\lipsum[1]

\cleaders\copy\widgetbox\vskip0pt plus 1fill
\end{document}
  • @diabonas: Why do you use the px unit? It is specific to pdftex and meant for uning it with images – user2478 Nov 12 '11 at 14:48
  • @Herbert I used the same specifications the OP provided in his question. – diabonas Nov 13 '11 at 11:24
  • @diabonas: Ah sorry, didn't realized that ... then it is a comment to Peter – user2478 Nov 13 '11 at 17:24

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.