9

2 questions really: in the following example I would like to 1) change the line spacing in the calendar 2) move the calendar to the left

I couldn't find the way to increase line spacing in calendar; I have tried \linespread in the document but it has no effect on calendar. And I haven't been able to move the days of the calendar any more to the left. I gave up!

This is the complete example, largely based on the .pgf document mindmap.

\documentclass{article}
%%%<
\usepackage{verbatim}
%%%>


\usepackage{tikz}
\usepackage[paperwidth=22cm,paperheight=29cm,left=0cm,top=0cm,bottom=0cm,right=0cm]{geometry}



\usetikzlibrary{%
backgrounds,%
trees,%
mindmap,%
calendar}


\begin{document}


\noindent
\begin{tikzpicture}[mindmap]
\begin{scope}[
every node/.style={concept, circular drop shadow={shadow scale=1.1, shadow xshift=.8ex, shadow yshift=-.3ex,
fill=black, path fading={circle with fuzzy edge 20 percent}, every shadow},
% execute at begin node=\hskip0pt
},
root concept/.append style={concept color=black, fill=white, line width=1ex, text=black, font=\Huge\scshape, minimum size=5cm},
text=white,
radio/.style={concept color=red,faded/.style={concept color=red!50}, minimum size=4cm},
ortho/.style={concept color=blue,faded/.style={concept color=blue!50}, minimum size=4cm},
rhumato/.style={concept color=orange,faded/.style={concept color=orange!50}, minimum size=4cm},
reeduc/.style={concept color=green!50!black,faded/.style={concept color=green!50!black!50}, minimum size=4cm},
grow cyclic,
level 1/.append style={level distance=6cm,sibling angle=90,font=\Large\scshape},
level 2/.append style={level distance=4.5cm,sibling angle=45,font=\normalsize}]
  \node[font=\bfseries, root concept, xshift=-4.3cm] (arteos) {ART\'eOS} % root
  child [radio,sibling angle=45] { node[yshift=-2cm, xshift=1cm] {\makebox[0pt]{{Radiologie}}}
    child [minimum size=2.5cm] { node {{Imagerie\\fonctionnelle}}}
    child [minimum size=2.8cm] { node {{Radiographie\\inter-ventionnelle}}}
    child [minimum size=2cm] { node {{EOS}}}
  }
  child [ortho] { node[yshift=-0.5cm, xshift=-1cm] {\makebox[0pt]{{Orthop\'edie}}}
    child [minimum size=2.5cm] { node (o_perf) {\makebox[0pt]{Performance}}}
    child [minimum size=2.2cm] { node (o_mat) {{Tribologie}}}
    child [minimum size=2.8cm] { node (o_art) {\makebox[0pt]{Arthroplasties}}}
    child [minimum size=2cm] { node (o_fra) {{Fractures}}}
  }
  child [rhumato] { node[yshift=+3cm, xshift=-1cm] {\makebox[0pt]{{Rhumatologie}}}
    child [minimum size=2.5cm] { node (rh_epid) {\makebox[0pt]{Epid\'emiologie}}}
    child [minimum size=2.5cm] { node (rh_infla) {{Maladies\\inflam-matoires}}}
    child [minimum size=2.5cm] { node (rh_auto) {{Maladies\\ auto-immunes}}}
    child [minimum size=2.5cm] { node (rh_ost) {\makebox[0pt]{Ost\'eoporose}}}
  }
  child [reeduc] { node[yshift=+1cm, xshift=+0.5cm] {\makebox[0pt]{{R\'e\'education}}}
    child [minimum size=2.5cm] { node (re_rea) {\makebox[0pt] {R\'eadaptation}}}
    child [minimum size=2.1cm] { node (re_han) {{Handicap}}}
    child [minimum size=2.2cm] { node (re_eva) {{Evaluation}}}
    child [minimum size=2.5cm] { node (re_ree) {\makebox[0pt]{R\'e\'education}}}
    child [minimum size=2cm] { node (re_exe) {{Exercices}}}
  };

\end{scope}

\tiny
\calendar [day list downward,
      month text=\% mt\ \%y0,
      month yshift=1.5em,
      name=cal,
      at={(-0.5\textwidth -2cm,0.5\textheight-2cm)},
      dates=2012-11-01 to 2013-01-last]
if (weekend)
[black!25]
if (day of month=1) {
\node at (-2cm,1.5em) [anchor=base west] {\Large\tikzmonthtext};
};


\begin{pgfonlayer}{background}
  \clip[xshift=-6cm, yshift=2cm] (-.5\textwidth,-.5\textheight) rectangle ++(\textwidth,\textheight);
  \colorlet{upperleft}{green!50!black!25}
  \colorlet{upperright}{orange!25}
  \colorlet{lowerleft}{red!25}
  \colorlet{lowerright}{blue!25}
  % The large rectangles:
  \fill [upperleft] (arteos) rectangle ++(-20,20);
  \fill [upperright] (arteos) rectangle ++(20,20);
  \fill [lowerleft] (arteos) rectangle ++(-20,-20);
  \fill [lowerright] (arteos) rectangle ++(20,-20);
  % The shadings:
  \shade [left color=upperleft,right color=upperright]
    ([xshift=-1cm]arteos) rectangle ++(2,20);
  \shade [left color=lowerleft,right color=lowerright]
    ([xshift=-1cm]arteos) rectangle ++(2,-20);
  \shade [top color=upperleft,bottom color=lowerleft]
    ([yshift=-1cm]arteos) rectangle ++(-20,2);
  \shade [top color=upperright,bottom color=lowerright]
    ([yshift=-1cm]arteos) rectangle ++(20,2);
\end{pgfonlayer}
\end{tikzpicture}


\end{document}

Any help welcome, and thanks all for the really helpful posts on the website.

Cheers,enter image description here

5
  • Does this example compile for you? It seems to be missing some tikz packages. Oct 3, 2012 at 19:49
  • Yes it does. Don't see why it should not work on yours. Maybe it's my outdated version of Tikz (see chat room unfortunately). If anybody knows how to add a layer on top of the whole page so that the above code could be more transparent and I could write on top of it... it would be kind of perfect. But I have to admit I haven't looked at that yet. Cheers,
    – jejuba
    Oct 3, 2012 at 19:55
  • How can I add the pdf file? If that helps,
    – jejuba
    Oct 3, 2012 at 20:01
  • When I try to run it, /tikz/circular drop shadow is not known, so I add the shadows tikz library. Then it does not know /tikz/angle... You can upload an image if you edit your question via the icon that looks like a picture. But I would need to be able to compile it as I don't know much about the tikz calendar library. Oct 3, 2012 at 20:06
  • Done. I don't know why it would not work for you. However, I managed to get half of my answers. By adding day yshift={0.013\textheight} to the calendar options, it spreads the days out. However, i still get stuck with moving the whole calendar to the right and to the top. It doesn't work. It's probably related to the margins but I have set 0 margins in the geometry package. Any idea how to move this calendar?
    – jejuba
    Oct 3, 2012 at 20:38

1 Answer 1

10

Here is a manually adjusted example. Most of the complications came from supplying the mindmap option to the TikZ picture instead of a scope and also using \tiny a little improperly (inside the TikZ environment, TikZ rulaz!).

\documentclass{article}
\usepackage{tikz}
\usepackage[paperwidth=22cm,paperheight=29cm,left=0cm,top=0cm,bottom=0cm,right=0cm]{geometry}

\usetikzlibrary{backgrounds,trees,mindmap,calendar,shadows}
\begin{document}

\noindent
\begin{tikzpicture}
\begin{scope}[yshift=2cm,mindmap,
every node/.style={concept, circular drop shadow={shadow scale=1.1, shadow xshift=.8ex, shadow yshift=-.3ex,
fill=black, path fading={circle with fuzzy edge 20 percent}, every shadow},
% execute at begin node=\hskip0pt
},
root concept/.append style={concept color=black, fill=white, line width=1ex, text=black, font=\Huge\scshape, minimum size=5cm},
text=white,
radio/.style={concept color=red,faded/.style={concept color=red!50}, minimum size=4cm},
ortho/.style={concept color=blue,faded/.style={concept color=blue!50}, minimum size=4cm},
rhumato/.style={concept color=orange,faded/.style={concept color=orange!50}, minimum size=4cm},
reeduc/.style={concept color=green!50!black,faded/.style={concept color=green!50!black!50}, minimum size=4cm},
grow cyclic,
level 1/.append style={level distance=6cm,sibling angle=90,font=\Large\scshape},
level 2/.append style={level distance=4.5cm,sibling angle=45,font=\normalsize}]
  \node[font=\bfseries, root concept, xshift=-4.3cm] (arteos) {ART\'eOS} % root
  child [radio,sibling angle=-135] { node[yshift=-2cm, xshift=1cm] {\makebox[0pt]{{Radiologie}}}
    child [minimum size=2.5cm] { node {{Imagerie\\fonctionnelle}}}
    child [minimum size=2.8cm] { node {{Radiographie\\inter-ventionnelle}}}
    child [minimum size=2cm] { node {{EOS}}}
  }
  child [ortho] { node[yshift=-0.5cm, xshift=-1cm] {\makebox[0pt]{{Orthop\'edie}}}
    child [minimum size=2.5cm] { node (o_perf) {\makebox[0pt]{Performance}}}
    child [minimum size=2.2cm] { node (o_mat) {{Tribologie}}}
    child [minimum size=2.8cm] { node (o_art) {\makebox[0pt]{Arthroplasties}}}
    child [minimum size=2cm] { node (o_fra) {{Fractures}}}
  }
  child [rhumato] { node[yshift=+3cm, xshift=-1cm] {\makebox[0pt]{{Rhumatologie}}}
    child [minimum size=2.5cm] { node (rh_epid) {\makebox[0pt]{Epid\'emiologie}}}
    child [minimum size=2.5cm] { node (rh_infla) {{Maladies\\inflam-matoires}}}
    child [minimum size=2.5cm] { node (rh_auto) {{Maladies\\ auto-immunes}}}
    child [minimum size=2.5cm] { node (rh_ost) {\makebox[0pt]{Ost\'eoporose}}}
  }
  child [reeduc] { node[yshift=+1cm, xshift=+0.5cm] {\makebox[0pt]{{R\'e\'education}}}
    child [minimum size=2.5cm] { node (re_rea) {\makebox[0pt] {R\'eadaptation}}}
    child [minimum size=2.1cm] { node (re_han) {{Handicap}}}
    child [minimum size=2.2cm] { node (re_eva) {{Evaluation}}}
    child [minimum size=2.5cm] { node (re_ree) {\makebox[0pt]{R\'e\'education}}}
    child [minimum size=2cm] { node (re_exe) {{Exercices}}}
  };
\end{scope}
\begin{scope}[shift={(-7cm,7.2cm)},scale=0.65,transform shape]
\calendar [day list downward,font=\small,
      month text=\% mt\ \%y0,
      month yshift=1.5em,
      name=cal,
      at={(-0.5\textwidth -2cm,0.5\textheight-2cm)},
      dates=2012-11-01 to 2013-01-last]
if (weekend)
[black!25]
if (day of month=1) {
\node at (-2cm,1.5em) [anchor=base west] {\Large\tikzmonthtext};
};

\end{scope}

\begin{scope}[on background layer]
  \clip[xshift=-6cm, yshift=2cm] (-.5\textwidth,-.5\textheight) rectangle ++(\textwidth,\textheight);
  \colorlet{upperleft}{green!50!black!25}
  \colorlet{upperright}{orange!25}
  \colorlet{lowerleft}{red!25}
  \colorlet{lowerright}{blue!25}
  % The large rectangles:
  \fill [upperleft] (arteos) rectangle ++(-20,20);
  \fill [upperright] (arteos) rectangle ++(20,20);
  \fill [lowerleft] (arteos) rectangle ++(-20,-20);
  \fill [lowerright] (arteos) rectangle ++(20,-20);
  % The shadings:
  \shade [left color=upperleft,right color=upperright]
    ([xshift=-1cm]arteos) rectangle ++(2,20);
  \shade [left color=lowerleft,right color=lowerright]
    ([xshift=-1cm]arteos) rectangle ++(2,-20);
  \shade [top color=upperleft,bottom color=lowerleft]
    ([yshift=-1cm]arteos) rectangle ++(-20,2);
  \shade [top color=upperright,bottom color=lowerright]
    ([yshift=-1cm]arteos) rectangle ++(20,2);
\end{scope}
\end{tikzpicture}


\end{document}

enter image description here

1
  • Thanks very much. It works fine. Probably because I run an outdate version of Tikz (still haven't worked out how to have my competing install of tkiz 2012 work with the other one I have, but that's another story), I had to change \begin{scope}[on background layer] to \begin{pgfonlayer}{background}. Otherwise, great. Tx again,
    – jejuba
    Oct 4, 2012 at 14:44

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .