@Abhishek wrote:
Hi i am computing intersection of parts and want to highlight the area of intersection. For that i want to create a node at the point of intersection which will highlight the area. Since intersectRect gives Rect in return can i directly assign it a node which will be used to highlight that area.
I am using following code for getting the intersect and setting the node but i want to give it the dimensions of rect.
var r = node.actualBounds.copy(); var intersect = r.intersectRect(otherNode.actualBounds.copy()); var model = diagram.model; var nodeData = {loc: go.Point.stringify(intersect.center), color:"lightgreen" }; model.addNodeData(nodeData);it is also not resulting the added node in exact center of the intersection.
Posts: 1
Participants: 1