我使用“genealogytree”包已经很长时间了,但我再次为如何为我的堂兄弟建模而苦苦挣扎。
在我合并多个(已完成)家谱时遇到麻烦后(关联) 有 ~150 个节点,我开始从“超级婴儿”(最年轻的活着的一代以下)和“超级父母”(我想要建模的最老一代以上)进行建模。其中根是超级婴儿或超级祖父(我想要建模的最老一代中所有祖先的父亲)
通过“超级宝宝”的尝试,我可以模仿我的表兄弟,但我很难将我的叔叔融入我父亲的家庭。
对于“超级父母”,我也遇到了类似的麻烦。
是否有机会正确地塑造我的表兄弟?
\documentclass{article}
\usepackage[all]{genealogytree}
\usepackage[ngerman]{babel}
\usepackage{hyperref}
\usepackage{pdflscape}
\begin{document}
\thispagestyle{empty}
\begin{landscape}
\begin{tikzpicture}[scale=0.5,transform shape]
\genealogytree[]
{
parent{
g[box={colback=green!20!white}]{invisible superbaby}
parent{
g[male]{My Brother}
c[male,box={colback=yellow!80}]{Me}
parent{
g[female]{Mother}
parent{
g[female]{Grandmother (Mother)}
}
parent{
g[male]{Grandfather (Mother)}
}
}
parent{
g[male]{Father}
parent{
g[female]{Grandmother (Father)}
}
parent{
g[male]{Grandfather (Father)}
}
}
}
parent{
g[male]{Cousin 1}
c[male]{Cousin 2}
p[female]{Aunt}
p[male]{Uncle (Fathers Brother)}
}
}
}
\end{tikzpicture}
\end{landscape}
\end{document}
答案1
我找到了解决方法!我手动将我的叔叔编辑为我的父母家人:
add child=uncle to fam_grand,
这包括我祖父母职位的一个小问题,所以我必须自己手动调整它们:
代码:
\documentclass{article}
\usepackage[all]{genealogytree}
\usepackage[ngerman]{babel}
\usepackage{hyperref}
\usepackage{pdflscape}
\begin{document}
\thispagestyle{empty}
\begin{landscape}
\begin{tikzpicture}[scale=0.5,transform shape]
\genealogytree[
%add parent=grandma to fam_uncle
add child=uncle to fam_grand
]
{
parent{
g[box={colback=green!20!white}]{invisible superbaby}
parent{
g[male]{My Brother}
c[male,box={colback=yellow!80}]{Me}
parent[]{
g[female]{Mother}
parent{
g[female]{Grandmother (Mother)}
}
parent{
g[male]{Grandfather (Mother)}
}
}
parent[id=fam_grand,pivot shift=-2.4cm]{ %2.4cm = Node Size
g[male]{Father}
p[female]{Grandmother (Father)}
p[male]{Grandfather (Father)}
}
}
parent[id=fam_uncle]{
g[male]{Cousin 1}
c[male]{Cousin 2}
p[id=uncle,male]{Uncle (Fathers Brother)}
parent{
g[female]{Aunt}
p[female]{Aunts Mother}
p[male]{Aunts Father}
}
}
}
}
\end{tikzpicture}
\end{landscape}
\end{document}