[texhax] Simulating dotted leading

Uwe Lueck uwe.lueck at web.de
Sun Jun 5 20:28:46 CEST 2011

"Alister Mitchell" <alister.mitchell at btinternet.com> wrote 02.06.2011 20:46:13:
> Thanks for the reply Philip - I've sent a couple of files across off-list.

Somebody wrote that it is not nice to go off-list. E.g., I am curious about this ...
----- Original Message -----
Alister Mitchell wrote:
> Is there a (relatively) simple way of simulating the dotted leading
> used in table columns (\tabular) in old documents to separate
> text on the left from a number on the right?
> I specifically want to produce something like this in a \multicolumn 2-column span:
>        Mirror, duplex   ...   ...   ...   ...   ...   1
> To line this up with similar rows above and below, I can set a fixed space
> between the two sides in the first row, and fill following rows with rubber space.
> But not with dotted leading!
> Incidentally, I have to use a 2-column span because the table becomes 2-column further down.

I think the interesting and general task here is:
(i) Two columns, left one left-aligned, right one right-aligned.
(ii) In the spanning header cell, what is left-hand to the fill,
should be typeset with tight interword space and left-aligned
with the first column below, what is right-hand to the fill,
should be typeset with tight interword space and right-aligned
with the second column below.

The OP mentions LaTeX's tabular environment and \multicolumn,
so in the first instance we wonder whether this can be achieved
with Standard LaTeX, or (in the second instance) with some
special LaTeX package.

I really wonder how the fill could "press" its surroudings apart
appropriately. I also wonder how this could be achieved
with Plain TeX.

A solution for Standard LaTeX could be (I guess) using type `p'
for the \multicolumn. Yet this would require adjusting the width
of the spanning cell manually.

There may be a LaTeX package that automates this by
a macro-based and perhaps .aux-based procedure,
rather than using TeX's built-in \halign directly.
I think Donald Arseneau has made a similar package.

If it is so difficult with LaTeX, can Phil Taylor solve it without LaTeX?



More information about the texhax mailing list