我怎样才能解决这个问题?
\documentclass[margin=5mm]{standalone}
\usepackage[utf8]{inputenc}
\usepackage[edges]{forest}
\begin{document}
\begin{forest}
for tree={
l sep=1cm,
child anchor=north,
parent anchor=south,forked edges,
edge={->,>=latex}}
[Circuit Elements
[Active
[a
]
[a
]
]
[Passive
[b
]
[b
]
]
]
\end{forest}
\end{document}
答案1
forked edges
相当于for tree=forked edge
。因此,要么改为forked edges
,forked edge
要么将其移出 的范围for tree
。
\documentclass[border=10pt,multi,tikz]{standalone}
\usepackage[edges]{forest}
\begin{document}
\begin{forest}
for tree={
l sep=1cm,
child anchor=north,
parent anchor=south,
forked edge,
edge={->,>=latex},
}
[Circuit Elements
[Active
[a
]
[a
]
]
[Passive
[b
]
[b
]
]
]
\end{forest}
\end{document}