答案1
一种可能性是使用colortbl
和forest
是@cfr 的这个很好的例子。
\documentclass{article}
\usepackage{colortbl}
\usepackage{forest}
\forestset{
dir node/.style={
parent anchor=south west,
child anchor=west,
anchor=west,
inner ysep=0pt,
align=left,
},
dir tree/.style={
for tree={
grow'=0,
dir node,
edge path={
\noexpand\path [draw, \forestoption{edge}] (!u.parent anchor) ++(1em,0) |- node[fill,inner sep=1.25pt] {} (.child anchor)\forestoption{edge label};
},
if n children=0{}{
delay={
prepend={[text 1, dir node, phantom, calign with current]}
}
},
fit=band,
before computing xy={
l=1em,
}
},
}
}
\begin{document}
\begin{tabular}{p{0.3\textwidth}p{0.3\textwidth}p{0.3\textwidth}}
\rowcolor{gray}
Trends I & Trends II & Trends III\\
\rowcolor{gray!50}
\begin{forest} % from https://tex.stackexchange.com/a/286188/121799
dir tree,
for tree = {
font=\ttfamily
}
[text 1
[text 2
[text 3
[text 4
[text 5.1
[text 6]
]
[text 5.2
]
]
]
]
]
\end{forest}
&
\begin{forest}
dir tree,
for tree = {
font=\ttfamily
}
[text 1
[text 2
[text 3
[text 4
[text 5.1
[text 6]
]
[text 5.2
]
]
]
]
]
\end{forest}
&
\begin{forest}
dir tree,
for tree = {
font=\ttfamily
}
[text 1
[text 2
[text 3
[text 4
[text 5.1
[text 6]
]
[text 5.2
]
]
]
]
]
\end{forest}
\end{tabular}
\end{document}
\documentclass[tikz,border=10pt]{standalone}
\usepackage{forest}
\begin{document}
\begin{forest}
for tree={
font=\sffamily,
line width=1pt,
grow'=0,folder},
[Rings
[Commutative\\ Rings
[Commutative Rings\\ with identity,name=cr
[Integer domains,l*=2,name=id]
]
]
[Rings\\ with unity,name=ru
[Division rings
[Fields,l*=2,name=fld]
]
]
]
\begin{scope}[line width=1pt]
\draw[-latex] (ru) -- (cr);
\draw[-latex] (id) -- (fld);
\end{scope}
\end{forest}
\end{document}