[Tex/LaTex] Bug (?) in color of connection bars in TikZ mindmap

mindmapstikz-pgf

I have the following figure, with the code below:

Example of minmap

\documentclass{standalone} 
\usepackage{tikz}
\usetikzlibrary{mindmap}

\begin{document}

\begin{tikzpicture}[small mindmap]
\node[concept, concept color=green] {Green\\node}
child[concept color=blue, grow=-65] {
    node[concept] {Blue\\Node\\2}
    child[concept color=red, grow=-60] { node[concept] {Red\\Node\\3} }
    child[concept color=red, grow=-120] { node[concept] (r) {Red\\Node\\2} }
}
child[concept color=blue, grow=-120] {
    node[concept] (b) {Blue\\Node\\1}
    child[concept color=red, grow=-120] { node[concept] {Red\\Node\\1} }
};
\path (b) to[circle connection bar switch color=from (blue) to (red)] (r);
\end{tikzpicture}

\end{document}

Main question: Why is the color of the connection bars between the green node and the blue nodes incorrect? And how to correct this?

Side question: My way of placing the Red Node 2 as a child of Blue Node 2 and then connect it as I can to Blue Node 1 is kind of a ugly hack. How should one code this more properly?

Side side question: There is some rough description of the mindmap library in the Beamer user guide, but I have been unable to find some complete documentation. Does it exist?

Best Answer

Setting concept color=green as a node option does not effect the connection to the first level children. Use it as an option of the tikzpicture.

\begin{tikzpicture}[mindmap,concept color=green]

You could place the Red Node 2 as an extra concept of level 2 in the middle of the Red Node 1 and Red Node 3. If you name the node the children will automatically be named.

\documentclass{standalone} 
\usepackage{tikz}
\usetikzlibrary{mindmap}

\begin{document}

\begin{tikzpicture}[mindmap,concept color=green]
\node[concept](mm) {Green\\node}
child[concept color=blue, grow=-60] {
    node[concept] {Blue\\Node\\2}
    child[concept color=red, grow=-60] { node[concept] {Red\\Node\\3} }
    %child[concept color=red, grow=-120] { node[concept] (r) {Red\\Node\\2} }
}
child[concept color=blue, grow=-120] {
    node[concept] {Blue\\Node\\1}
    child[concept color=red, grow=-120] { node[concept] {Red\\Node\\1} }
};

\node[extra concept,level 2 concept,concept color=red](mm-1-1e2)at(mm|-mm-1-1){Red\\Node\\2};

\foreach \i in {1,2}
  \path (mm-\i) to[circle connection bar switch color=from (blue) to (red)] (mm-1-1e2);
\end{tikzpicture}

\end{document}

enter image description here

There is a chapter "Mindmap Drawing Library" inside the pgfmanual.

Related Question