This is my first post on any kind of internet forum. I'm writing a report with LaTeX and would like to use TikZ for some diagrams, including a timeline with labels attached. I would like to have branches coming off the main, horizontal, line at an angle of 30deg or so, and to label each with one or two words of text PARALLEL to the branch, i.e. also rotated.
Using the following lines I can draw a timeline with an angled branch, labelled in the middle, but the text is not properly rotated:
Code: Select all
\documentclass{article}
\usepackage{tikz}
\begin{document}
% draw a timeline
\begin{tikzpicture}
% draw horizontal line
\draw (0,0) --(10,0);
% draw vertical lines
\foreach \x in {0,0.5,1.0,1.5,2.0,2.5,3.0,3.5,4.0,4.5,5.0,5.5,6.0,6.5,7.0,7.5,8.
0,8.5,9.0,9.5,10.0}
\draw(\x cm,3pt) -- (\x cm,-3pt);
% put in dates
\draw (0,0) node[below=3pt] {$ 1990 $} node[above=3pt] {$ $};
\draw (2.5,0) node[below=3pt] {$ 1995 $} node[above=3pt] {$ $};
\draw (5,0) node[below=3pt] {$ 2000 $} node[above=3pt] {$ $};
\draw (7.5,0) node[below=3pt] {$ 2005 $} node[above=3pt] {$ $};
\draw (10,0) node[below=3pt] {$ 2010 $} node[above=3pt] {$ $};
% have a go at attaching lines, and rotating them
\draw [rotate around={30:(0,0)}] (0,0) -- (1.5,0) node {first paper} -- (3,0);
\end{tikzpicture}
\end{document}
Best,
Daniel.