LaTeX教程—8.LaTeX中的表格

1.LaTeX插入表格介绍

使用tabular设置表格

tabular{}后面的参数 说明
l 左对齐
c 居中对齐
r 右对齐
p=1.5cm 设置列宽,超出长度自动换行
其他符号 说明
\hline 设置横线
& 设置竖线
\ 设置换行
% 导言区
\documentclass{article}
\usepackage{xeCJK}

% 正文区
\begin{document}

	%使用tabular设置表格
	\begin{tabular}{|l||c|c|c|r|} %l左对齐;c居中;r右对齐
	\hline %设置横线
	姓名 & 语文 & 数学 & 英语 & 备注  \\
	\hline\hline
	张三 & 99 & 90 & 95 & 优秀 \\
	\hline
	李四 & 80 & 78 & 85 & 及格 \\
	\hline
	王五同学 & 59 & 32 & 1 & 补考待通知 \\
	\hline
	\end{tabular}

\end{document}

2.查看帮助文档命令

texdoc booktab
texdoc longtab
texdoc tabu

猜你喜欢

转载自blog.csdn.net/m0_38068876/article/details/113360063