[l2h] problem with side-by-side minipages

Ross Moore ross at ics.mq.edu.au
Thu Jan 19 01:17:36 CET 2006


Hi John,

On 19/01/2006, at 9:06 AM, john wrote:

>
> I have 2 minipages with an \hfill between them.
> They show up side-by-side in DVI and PDF.
> But latex2html places them one-above-the-other.

Well actually it's HTML that's doing that.

In TeX things like mini-pages, figures, etc.
are created as an \hbox or \vbox .
These stack horizontally in normal paragraphing mode.

For HTML, such things are built into a  <TABLE>...</TABLE>
construction. But to a web-browser a <TABLE> is a block-level
structure (rather than a text-level one).
In (La)TeX parlance, it is vertical material rather than
horizontal, so you see what you see.

Since in HTML the text-size and graphics are generally
relatively larger compared to the window-size, it is not
at all clear that when images are side-by-side in print
that they should remain so in HTML.
This is why I didn't bother to program "looking-ahead"
to try to work out how to stack minipages in every
possible situation.

Instead you can do it yourself, using a {tabular}
environment conditionally:

\begin{htmlonly}
\begin{tabular}{cc}
\end{htmlonly}
\begin{minipage} ..... 1st minipage
\end{minipage}
\html{&}%  so LaTeX doesn't see the & , and don't forget the % .
\begin{minipage} ..... 2nd minipage
\end{minipage}
\begin{htmlonly}
\end{tabular}
\end{htmlonly}


>
> My system: SuSE linux 9.3; latex2html 2002-2-1 (1.70)

This isn't a system-dependent thing.

>
> regards
> John O'Gorman


Hope this helps,

	Ross Moore


------------------------------------------------------------------------
Ross Moore                                         ross at maths.mq.edu.au
Mathematics Department                             office: E7A-419
Macquarie University                               tel: +61 +2 9850 8955
Sydney, Australia  2109                            fax: +61 +2 9850 8114
------------------------------------------------------------------------




More information about the latex2html mailing list