ciena-blueplanet / dagre

Directed graph renderer for javascript
MIT License
36 stars 13 forks source link

how to avoid nodes overlapping cluster labels #20

Open christianvoigt opened 7 years ago

christianvoigt commented 7 years ago

Hi, thanks for taking care of dagre!

I am currently experimenting with clusters, clusterLabelPos:'top' and rankDir:'BT'. This leads to a layout where the nodes within a cluster are positioned over the cluster labels. Is there any chance to get them out of the way?

In https://github.com/cpettitt/dagre-d3/pull/156 @cpettitt said:

"Looks good! It would be possible to get the edges to route around the cluster label by doing some of this in dagre - e.g. adding a dummy node to the cluster at the right rank with the size of the label."

Is it easy to add such dummy nodes?