Pietro
2008-04-07 05:01:49 UTC
Whats the deal with vertical spaces in minipages?
When I use stuff like \vspace{\stretch{1}} in a minipage, it seems to
be doing its calculations relative to the height of the whole page,
not just the minipage (even when I specify the height of the minipage
when I construct it). Also \flushbottom doesnt seem to work in
minipages.
Can anyone explain or send a url? I am trying to do things like define
minipages of fixed heights, vertically center stuff inside them, etc.
For example I had hoped that the following would give me a minipage
that is half the height of the page, which contains two minipages side
by side (each half the page wide) and an image below them.
% Half height of page, full width
begin{minipage}[t][0.49\textheight]{\textwidth}
% Full height of outer minipage, half width
\begin{minipage}[t][\textheight]{.49\textwidth}
content ...
\end{minipage}
% Full height of outer minipage, half width
\begin{minipage}[t][\textheight]{.49\textwidth}
\includegraphics[width=\textwidth]{foo}}
\end{minipage}
\includegraphics[width=\textwidth]{bar}}
\end{minipage}
What I would like is for the bar image to be at the bottom of the
outer minipage, for the 2 inner minipages to fill up the remaining
space above it, and for the foo image to be vertically centered in its
minipage. I cant figure it out tho ...
Thanks.
When I use stuff like \vspace{\stretch{1}} in a minipage, it seems to
be doing its calculations relative to the height of the whole page,
not just the minipage (even when I specify the height of the minipage
when I construct it). Also \flushbottom doesnt seem to work in
minipages.
Can anyone explain or send a url? I am trying to do things like define
minipages of fixed heights, vertically center stuff inside them, etc.
For example I had hoped that the following would give me a minipage
that is half the height of the page, which contains two minipages side
by side (each half the page wide) and an image below them.
% Half height of page, full width
begin{minipage}[t][0.49\textheight]{\textwidth}
% Full height of outer minipage, half width
\begin{minipage}[t][\textheight]{.49\textwidth}
content ...
\end{minipage}
% Full height of outer minipage, half width
\begin{minipage}[t][\textheight]{.49\textwidth}
\includegraphics[width=\textwidth]{foo}}
\end{minipage}
\includegraphics[width=\textwidth]{bar}}
\end{minipage}
What I would like is for the bar image to be at the bottom of the
outer minipage, for the 2 inner minipages to fill up the remaining
space above it, and for the foo image to be vertically centered in its
minipage. I cant figure it out tho ...
Thanks.