[OS X TeX] Tables Question
Michael Sharpe
msharpe at ucsd.edu
Sun Jul 10 18:31:19 CEST 2011
On Jul 10, 2011, at 6:06 AM, Jada Watson wrote:
> Sorry to bother everyone again, I hope this is the last question with regard to these pesky tables.
>
> 1) Is there a way to make one column slightly narrower than the rest (I have been playing around with the \hspace code, and it doesn't seem to do the trick.
>
> 2) The table I was asking about yesterday has items spaced out in a specific way over four columns, so the example send to me uses the \multicolumn code, but I am having problems in a table that does not require multicolumns and spacing information within just a regular cell. I copied the table I attempted to make below (with the Word doc attached, it's the last table). I keep getting alignment errors. I'm sure the problem is easy, but I am not 100% sure that I'm doing this right.
>
> \noindent
> \begin{tabular}{|r|c|c|c|} \hline
> Section&Introduction&Exposition&Développement\\ \hline
> \multirow{2}{*}{Musique} &&{||: 1T\hspace{.5in}Tr\hspace{.5in}2T\hspace{.5in}TC:||}&&
> && {a b c\hspace{.5in}a, b\hspace{.3in}a'\hspace{.3in}d\hspace{.2in}e\hspace{.1in}} &e,a,b,d& \hline
> Tonalité& Sol majeur& {Sol M\hspace{.6in}mod.\hspace{.4in}Ré M\hspace{.3in}}&mod.\\ \hline
> Mesures&1&{21\hfil25\hfil33\hfil41\hfil57\hfil61\hfil72}&83\\ \hline
> \end{tabular}
>
The \multirow macro using * sets each entry to its natural width. You can force this to something different. In a Terminal window, type texdoc multirow to see the options.
Try this:
\begin{tabular}{|c|c|c|c|} \hline
Section&Introduction&Exposition&Développement\\ \hline
\multirow{3}{*}{Musique} &&{||: 1T\hspace{.4in}Tr\hspace{.4in}2T\hspace{.4in}TC:||}&\\
&&&e,a,b,d\\
&& {a b c\hspace{.5in}a, b\hspace{.3in}a'\hspace{.3in}d\hspace{.2in}e\hspace{.1in}}&\\ \hline
Tonalité& Sol majeur& {Sol M\hspace{.6in}mod.\hspace{.4in}Ré M\hspace{.3in}}&mod.\\ \hline
Mesures&1&\hbox to2.3in{21\hfil25\hfil33\hfil41\hfil57\hfil61\hfil72}&83\\ \hline
\end{tabular}
Michael
More information about the macostex-archives
mailing list