作者andrew43 (讨厌有好心推文後删文者)
看板LaTeX
标题Re: [问题] 表头排版问题
时间Thu Jul 24 01:23:48 2014
你的观念都正确,但不知道你卡在哪里。
\begin{table}
\begin{tabular}{lr@{$\times$}lr@{,}r}
\hline
Game & \multicolumn{2}{c}{Map Size} & \multicolumn{2}{c}{Target} \\
\hline
1 & 7 & 11 & 2 & $-$3 \\
2 & 11 & 8 & $-$3 & 2 \\
\hline
\end{tabular}
\end{table}
※ 引述《Jackliu2619 ()》之铭言:
: 目前想做的表格大概长这样:
: __________________________
: Game Map Size Target
: __________________________
: 1 7 x 11 2, -3
: 2 11 x 8 -3, 2
: __________________________
: 我希望第二行的的 x 和 第三行的 , 可以对齐
: 试过 dcolumn 巨集,但排不出我要的感觉。
: 最後是用
: \begin{table}
: \begin{tabular}{lr@{$\times$}rr@{,}r}
: 1 & 7 & 11 & 2 & -3 \\
: 2 & 11 & 8 & -3 & 2 \\
: \end{tabular}
: \end{table}
: 的方式硬写出来
: 但遇到的问题是当我想把表头放回去时
: 下 multicolumn{2}{c}{Map Size}
: 都还是会回传
: !Missing \cr inserted.
: 不太知道要如何解决,想请有经验的板友指点
: 谢谢
--
※ 发信站: 批踢踢实业坊(ptt.cc), 来自: 122.117.37.172
※ 文章网址: http://webptt.com/cn.aspx?n=bbs/LaTeX/M.1406136232.A.670.html
※ 编辑: andrew43 (122.117.37.172), 07/24/2014 01:25:55
1F:推 Jackliu2619:结果检查很久後发现是其他地方出错(原始表格更大) 07/24 20:28
2F:→ Jackliu2619:非常谢谢你的回答.... 07/24 20:29