Graphics, Figures & TablesVertical Alignment of Line or Cell with 'minipage'

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
Montag
Posts: 340
Joined: Wed Jul 15, 2009 9:25 am

Vertical Alignment of Line or Cell with 'minipage'

Post by Montag »

Hello,

how can I push the last line (which contains "Word Three") lower to make it have a more sophisticated look?

Code: Select all

\documentclass[
fontsize=12pt,
english
]{scrartcl}

\usepackage{lmodern}
\usepackage[T1]{fontenc}

\newcommand{\mini}[1]{\begin{minipage}[t]{9cm}#1\end{minipage}}

\begin{document}
\begin{center}
\begin{tabular}{ll}
01/02 & Word One\\
03/04 & Word Two\\
05/06 & \mini{Some more words which are usesless but have the purpose  of forming a sentence.}\\
07/08 & Word Three
\end{tabular}
\end{center}
\end{document}
OS: Win 7 64-bit LaTeX: MikTeX 2.9 64-bit Editor: TXC 1 RC1

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

Learn LaTeX easily with newest books:

The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis

The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more

LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis

User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Vertical Alignment of Line or Cell with 'minipage'

Post by localghost »

Don't think so complicated. Load the array package and choose an appropriate column type.

Code: Select all

\documentclass[fontsize=12pt]{scrartcl}
\usepackage[T1]{fontenc}
\usepackage{array}

\begin{document}
  \begin{tabular}{lm{9cm}}
    01/02 & Word One \\
    03/04 & Word Two \\
    05/06 & Some more words which are useless but have the purpose of forming a sentence. \\
    07/08 & Word Three
  \end{tabular}
\end{document}
Details in the package manual.


Thorsten
Montag
Posts: 340
Joined: Wed Jul 15, 2009 9:25 am

Re: Vertical Alignment of Line or Cell with 'minipage'

Post by Montag »

Oh, ok, I'm gonna save that for another opportunity. :)
But it doesn't solve my problems since it has to be inside of a tabular environment.
OS: Win 7 64-bit LaTeX: MikTeX 2.9 64-bit Editor: TXC 1 RC1
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Re: Vertical Alignment of Line or Cell with 'minipage'

Post by localghost »

I'm a afraid you will have to tinker with additional vertical space.
Montag
Posts: 340
Joined: Wed Jul 15, 2009 9:25 am

Vertical Alignment of Line or Cell with 'minipage'

Post by Montag »

Well I do not know how to do that then. I already added something like

Code: Select all

[2pt]
at the critical lines to tinker around, but that didn't give me a good result. Is there another way?
OS: Win 7 64-bit LaTeX: MikTeX 2.9 64-bit Editor: TXC 1 RC1
Post Reply