\documentclass{article}
\usepackage{multirow}
\begin{document}
\begin{table}[htbp]
\centering
\begin{tabular}{ccccp{1cm}p{1cm}p{1cm}p{1cm}p{1cm}p{1cm}p{1cm}}
\hline
& A & B & C \\
& & & &\\
\hline
\multirow{2}{*}{This is a really long sentence sentence sentence} & 0 & 6 & 230 \\
& 1 & 5 & 195 \\ \hline
\end{tabular}
\label{table2}
\end{table}
\end{document}
答案1
您可以定义自己的命令并赋予其宽度和文本\breakText{5cm}{text}
,如下所示:
\documentclass{article}
\usepackage{multirow}
\newcommand{\breakText}[2]{%
\noindent \parbox{#1}{%
#2
}%
}
\begin{document}
\begin{table}[htbp]
\centering
\begin{tabular}{ccccp{1cm}p{1cm}p{1cm}p{1cm}p{1cm}p{1cm}p{1cm}}
\hline
& A & B & C \\
& & & &\\
\hline
\multirow{2}{*}{\breakText{5cm}{This is a really long sentence sentence sentence}} & 0 & 6 & 230 \\
& 1 & 5 & 195 \\ \hline
\end{tabular}
\label{table2}
\end{table}
\end{document}