[OS X TeX] Re: long tables
James Swan
jswan at u.arizona.edu
Fri Apr 30 22:09:59 CEST 2004
I've moved on to trying this, but I can't seem to get the lengths
accurate. Maybe you know why it doesn't work.
\documentclass[10pt]{book}
\usepackage{makeidx}
\usepackage{fullpage}
\usepackage{graphicx}
\usepackage{amssymb}
\usepackage{epstopdf}
\usepackage{multicol}
\DeclareGraphicsRule{.tif}{png}{.png}{`convert #1 `dirname
#1`/`basename #1 .tif`.png}
\setlength{\columnsep}{1mm}
%\setlength{\columnseprule}{.1mm}
\raggedbottom
\makeindex
\begin{document}
\begin{multicols}{4}
\newlength{\thecenter}
\setlength{\thecenter}{0.5 \columnwidth }
\newlength{\theword}
\newlength{\thehook}
\newcommand{\wordandhooks}[3]
{
\settowidth{\theword}{#2}
\setlength{\thehook}{\thecenter}
\addtolength{\thehook}{-\theword}
\noindent
\begin{tabular}[h]{p{\thehook}p{2\theword}p{\thehook}}
\begin{minipage}{\thehook}\flushleft #1\end{minipage} &
\begin{minipage}{2\theword} \center #2 \end{minipage} &
\begin{minipage}{\thehook}\flushright #3\end{minipage} \\
\end{tabular}\\
}
\newcommand{\anagram}[1]
{
\setlength{\thehook}{\thecenter}
\settowidth{\theword}{#1}
\addtolength{\thehook}{-0.5\theword}
\hspace{\thehook}
\begin{minipage}{\theword}
{ \it #1}
\end{minipage}
}
%\include{wordlist8}
\wordandhooks{abc\\ edf}{my fatea}{lmn}
\wordandhooks{abc\\ edf}{my fatea}{lmn}
\wordandhooks{abc\\ edf}{my fatea}{lmn}
\wordandhooks{abc\\ edf}{my fatea}{lmn}
\wordandhooks{abc\\ edf}{my fatea}{lmn}
\wordandhooks{cat\\ dog}{mouse}{bird}
\end{multicols}
\end{document}
Thanks
On Apr 30, 2004, at 8:07 AM, Tate Wilson wrote:
> I wanted to do almost exactly the same thing. I'm preparing a large
> number of pages, each of which has a plot in the top half and a table
> of the ploted data in the bottom half. The data is, of course, two
> columns, and I wanted the table to wrap into multiple columns so it
> would fit all on one page. I was not able to make this work with
> multicol. It was suggested to me that it might be possible by using
> minipages and defining each minipage to be in the size and location of
> one of the desired columns. I never tried this because I found
> another way first. Instead of having multiple columns in the page,
> make the table span the page and have redundant columns within it.
> You can even make it look like separate tables by having blank columns
> in between. The difficulty with this is that you have to predetermine
> how long the table has to be because you have to "wrap" it by hand and
> it won't change to fit into the given space. This is no problem for
> me because every page I want to do this to will be the same, so once I
> figure out how many rows to have in the first table it will be the
> same for all of them.
>
> Here is an example. It also shows how to leave the spacer columns
> blank if you use horizontal lines:
>
> \tablecaption[Figgerin']{\label{testtable}This table is just a test of
> the way I may include all the raw data}
> \begin{supertabular}{c|ccc|ccc|ccc|c}
> T (K) & C (mJ/K) & & T (K) & C (mJ/K) & & T (K) & C (mJ/K) & & T (K) &
> C (mJ/K)\\ \cline{1-2} \cline{4-5} \cline{7-8} \cline{10-11}
> {\rule[0mm]{0mm}{4mm}5.1564} & 1.8765 & & 2.3654 & 2.0098 & & 7.1924 &
> 5.7650 & & 3.9876 & 7.2323\\
> 12.3245 & 62.5284 & & 42.2358 & 72.1478 & & 72.1924 & 52.7650 & &
> 32.9876 & 72.2323\\
> 3.5285 & 3.2148 & & 1.4587 & 0.0032 & & 7.1924 & 5.7650 & & 3.9876 &
> 7.2323\\
> 6.1245 & 3.8547 & & 0.2589 & 3.2584 & & 7.1924 & 5.7650 & & 3.9876 &
> 7.2323\\
> \end{supertabular}\\
>
>
> Note that I didn't really need supertabular to do this.
>
> cheers,
> tate
>
> PS I'm not a subscriber to the list you posted this on, it was
> forwarded to me by a friend. If you find this useful, please feel
> free to post it for everyone.
>
>
http://www.u.arizona.edu/~jswan/blog/
-----------------------------------------------------
Please see <http://www.esm.psu.edu/mac-tex/> for list
guidelines, information, and LaTeX/TeX resources.
More information about the macostex-archives
mailing list