[XeTeX] tabular in footnote

Zdenek Wagner zdenek.wagner at gmail.com
Mon Dec 5 13:14:01 CET 2011


2011/12/5 Petr Tomasek <tomasek at etf.cuni.cz>:
> On Sun, Dec 04, 2011 at 07:31:59AM +0800, Daniel Greenhoe wrote:
>> When I put a tabular in a footnote, the tabular often is extended
>> outside the text area. Besides placing a newline directive after the
>> tabular environment, is there anything I can do to prevent this
>> behavior? That is, how can I best ensure that tabulars in a footnote
>> get typeset completely within the text area? Here is an example:
>
> Put it in \vbox :-). At least I would do so in plain(Xe)TeX. :-)
>
In (Xe)LaTeX it will be even worse because the natural width of a
\vbox is the line width. If such a \vbox appears in a paragraph just
after the footnote number, it will result in an overful \hbox.
Breaking the line between the footnote number and the \vbox is in
principle possible but the \hbox will be badly underfull and TeX will
not do it unless \tolerance is set to 10000. The problem is most
probably caused by the fact that tabular has zero height and positive
depth, it is probably set as \vtop. If placed inside \vbox, the
baseline of the \vbox will be aligned with the baseline of tabular,
thus the \vbox will still have zero height and positive depth (see my
example in one of my previous posts). Thus \vbox does not improve the
situation.

>> \documentclass[12pt]{book}
>> \usepackage[xetex,a4paper,noheadfoot,nomarginpar,margin=20mm,showframe]{geometry}
>> \begin{document}%
>>   xyz\footnote{%
>>     %\raisebox{2.5mm}{
>>       \begin{tabular}[t]{|l|}
>>        \hline
>>         abc\\
>>         def\\
>>         ghj\\
>>         klm\\
>>         \hline
>>       \end{tabular}%\\
>>       %}%
>>     }
>>   xyz\footnote{%
>>     %\raisebox{2.5mm}{
>>       \begin{tabular}[t]{|l|}
>>        \hline
>>         abc\\
>>         def\\
>>         ghj\\
>>         klm\\
>>         \hline
>>       \end{tabular}%\\
>>       %}%
>>     }
>> \end{document}%
>>
>> Many thanks in advance,
>> Dan
>>
>
>
>
>>
>>
>> --------------------------------------------------
>> Subscriptions, Archive, and List information, etc.:
>>   http://tug.org/mailman/listinfo/xetex
>>
>
>
> --
> Petr Tomasek <http://www.etf.cuni.cz/~tomasek>
> Jabber: butrus at jabbim.cz
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> EA 355:001  DU DU DU DU
> EA 355:002  TU TU TU TU
> EA 355:003  NU NU NU NU NU NU NU
> EA 355:004  NA NA NA NA NA
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
>
>
>
> --------------------------------------------------
> Subscriptions, Archive, and List information, etc.:
>  http://tug.org/mailman/listinfo/xetex



-- 
Zdeněk Wagner
http://hroch486.icpf.cas.cz/wagner/
http://icebearsoft.euweb.cz



More information about the XeTeX mailing list