New answers tagged

3

Small variation of the @hpekristiansen first answer: \documentclass[border=3.141592]{standalone} \usepackage[edges]{forest} \begin{document} \begin{forest} for tree={ % common nodes style draw, thick, rounded corners, % styles man/.style = {fill=cyan!30}, woman/.style = {fill=teal!30}, % tree forked edge, edge = {-, semithick}, ...


2

I do not know much about forest, so I do not know if it is possible. It seems that forked edges move the edge anchor to one point. A possibility is to have no edge and then draw it afterwards, like this: \documentclass[border=10pt]{standalone} \usepackage[edges]{forest} \begin{document} \begin{forest} man/.style = {fill=blue!70}, ...


5

Like this? This is relatively easy by use of the forest package: \documentclass[border=3.14159mm]{standalone} \usepackage{forest} \begin{document} \begin{forest} for tree={ % nodes minimum width = 4em, delay = {where content={}{shape=coordinate}{}, % tree calign=fixed edge angles, calign angle=60, grow=north, ...


1

I got the following answer from @qpheevr on Twitter. \begin{document} \begin{forest} [\textsf{Supplement}\\NP,s sep=-2em [\phantom{X}\hspace*{-4em},tier=dh] [\textsf{Determiner-Head}\\DP,no edge,tier=dh [\textsf{Head}\\D [\textit{which}] ] ] [\textsf{Head}\\Nom [\hspace*{-4em}\phantom{X},tier=dh] ] ] \end{forest} \end{document}


3

Alignment of children with respect to their parent is controlled by key calign, which is given to the parent node. In OP's case, we want the first child to be aligned to the parent, so we say calign=first. (I took the liberty to reformat a bit, as OP's l* leads to problems by pushing the DP too much down.) \documentclass{article} \usepackage[linguistics]{...


2

You need to add fit=tight for DDDD node \documentclass{article} \usepackage[edges]{forest} \usetikzlibrary{shadows} \usepackage{array} \newcolumntype{C}[1]{>{\centering}p{#1}} \begin{document} \scalebox{0.8}{ \forestset{% rect/.append style={rectangle, rounded corners=2pt}, dir tree switch/.style args={at #1}{% for tree={ fit=rectangle, ...


1

Although forest is a nice package for sure. However, in case you need to fine-turning things, plain TikZ is an easy way to control things as you wish. \documentclass[tikz,border=5mm]{standalone} \begin{document} \begin{tikzpicture} \def\a{2} \def\b{2.2} \path[nodes={minimum size=15mm,draw,thick,text=red}] (0,0) node (A) {AAAA} (0,-\b) node (D) {DDDD} (\a,-\...


5

A simple code with pstricks: \documentclass{article} \usepackage{pst-node, multido} \begin{document} \[ \begin{array}{c} \rnode{C}{5x^3} \\ \\ \rnode{F0}{5}\, \Rnode{F1}{x}\, \Rnode{F2}{x}\, \Rnode{F3}{x} \end{array} \psset{nodesep=2pt, linewidth=0.5pt, arrowinset=0.2, linejoin=1} \multido{\i =0+1}{4}{\ncline{-&...


9

The context of use the showed image is not entirely clear, so see if the following image is what you after. The MWE, which produce it, is: \documentclass[border=3.141592]{standalone} \usepackage{tikz} \usetikzlibrary{arrows.meta, calc, chains, positioning} \begin{document} \begin{tikzpicture}[ node distance = 7mm and 0mm,...


Top 50 recent answers are included