LyX ⇒ Table Column Widths
-
- Posts: 1
- Joined: Mon Nov 30, 2009 8:43 pm
Table Column Widths
I am making some tables for a document (report class with customised margins). I set the widths of individual columns by right clicking on them and settings/table and settings/width and changing the value to whatever I wish. Regardless of whether I set the value in inches, mm, % of page etc, there is a really strange trend I have noticed:
A column of 2x (where x is any number) is always less wide than 2 columns of width x. Does this make sense?
Furthermore, the workable space on my document is 6 inches, as confirmed by the width I have set for my graphics which work fine, however a table of 1 column needs have that column at around 5.835 inches in order to produce a 6 inch column in the PDF, AND tables of two columnsor more will produce tables wider than 6 inches despite each value of the individual columns totalling 5.835 inches.
I would like to know what is going on so I can create tables that are all the same width regardless of how many columns each individual table has.
Any ideas?
I am using the latest version of LyX and Snow Leopard.
Thank you in advance.
Sam
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
Table Column Widths
Don't know anything about clicking and right-clicking in LaTeX, so I can help with a solution that involves a cool device (the keyboard). OK, enough of that.
A table, in LaTeX is created with the "tabular" environment. You need to, from the source code file, write:
Code: Select all
\begin{tabular}{|p{6in}|p{6in}|}\hlinethe value in the first column & the value in the second column \\ \hlinethe second value in the first column & the second value in the second column \\ \hline\end{\tabular}
Hope this helps. Cheers