Graphics, Figures & Tables ⇒ Tabular: Centering text in one row & better text alignment
Tabular: Centering text in one row & better text alignment
I have to issues creating a table using the tabular environment. I'm quite new to latex, so the solutions might be quite easy...
1: I would like to center the text in the first row. Is it possible?
2: I have a lot of text in some cells and it looks awful as it spreads out all over the cell width. Can i get "normal" alignment somehow?
Many thanks in advance!
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
- Stefan Kottwitz
- Site Admin
- Posts: 10348
- Joined: Mon Mar 10, 2008 9:44 pm
Tabular: Centering text in one row & better text alignment
- yes, using \centering or \multicolumn, for example
Code: Select all
\multicolumn{3}{c}{Text}
- you could use \raggedright in the column definition or within the cell.
Stefan
Re: Tabular: Centering text in one row & better text alignme
For the record I solved 1 by using \centering and 2 by using \raggedright in a tabularx-environment (as it fitted my purpose better).
Again, thanks alot.