我如何重新创建这个表?

我如何重新创建这个表?

我想重新创建的表

我想在 LaTeX 中重新创建此表格。但是,我无法获取沿 y 轴的文本。可以吗?

答案1

在此处输入图片描述

该“表格”由以下人员绘制tikz

\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{positioning, shadows}

\begin{document}
    \begin{tikzpicture}[
node distance = 0pt,
   box/.style = {draw=brown, fill=white, 
                 minimum size=42mm,
                 text width =\pgfkeysvalueof{/pgf/minimum width} - 2*\pgfkeysvalueof{/pgf/inner xsep},
                 inner sep=7mm, align=left,
                 drop shadow={fill=black, shadow xshift=2mm, shadow yshift=-2mm}
                 },
   lbl/.style = {font=\large\bfseries}
                        ]
\node (n11) [box]               {\bfseries      xxxxx\\ xxxx\\
                                 \normalfont    (svak + sterk)};
\node (n12) [box,right=of n11]  {\bfseries      xxxxx\\ xxxx\\
                                 \normalfont    (svak+sterk)};
\node (n21) [box,below=of n11]  {\bfseries      xxxxx\\ xxxx\\
                                 \normalfont    (svak+sterk)};
\node (n22) [box,right=of n21]  {\bfseries      xxxxx\\ xxxx\\
                                 \normalfont    (svak + sterk)};
  %
\node[lbl,left=3mm of n11.south west,anchor=south,rotate=90] {Selvhevdelse};
\node[lbl, below=3mm of n22.south west] {Samarbeidsorientering};  
\end{tikzpicture}
\end{document}

答案2

fancybox下面是一个带有 和的 简单代码rotating。我定义了一个命令,该命令在类型列\mycell中创建(近似)方形单元格:p{...}

\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage{newtxtext, newtxmath}
\usepackage{makecell}
\usepackage{fancybox, rotating}
\newlength{\cellwd}
\setlength\cellwd{30mm}
\newcommand{\mycell}[1]{\raisebox{0pt}[0.53\cellwd][0.47\cellwd]{\makecell[l]{#1}}}

\begin{document}

\begin{table}[!ht]
    \centering\bfseries\fboxsep = 0pt
    \begin{tabular}{c@{\hskip 0.75em}>{\centering\arraybackslash}m{7cm}}
    \rotatebox[origin =bc]{90}{Selhelvdelse}%
     & \shadowbox{\begin{tabular}{>{\centering\arraybackslash}m{\cellwd}|>{\centering\arraybackslash}m{\cellwd}}
        \mycell{Fientlig\\holdning\\\mdseries(svak + sterk)} & \mycell{Samarbeidende\\stil\\\mdseries(sverk + sterk)} \tabularnewline
        \hline
         \mycell{Unnvikendeg\\\mdseries(svak + svak)} & \mycell{Forsvarsholdning\\\mdseries(sterk + svak)}
    \end{tabular}} \\
    & Samarbeidsorientering
    \end{tabular}
\end{table}

\end{document}

在此处输入图片描述

相关内容