I'm trying to draw a large family/directory tree using tikz-tree. I've found this question in Stackexchange, which almost works, but not quite. Using the code provided in the answer I get overlapping text when my tree is sufficiently large. If I don't use the tighter intendation, nodes do not overlap, but I don't get wanted intendation (and the tree becomes too wide).
Example for clarity
\documentclass[11pt,a4paper]{report}
\usepackage[utf8]{inputenc}
\usepackage{tikz}
\makeatletter
\newcount\dirtree@lvl
\newcount\dirtree@plvl
\newcount\dirtree@clvl
\def\dirtree@growth{%
\ifnum\tikznumberofcurrentchild=1\relax
\global\advance\dirtree@plvl by 1
\expandafter\xdef\csname dirtree@p@\the\dirtree@plvl\endcsname{\the\dirtree@lvl}
\fi
\global\advance\dirtree@lvl by 1\relax
\dirtree@clvl=\dirtree@lvl
\advance\dirtree@clvl by -\csname dirtree@p@\the\dirtree@plvl\endcsname
\pgf@xa=1cm\relax
\pgf@ya=-0.5cm\relax
\pgf@ya=\dirtree@clvl\pgf@ya
\pgftransformshift{\pgfqpoint{\the\pgf@xa}{\the\pgf@ya}}%
\ifnum\tikznumberofcurrentchild=\tikznumberofchildren
\global\advance\dirtree@plvl by -1
\fi
}
\tikzset{
dirtree/.style={
growth function=\dirtree@growth,
growth parent anchor=south west,
parent anchor=south west,
every child node/.style={anchor=west},
edge from parent path={([xshift=2ex] \tikzparentnode\tikzparentanchor) |- (\tikzchildnode\tikzchildanchor)}
}
}
\tikzset{
dirtreemid/.style={
growth function=\dirtree@growth,
every node/.style={anchor=north},
every child node/.style={anchor=west},
edge from parent path={(\tikzparentnode\tikzparentanchor) |- (\tikzchildnode\tikzchildanchor)}
}
}
\makeatother
\begin{document}
\begin{tikzpicture}[dirtree]
\node {Maria}
child { node {Fuu}
child { node {Lii}
child { node {Lee}
child { node {Loo} }
child { node {Luu} }
}
child { node {Overlap}
child { node { Kim} }
child { node { Jou} }
}
}
child { node {Long text here}
}
}
child { node {Foo} };
\end{tikzpicture}
\\ \\
\begin{tikzpicture}[dirtreemid]
\node {Maria}
child { node {Fuu}
child { node {Lii}
child { node {Lee}
child { node {Loo} }
child { node {Luu} }
}
child { node {Overlap}
child { node { Kim} }
child { node { Jou} }
}
}
child { node {Long text here}
}
}
child { node {Foo} };
\end{tikzpicture}
\end{document}'
And for the reference image I get with the above code. What I'd like to have is the node indentation of the first image without overlapping of nodes.

Any help is greatly appreciated!

