Using tkz-graph package I often feel the need to move a little bit the labels on the edges, that are always positioned midway the edge. In this example I would move the label 0.5
from node a
to node d
closer to node d
to avoid intersection with a red box. Here a MWE:
\documentclass[border=10pt]{standalone}
\usepackage{tkz-graph}
\usetikzlibrary{fit}
\thispagestyle{empty}
\begin{document}
\begin{tikzpicture}
\GraphInit[vstyle=Normal]
\SetGraphUnit{1.5}
\Vertices{circle}{a,b,c,d,e}
\Edge[label=1](a)(b)
\Edge[label=2](a)(c)
\Edge[label=0.5](a)(d)
\Edge[label=3](a)(e)
\node[draw=red!50,rounded corners=5mm,fit=(b.north) (a.south) (c.west) (a.east)](BORD) {};
\node[right of=BORD,anchor=west,inner sep=1cm]{$\mathcal{G}$};
\end{tikzpicture}
\end{document}
How to mode the 0.5
label along the edge and not always in the center?
\Edge[label=0.5,style={pos=.4}](a)(d)
?