Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Using the answer I got to this question, I have a mindmap with 6 children, each with 2-5 children of their own.

MWE:

% Author: Till Tantau
% Source: The PGF/TikZ manual
\documentclass{article}

\usepackage{tikz}
\usetikzlibrary{mindmap,trees}

\begin{document}
\resizebox{!}{4 in}{%
   \begin{tikzpicture}
      \path[
         mindmap,
         concept color=black,
         text=white,
         grow cyclic,
         segment length=20cm
      ]
      node[concept] {Main}
      [clockwise from=0]
      child[concept color=green!50!black] {%
         node[concept] {A}
         [clockwise from=65]
         child {node[concept] {A1} }
         child {node[concept] {A2} }
         child {node[concept] {A3} }
      }  
      child[concept color=blue] {%
         node[concept] {B}
         [clockwise from=-20]
         child {node[concept] {B2} }
         child {node[concept] {B3} }
      }
      child[concept color=red] {%
         node[concept] {C}
         [clockwise from=5]
         child {node[concept] {C1} }
         child {node[concept] {C2} }
         child {node[concept] {C3} }
         child {node[concept] {C4} }
         child {node[concept] {C5} }
      }
      child[concept color=orange] {%
         node[concept] {D}
         [clockwise from=-145]
         child {node[concept] {D1} }
         child {node[concept] {D2} }
      }
      child[concept color=magenta] {%
         node[concept] {E}
         [clockwise from=-180]
         child {node[concept] {E1} }
         child {node[concept] {E2} }
         child {node[concept] {E3} }
      }
      child[concept color=brown] {%
         node[concept] {F}
         [clockwise from=-245]
         child {node[concept] {F1} }
         child {node[concept] {F2} }
         child {node[concept] {F3} }
         child {node[concept] {F4} }
      };
   \end{tikzpicture}
}
\end{document}

Output:

enter image description here

Problem: I need the level 1 children (A-F) to be farther away from the parent (MAIN) as even now, F is too close to A and F3 is overlapping with A1. Furthermore, if I want each level 1 child to have 5 or 6 children of their own, then there will be serious overlap. How do I go about increasing the sibling distance on a per child/node, or at least a per level basis.

share|improve this question

1 Answer 1

You can use level distance=<length> and/or sibling angle=<value> inside level <number>/.append style to customize the distance and angle for an specific level. A complete example:

\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{mindmap,trees}

\begin{document}
\resizebox{!}{4 in}{%
   \begin{tikzpicture}
      \path[
         mindmap,
         concept color=black,
         text=white,
         grow cyclic,
         segment length=20cm,
level 1/.append style={level distance=8cm,sibling angle=60},
level 2/.append style={level distance=2.5cm},
      ]
      node[concept] {Main}
      [clockwise from=0]
      child[concept color=green!50!black] {%
         node[concept] {A}
         [clockwise from=30]
         child {node[concept] {A1} }
         child {node[concept] {A2} }
         child {node[concept] {A3} }
         child {node[concept] {A4} }
         child {node[concept] {A5} }
         child {node[concept] {A6} }
      }  
      child[concept color=blue] {%
         node[concept] {B}
         [clockwise from=30]
         child {node[concept] {B1} }
         child {node[concept] {B2} }
         child {node[concept] {B3} }
         child {node[concept] {B4} }
         child {node[concept] {B5} }
         child {node[concept] {B6} }
      }
      child[concept color=red] {%
         node[concept] {C}
         [clockwise from=30]
         child {node[concept] {C1} }
         child {node[concept] {C2} }
         child {node[concept] {C3} }
         child {node[concept] {C4} }
         child {node[concept] {C5} }
         child {node[concept] {C6} }
      }
      child[concept color=orange] {%
         node[concept] {D}
         [clockwise from=30]
         child {node[concept] {D1} }
         child {node[concept] {D2} }
         child {node[concept] {D3} }
         child {node[concept] {D4} }
         child {node[concept] {D5} }
         child {node[concept] {D6} }
      }
      child[concept color=magenta] {%
         node[concept] {E}
         [clockwise from=30]
         child {node[concept] {E1} }
         child {node[concept] {E2} }
         child {node[concept] {E3} }
         child {node[concept] {E4} }
         child {node[concept] {E5} }
         child {node[concept] {E6} }
      }
      child[concept color=brown] {%
         node[concept] {F}
         [clockwise from=30]
         child {node[concept] {F1} }
         child {node[concept] {F2} }
         child {node[concept] {F3} }
         child {node[concept] {F4} }
         child {node[concept] {F5} }
         child {node[concept] {F6} }
      };
   \end{tikzpicture}
}
\end{document}

enter image description here

share|improve this answer
    
level 1/.append style={level distance=8cm} was what I was looking for, thank you –  puk Jun 17 '13 at 21:01
    
Also, I don't know if you should use level 1/.append style={sibling angle=60} with grow cyclic –  puk Jun 17 '13 at 21:01
    
do you know how you could make it specific to only certain children? –  puk Jun 17 '13 at 21:02
    
@puk As far as I know, sibling angle was designed to be used with grow cyclic (see page 476 of the PGF manual). –  Gonzalo Medina Jun 17 '13 at 21:06
    
@puk I don't know if it's possible to use options to affect just some children and not the whole level. –  Gonzalo Medina Jun 17 '13 at 21:10

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.