diff options
Diffstat (limited to 'Master/texmf-dist/tex/xelatex/langsci/langsci-forest-setup.sty')
-rw-r--r-- | Master/texmf-dist/tex/xelatex/langsci/langsci-forest-setup.sty | 44 |
1 files changed, 21 insertions, 23 deletions
diff --git a/Master/texmf-dist/tex/xelatex/langsci/langsci-forest-setup.sty b/Master/texmf-dist/tex/xelatex/langsci/langsci-forest-setup.sty index 2d8d0571582..49e0a854caa 100644 --- a/Master/texmf-dist/tex/xelatex/langsci/langsci-forest-setup.sty +++ b/Master/texmf-dist/tex/xelatex/langsci/langsci-forest-setup.sty @@ -1,11 +1,11 @@ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% File: langsci-forest-setup.sty %% Author: Language Science Press (http://langsci-press.org) -%% Date: 2016-01-16 16:47:43 UTC -%% Purpose: This file contains optional styles and settings for the +%% Date: 2016-01-16 16:47:43 UTC +%% Purpose: This file contains optional styles and settings for the %% forest package. This version is for 2.0. %% Language: LaTeX -%% Licence: +%% Licence: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% @@ -13,10 +13,12 @@ % a workaround is to use a different pgf driver. % See email from Akira Kakuto to Stefan Müller 15.01.2016 +% Do we need this for 2017? +% We seem to be better off without it 31.10.2017 %deceive the driver -\def\pdftexversion{140} +%\def\pdftexversion{140} %use the old driver for dvipdfm -\def\pgfsysdriver{pgfsys-dvipdfm.def} +%\def\pgfsysdriver{pgfsys-dvipdfm.def} % http://en.wikibooks.org/wiki/LaTeX/Linguistics#Syntactic_trees \usepackage{tikz-dependency} @@ -31,31 +33,26 @@ % does not work with forest v1.05 did not check later versions -\usepackage[external]{forest} -\tikzset{external/up to date check=simple} +\usepackage[external,linguistics]{forest} +\tikzset{external/up to date check=simple} % for texlive: -shell-escape, for miktex -enable-write18 % All externalized graphics go go the \externaldirectory %\tikzexternalize[prefix=external-figures/,shell escape=-shell-escape] \tikzset{external/system call={xelatex \tikzexternalcheckshellescape -halt-on-error -interaction=batchmode -jobname "\image" "\texsource"}} %\usepackage{morewrites} -%\usepackage{forest} -% for forest version2 -\useforestlibrary{linguistics} -\forestapplylibrarydefaults{linguistics} - % specification for all trees, "default preamble" appends to existing specification. % The version with apostrophe replaces it. \forestset{default preamble'={ - for tree={align=center,parent anchor=south, child anchor=north,base=bottom}, + for tree={align=center,parent anchor=south, child anchor=north,anchor=north,base=bottom}, before drawing tree={ sort by=y, for min={tree}{baseline} } - }} + }} \forestset{ @@ -81,7 +78,7 @@ % http://www.texample.net/tikz/examples/borrowers-and-lenders/ -\usetikzlibrary{arrows} %,positioning} +\usetikzlibrary{arrows} %,positioning} \tikzset{ %Define standard arrow tip >=stealth'} @@ -89,7 +86,7 @@ %% \forestset{ -%% sn edges/.style={for tree={parent anchor=south, child anchor=north,align=center,base=bottom,where n children=0{tier=word}{}}}, +%% sn edges/.style={for tree={parent anchor=south, child anchor=north,align=center,base=bottom,where n children=0{tier=word}{}}}, %% background tree/.style={for tree={text opacity=0.2,draw opacity=0.2,edge={draw opacity=0.2}}} %% } @@ -103,14 +100,15 @@ l sep=0,inner xsep=0, append translation/.expanded/.wrap pgfmath arg={\gettranslation{##1}}{content}, content/.expanded/.wrap pgfmath arg={\gettext{##1}}{content}, - }, + }, append translation/.style={ if={strequal("#1","")}{}{ append={[#1,no edge,inner xsep=0,inner ysep=0,outer ysep=0, + tier=gloss, l=\baselineskip + 0.2ex, ]} } - } + } } \def\gettext#1{\gettextA#1;;\endget} @@ -124,7 +122,9 @@ % to do: make this style default and change all other figures explicitely as is described here: % http://tex.stackexchange.com/questions/167983/getting-rid-of-a-default-where-specification \forestset{ -sm edges/.style={for tree={parent anchor=south, child anchor=north,base=bottom}, +sm edges/.style={for tree={parent anchor=south, child anchor=north,base=top}, % changed base=bottom + % to top since we have NP and AVM nodes and the NP has to start + % right away at the same hight as the AVM St. Mü. 18.10.2017 where n children=0{tier=word,delay=with translation}{} %,delay=with translation }, sm edges without translation/.style={for tree={parent anchor=south, child anchor=north,base=bottom}, @@ -196,7 +196,7 @@ dg junction/.style={no edge, tikz+={\draw (!p.east)--(!.west) (.east)--(!n.west) % % TAG % http://tex.stackexchange.com/questions/207459/getting-old-school-trees-with-forest -% fit -> fit=band causes all nodes to have nothing below them +% fit -> fit=band causes all nodes to have nothing below them tag/.style={for tree={parent anchor=south, child anchor=north,align=center,base=top,fit=rectangle}, where n children=0{delay=with translation}{}, % the following breaks the alignments in sets @@ -207,7 +207,7 @@ tag/.style={for tree={parent anchor=south, child anchor=north,align=center,base= no word baseline/.style={for tree={parent anchor=south, child anchor=north,align=center,base=top}, where n children=0{delay=with translation}{}}, % -% a style that creates an arrow pointing to the substitution node from a tree top node encoded as daughter +% a style that creates an arrow pointing to the substitution node from a tree top node encoded as daughter substitution/.style={edge={<-,dashed},l+=\baselineskip}, % % @@ -238,5 +238,3 @@ instance/.style={edge=dotted}, delay={where content={}{shape=coordinate,for siblings={anchor=north}}{}} } } - - |