Tikz Mindmap 2 级对齐

Tikz Mindmap 2 级对齐

如何在我的思维导图中对齐 2 级节点(线条)。

\documentclass[border=10pt]{standalone}
\usepackage[condensed,math]{iwona}
\usepackage[T1]{fontenc}
\usepackage[dvipsnames,svgnames]{xcolor}
\usepackage{tikz}

\usetikzlibrary{mindmap,trees,positioning}
\tikzset{
set angles for level/.style={level #1/.append style={sibling angle=360/\the\tikznumberofchildren}},
level/.append style={set angles for level=#1}% solution 1
}
\tikzset{
non-concept/.style={
    rectangle,
    text width=15em,
    text=black,
    align=left,
    font=\large,
},
cncc east/.style={
    edge from parent path={
        (\tikzparentnode.east) to[out=0, in=180] (\tikzchildnode.south west)
        -- (\tikzchildnode.south east)
    }
}
}
\begin{document}
\pagestyle{empty}
\begin{tikzpicture}[level 1 concept/.append style={font=\large}, level 1 concept/.append style={
    level distance=150}]
\path[mindmap, concept color=Aquamarine]
node[concept] {ICF Core \\ Competencies}[clockwise from=45]
child[concept color=blue!20!white, text width=8em] {
    node[concept] (def) {Setting the Foundation}
    [grow=right, sibling distance=10ex, ]
    child[level distance=5cm] { node[non-concept] {Meeting Ethical Guidelines \& Professional Standards} edge from parent[cncc east] }
    child[level distance=5cm] { node[non-concept] {Establishing the Coaching Agreement} edge from parent[cncc east] }
}
child[concept color=Pink, text width=8em]  { node[concept] {Co-creating the \\ Relationship} 
    child[level distance=5cm] { node[non-concept] {Establishing Trust \& Intimacy with the Client} edge from parent[cncc east] }
    child[level distance=5cm] { node[non-concept] {Coaching Presence} edge from parent[cncc east] } 
   }
     child[concept color=Bisque, text width=8em]{ node[concept] {Communicating Effectively} 
     child[level distance=5cm] { node[non-concept] {Establishing Trust \& Intimacy with the Client} edge from parent[cncc east] }
     child[level distance=5cm] { node[non-concept] {Coaching Presence} edge from parent[cncc east] }    
     child[level distance=5cm] { node[non-concept] {Coaching Presence} edge from parent[cncc east] }    
 }
 child[concept color=Cyan, text width=8em]  { node[concept] {Facilitating Learning \& Results} 
    child[level distance=5cm] { node[non-concept] {Establishing Trust \& Intimacy with the Client} edge from parent[cncc east] }
    child[level distance=5cm] { node[non-concept] {Coaching Presence} edge from parent[cncc east] } 
    child[level distance=5cm] { node[non-concept] {Coaching Presence} edge from parent[cncc east] } 
    child[level distance=5cm] { node[non-concept] {Coaching Presence} edge from parent[cncc east] }     
};
\end{tikzpicture}
\end{document}

答案1

除非你比我更有耐心,否则我建议你放弃那些繁琐的事情,选择一些更简单的事情。

这是一个可能的开始:

\documentclass[border=10pt]{standalone}
\usepackage[condensed,math]{iwona}
\usepackage[T1]{fontenc}
\usepackage[dvipsnames,svgnames]{xcolor}
\usepackage{tikz}

\usetikzlibrary{mindmap,trees,positioning}
\tikzset{
  set angles for level/.style={level #1/.append style={sibling angle=360/(\the\tikznumberofchildren+4)}},
  level/.append code={
    \edef\tempa{#1}\edef\tempb{1}
    \ifx\tempa\tempb\tikzset{level 1/.append style={sibling angle=360/\the\tikznumberofchildren}}\else\tikzset{set angles for level=#1}\fi},
%     set angles for level=#1},% solution 1
  non-concept/.style={
    rectangle,
    text width=15em,
    text=black,
    align=left,
    font=\large,
  },
  cncc/.style={ edge from parent path={ (\tikzparentnode.#1) to [bend right] (\tikzchildnode)   } },
}
\begin{document}
\begin{tikzpicture}[level 1 concept/.append style={font=\large, level distance=150}]
  \path[mindmap, concept color=Aquamarine, grow cyclic]
  node[concept] {ICF Core \\ Competencies}%[clockwise from=45]
  child[concept color=blue!20!white] {
    node[concept] (def) {Setting the Foundation}
    child[level distance=5cm] { node[non-concept] {Meeting Ethical Guidelines \& Professional Standards} edge from parent[cncc=west] }
    child[level distance=5cm] { node[non-concept] {Establishing the Coaching Agreement} edge from parent[cncc=west] }
  }
  child[concept color=Pink]  { node[concept] {Co-creating the \\ Relationship} 
    child[level distance=5cm] { node[non-concept] {Establishing Trust \& Intimacy with the Client} edge from parent[cncc=south] }
    child[level distance=5cm] { node[non-concept] {Coaching Presence} edge from parent[cncc=south] } 
  }
  child[concept color=Bisque]{ node[concept] {Communicating Effectively} 
    [clockwise from=0]
    child[level distance=5cm] { node[non-concept] {Establishing Trust \& Intimacy with the Client} edge from parent[cncc=east] }
    child[level distance=5cm] { node[non-concept] {Coaching Presence} edge from parent[cncc=east] }    
    child[level distance=5cm] { node[non-concept] {Coaching Presence} edge from parent[cncc=south] }    
  }
  child[concept color=Cyan]  { node[concept] {Facilitating Learning \& Results} 
    [clockwise from=90]
    child[level distance=5cm] { node[non-concept] {Establishing Trust \& Intimacy with the Client} edge from parent[cncc=west] }
    child[level distance=5cm] { node[non-concept] {Coaching Presence} edge from parent[cncc=west] } 
    child[level distance=5cm] { node[non-concept] {Coaching Presence} edge from parent[cncc=north] } 
    child[level distance=5cm] { node[non-concept] {Coaching Presence} edge from parent[cncc=east] }     
  };
\end{tikzpicture}
\end{document}

更简单(但清晰易读)

相关内容