我正在创建一个tabular
包含一\multirow
列、另一列且标题很长且最后一列包含很多文本(真的很多)的列。
我已经尝试了很多解决方案,但都没有奏效,下一个解决方案很接近:
\begin{tabularx}{\textwidth}{| c| x | X |}
\hline
\multicolumn{2}{|X|}{Teoría} & Descripción \\
\hline
\multirow {4}{\begin{turn}{90}{title}} & long text & really very very very very long text \\
\hline
\end{tabularx}
但是最后一列比中心列小(必须相反),并且文本没有固定在第一列中而在第三列中溢出。
我也试过
\begin{tabularx}{\textwidth}{C{2cm}C{3cm}X}
\end{tabularx}
但这也不起作用。我需要帮助。
答案1
我认为以下布局可能接近您想要的。请注意,无需加载包multirow
。
\documentclass{article}
\usepackage[spanish]{babel}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{tabularx,graphicx}
\begin{document}
\noindent
\begin{tabularx}{\textwidth}{| c | X | X |}
\hline
\multicolumn{2}{|c|}{Teoría} & Descripción \\
\hline
\rotatebox[origin=tr]{90}{~vertical title~}
& long text
& really very very very very very very very very very very very very very very very very long text \\
\hline
\end{tabularx}
\end{document}
答案2
这是我最终可以在 Debian wheezy(一个非常旧的版本)中的 Latex 中使用的代码
\documentclass[12pt,twoside]{article}
\usepackage{supertabular}
\usepackage{array}
\usepackage{multirow}
\usepackage{rotating}
\begin{document}
\begin{supertabular}{| c | p{4cm} | p{11cm} |}
\hline
\multicolumn{2}{|c|}{\textbf{Title}} & \textbf{Title} \\
\hline
\multirow{4}{*}[-3cm]{ \rotatebox[origin=c]{90}{LONG TITLE}}
& A Lot of Text & really a lot of text really a lot of text really a lot of text really a lot of text really a lot of text really a lot of text really a lot of text \\
\cline{2-3}
& A Lot of Text & really a lot of text really a lot of text really a lot of text really a lot of text really a lot of text really a lot of text really a lot of text \\
\cline{2-3}
& A Lot of Text & really a lot of text really a lot of text really a lot of text really a lot of text really a lot of text really a lot of text really a lot of text \\
\cline{2-3}
& A Lot of Text & really a lot of text really a lot of text really a lot of text really a lot of text really a lot of text really a lot of text really a lot of text \\
\hline
\end{supertabular}
我希望对某些人有用。