[texhax] A question about \halign
Rodolfo Medina
rodolfo.medina at gmail.com
Fri Jul 3 23:14:57 CEST 2009
Rodolfo Medina <rodolfo.medina at gmail.com>:
>> In plain TeX, I have the following problem:
>>
>> I have the following alignment:
>>
>>
>> \halign to \hsize{%
>> \vtop{\parindent=0pt\hsize=105mm\hangindent 0em\strut#\hfill\strut}%
>> \tabskip=0cm plus20cm minus20cm&\hfil#\tabskip=0pt\cr
>> bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla
>> bla bla bla bla bla bla bla bla bla bla bla bla bla &bnbnbnbnb\cr}
>>
>>
>> \bye
>>
>>
>> Now, I want that, when the first argument is very long and continues over a
>> second line, the second argument is put on the second line as well (in the
>> above example it is put on the first line, instead).
Dave Geering <dlgeering at gmail.com> writes:
> If you use \vbox instead of \vtop it will put bnbnbnbnb on the second
> line. Is that what you intended?
Donald Arseneau <asnd at triumf.ca> writes:
> Then use \vbox, not \vtop.
Yes, thanks for your help, that's fine.
But now, suppose that I want a third argument of the alignment to stay on the
first line, instead:
\halign to \hsize{%
\quad\rm\ \ \ \ \llap{1.2}\
\vbox{\parindent=0pt\hsize=105mm\hangindent 0em\strut#\hfill\strut}%
\tabskip=0cm plus20cm minus20cm&\hfil#\tabskip=0pt\cr
bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla
bla bla bla bla bla bla bla bla bla bla bla bla bla &bnbnbnbnb\cr}
\bye
I want that `\quad\rm\ \ \ \ \llap{1.2}\ ' stays on the first line and
`bnbnbnbn' on the second line.
Excuse that I'm asking too much!!
How can I achieve that?
Help very much appreciated: it's for the format of a table of content.
Thanks
Rodolfo
More information about the texhax
mailing list