# \tkzDrawLine doesn't print node

I've made this drawing, but I can manage to place the node $m$ to the line. Any suggestions? Thanks in advance

\documentclass[a4paper]{article}
\usepackage{pgfplots}
\usepackage{tkz-euclide}
\usetkzobj{all}
\begin{document}
\begin{center}
\begin{tikzpicture}
\coordinate (M) at (0,0) ;
\coordinate (A) at (canvas polar cs:angle=90,radius=3cm);
\coordinate (B) at (canvas polar cs:angle=20,radius=3cm) ;
\draw (M) circle (3cm);
\draw (A) -- (B) ;
\tkzDefMidPoint(A,B) \tkzGetPoint{P}
\draw (A) -- (P) node[midway,sloped] {$//$} ;
\draw (P) -- (B) node[midway,sloped] {$//$} ;
\tkzDrawLine[add = 0.5 and 1.6](P,M) node {m}; %PROBLEM%
\tkzDrawPoints(A,B,M);
\tkzLabelPoints(B,M);
\tkzLabelPoints[above](A);
\end{tikzpicture}
\end{center}
\end{document}

-
The node {m}; text is not part of a TikZ path. You will place the node manually or use one of the \tkz… macros or options for that. – Qrrbrbirlbel Aug 26 '13 at 11:35
@macmadness86 ... It is marked in the code... %PROBLEM% ;-) – Arne Timperman Aug 26 '13 at 11:43
@Arne You can use \tkzDrawLine[add = 0.5 and 1.6, start=m, start style={midway}](P,M) (or end instead of start). Usually those two nodes default to at start (= pos = 0) and at end (= pos = 1) but you can overwrite this with the … style keys. – Qrrbrbirlbel Aug 26 '13 at 12:29
In general tkz commands do not have ; in the end – percusse Aug 26 '13 at 13:06
You can't accept comments, but I'm sure @Qrrbrbirlbel will write an answer as soon as he has time. – Torbjørn T. Aug 26 '13 at 13:44

The macros of the tkz-* packages are all wrappers around TikZ paths. A simple node {m}; is therefore not part of any path (like every ; after any of the \tkz* macros).

The \tkzDrawLine macro provides the keys

• start,
• end,
• start style and
• end style

to add nodes to the path, the * style can be used to apply another position besides at start and at end.

In this example, I have used near start to show the affect:

\tkzDrawLine[add = 0.5 and 1.6, start=$m$, start style={near start}](P,M)


## Code

\documentclass[tikz,convert=false]{standalone}
\usepackage{tkz-euclide}
\begin{document}
\begin{tikzpicture}
\coordinate (M) at (0,0) ;
\coordinate (A) at (canvas polar cs:angle=90,radius=3cm);
\coordinate (B) at (canvas polar cs:angle=20,radius=3cm) ;
\draw (M) circle (3cm);
\draw (A) -- (B) ;
\tkzDefMidPoint(A,B) \tkzGetPoint{P}
\draw (A) -- (P) node[midway,sloped] {$//$} ;
\draw (P) -- (B) node[midway,sloped] {$//$} ;
\tkzDrawLine[add = 0.5 and 1.6, start=$m$, start style={near start}](P,M)
\tkzDrawPoints(A,B,M);
\tkzLabelPoints(B,M);
\tkzLabelPoints[above](A);
\end{tikzpicture}
\end{document}


-