I produce automatically generated LaTeX-files with nodes and links.
Is it possible to put the label of the node outside of the node and it is automatically positioned somewhere, such that there is no line crossing it?
I know I can position the label by hand:
\node[label= above right: N-1](N-1) at (0.0,2.0){ };
But this it not what I want, since sometimes there could be a line right there.
Does anyone have any idea?
label= above right: N-1
you create a new node (in the pgfmanual this node is designed bylabel node
). I think it's difficult to know if your new node could be on a line because it depends of the size of the label node and you need to create a tool to know if there is something drawn where you want to place the label. I'm not very optimistic about existence of such kind of tool !