Closed richa2008 closed 9 years ago
Graphics object provides two methods which allows you to modify link UI and its position:
graphics.link(function(link){
return Viva.Graph.svg('path')
.attr('stroke', 'red')
.attr('stroke-dasharray', '5, 5');
}).placeLink(function(linkUI, fromPos, toPos) {
// You can assign position that you desire here:
var data = 'M' + fromPos.x + ',' + fromPos.y +
'L' + toPos.x + ',' + toPos.y;
linkUI.attr("d", data);
});
Would this work?
Hi, I am working on vivagraph.I am assigning some predefined position to nodes and want the link also to reposition at that place.But the position of links is not changing.How to do that.Please help.Thanks.