在表格中居中旋转多行

在表格中居中旋转多行

我正在修复下面的表格,到目前为止一切正常。我只是无法让前两行的文本垂直居中。我猜是多列阻碍了对齐,但我不知道还有其他方法可以做到这一点。只是没有人会费心去建议:我必须模仿现有的表格,所以我需要有所有的垂直线,尽管良好的排版规则是这么说的。

有人知道如何让前两行的文本在各自的单元格中居中,而不需要像后面的行那样使用“\vspace”解决方法吗?

\documentclass[demo,draft]{scrreprt}

\usepackage{multirow}
\usepackage{rotating}
\usepackage{tabulary}

\begin{document}

\begin{table}
    \centering
    \setlength{\extrarowheight}{2pt}%
    \begin{tabulary}{\linewidth}{|C|C|C|C|C|C|C|}
    \hline
    \multicolumn{2}{|c|}{} & \multicolumn{5}{c|}{Eisschichtdicke / mm}\\
    \cline{3-7}
    \multicolumn{2}{|c|}{}  & 1,0 & 2,0 & 3,0 & 4,0 & 5,0\\
    \hline
    \multirow{5}{*}{\rotatebox{90}{{Auslenkung / mm}}} & 1,0 & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/1mm/V24_1,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/2mm/V4_1,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/3mm/V5_1,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/4mm/V3_1,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/5mm/V21_1,0}} \\[2pt]
    \cline{2-7}
     & 1,5 & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/1mm/V24_1,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/2mm/V4_1,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/3mm/V5_1,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/4mm/V3_1,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/5mm/V21_1,5}} \\[2pt]
    \cline{2-7}
     & 2,0 & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/1mm/V24_2,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/2mm/V4_2,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/3mm/V5_2,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/4mm/V3_2,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/5mm/V21_2,0}} \\[2pt]
    \cline{2-7}
     & 2,5 & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/1mm/V24_2,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/2mm/V4_2,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/3mm/V5_2,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/4mm/V3_2,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/5mm/V21_2,5}} \\[2pt]
    \cline{2-7}
    \hline
    \end{tabulary}
    \label{Bildmatrix}
\end{table}

\end{document}

答案1

 \documentclass[demo,draft]{scrreprt}
 \usepackage{multirow}
\usepackage{rotating}
\usepackage{tabulary}
\usepackage{makecell}
\begin{document}
\begin{table}
\centering
\setlength{\extrarowheight}{2pt}%
\begin{tabulary}{\linewidth}{|r|C|C|C|C|C|C|}
\hline
\multicolumn{2}{|c|}{} & \multicolumn{5}{c|}{Eisschichtdicke / mm}\\
\cline{3-7}
\multicolumn{2}{|c|}{}  & 1,0 & 2,0 & 3,0 & 4,0 & 5,0\\
\hline
{\rotatebox{90}{\makecell{\multirow{5}*{  \vspace{56pt}\hspace{-260pt} Auslenkung / mm}}}}
   \vspace{40pt} 1,0 & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/1mm/V24_1,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/2mm/V4_1,0}} & \vspace{-6pt}
&{\includegraphics[width=\linewidth]{figures/Matrix/3mm/V5_1,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/4mm/V3_1,0}} 
& \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/5mm/V21_1,0}} \\[2pt]
\cline{2-7}
 &   \vspace{40pt} 1,5 & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/1mm/V24_1,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/2mm/V4_1,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/3mm/V5_1,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/4mm/V3_1,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/5mm/V21_1,5}} \\[2pt]
\cline{2-7}
 &   \vspace{40pt} 2,0 & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/1mm/V24_2,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/2mm/V4_2,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/3mm/V5_2,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/4mm/V3_2,0}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/5mm/V21_2,0}} \\[2pt]
\cline{2-7}
 &   \vspace{40pt} 2,5 & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/1mm/V24_2,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/2mm/V4_2,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/3mm/V5_2,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/4mm/V3_2,5}} & \vspace{-6pt}{\includegraphics[width=\linewidth]{figures/Matrix/5mm/V21_2,5}} \\[2pt]
\cline{2-7}
\hline
\end{tabulary}
\label{Bildmatrix}
\end{table}
\end{document}

旋转文本

相关内容