Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

In another question, Harald showed how to make vertical leaders. Armed with this knowledge, I set sail to answer another question, but as I've tried to put such leaders into a page with other material as well, the leaderfill always takes up the whole page.

Is there a general way to typeset something onto a page, which then would be handled by TeX as if nothing had been typeset at all (i.e., it wouldn't take any kind of space away from other material)?

Example:

\newbox\needlebox\setbox\needlebox=\vbox{\hsize=2em$\cdot$}
\def\needlefill{\cleaders\copy\needlebox\vskip0pt plus 1fill}
\llap{\hbox to 2em{\vbox to\vsize{\hsize=2em\needlefill}}} Blah
\bye

(The "Blah" goes to second page)

share|improve this question

2 Answers 2

up vote 1 down vote accepted

\llap is the right direction, but you still need a vertical version of it:

\newbox\needlebox\setbox\needlebox=\vbox{\hsize=2em$\cdot$}
\def\needlefill{\cleaders\copy\needlebox\vskip0pt plus 1fill}
\llap{\vbox to 0pt{\hbox to 2em{\vbox to\vsize{\hsize=2em\needlefill}}\vss}} Blah
\bye

See also this discussion on c.t.t I started about \blap and \tlap macros.

share|improve this answer

(not tested)

a box in vertical mode gets set and stays in vertical mode. you need to get out of vertical mode.

precede the \llap by \leavevmode to put you into horizontal mode.

you may also want to give \vbox the height of a line of text to avoid having it line up at the bottom. \vbox to Npt{...} where N = the height of the first line; the height of \mathstrut is probably a good value.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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