Tag Info

New answers tagged

2

You can draw the braces with a TikZ decoration. Admitted, they're ugly, but there's no need for a box raised to some arbitrary height. \usetikzlibrary{tikzmark,decorations,decorations.pathreplacing} \newcommand{\menge}[1]{% \begin{tikzpicture} \draw node(tree){\ignorespaces#1}; \draw [decorate,decoration=brace] (tree.south west) -- (tree.north west); ...


0

Braces for mathematical expressions are always symmetrical to the math baseline. Draw independent braces: \documentclass{article} \usepackage{forest} \usetikzlibrary{tikzmark} \begin{document} \begin{figure} \raisebox{2em}{$\left\{\rule{0pt}{2.75em}\right.$} \begin{forest} [VP [NP$\downarrow$] [\subnode{vp1}{VP}]] ...


4

May be fit=rectangle (page 29) is what you're looking for: \documentclass{standalone} \usepackage{forest} \forestset{ tag/.style={for tree={parent anchor=south, child anchor=north,align=center,base=top}}, % a style that creates an arrow pointing to the substitution node from a tree top node encoded as daughter ...


2

Seek help from adjustbox package with valign=m or c (t for top, b for bottom) does the objectives. Code \documentclass{minimal} \usepackage[export]{adjustbox} \usepackage{forest} \forestset{ tag/.style={for tree={parent anchor=south, child anchor=north, align=center, base=top}, where n children=0{}{}} } \begin{document} \hfill ...


2

Below, I used a trick shown in the big example in the forest manual (section 4.2) to parse the content of the node. Then, (i) an additional node is created just below the text and filled with the translation (i.e whatever comes after \\ in the original content) and (ii) the translation is deleted from the content. (This parsing mechanism is set to apply to ...


1

You can use the option edge path also documented at page 33. It contains the code that generates the edge. By default it is edge path={\noexpand\path[\forestoption{edge}](!u.parent anchor)--(.child anchor)\forestoption{edge label};} we can modify it (on a per-node basis) to produce an extra bit on top of the child: edge ...


5

You need to just set the name as they are arealdy nodes: \documentclass{article} \usepackage{forest} \forestset{ sn edges/.style={for tree={parent anchor=south, child anchor=north,align=center,base=bottom,where n children=0{tier=word}{}}}, } \begin{document} \begin{forest} sn edges [V{[\textit{fin,} SUBCAT $<>$]} [1 ...


4

I couldn't replicate the spacing issue around the SG, so this answer might not help you with that. The go.PSTpastpst issue is related to the usage of the obsolete glossaries commands \defglsdisplay and \defglsdisplayfirst in leipzig.sty. Here is what is in v1.0 of leipzig.sty: \newcommand*{\SetLeipzigDisplayStyle}[1]{% ...


1

I'm not entirely sure I understand the question. That is, I'm not sure why you want to avoid phantom so what the criteria are for an acceptable answer. However, the following does avoid phantom. Whether it does anything you consider equally obnoxious, I'm not so sure ;). \documentclass[border=5pt]{standalone} \usepackage{forest} \forestset{ dg ...


3

This solution uses a phantom node, and I know Stefan doesn't want it, but I don't know how to align (tier) first level children with a fifth level child if this doesn't exist. First example had a reference node but is missing in second one. Of course,I'm open to better solutions. \documentclass{article} \usepackage{forest} \forestset{ dg edges/.style={for ...


2

You do not need no edge in addition to phantom. You can align the two Ns by using another tier option: \documentclass{article} \usepackage{forest} \forestset{ dg edges/.style={% for tree={% parent anchor=south, child anchor=north, align=center, base=bottom, where n children=0{% tier=word, edge=dotted, ...


1

The calign with current edge option did the trick: \documentclass{article} \usepackage{forest} \forestset{ dg edges/.style={for tree={parent anchor=south, child anchor=north,align=center,base=bottom,where n children=0{tier=word,edge=dotted,calign with current edge}{}}}, } \begin{document} \begin{forest} dg edges [V [N [D [the] ] [child] ] ...


3

A bit kludgy, but shows how to specify a custom growth function and a sneaky way of duplicating the words at the bottom. I pinched a couple of styles from from Jesse's answer: \documentclass[tikz, border=5]{standalone} % An (incomplete) growth function \makeatletter \def\tikz@grow@tree{% \tikzset{shift=(270:\tikzleveldistance)}% ...


5

This is an attempt where tikz tree is used. To align the text at the bottom a dfont style is defined. Code \documentclass{article} \usepackage{tikz} \usetikzlibrary{shapes,trees,calc} \begin{document} \tikzset{ treenode/.style = {inner sep=0pt, outer sep=2pt, font=\sffamily}, edge from parent/.style={draw, edge from parent path= ...



Top 50 recent answers are included