allPoints
Gets all points of the Connection. This is the union of the endpoints and the intermediate points.
Returns
Array
all points of the connection.
Example - using allPoints
<button id="getPointsBtn">Get Connection Points</button>
<div id="diagram"></div>
<script>
var Shape = kendo.dataviz.diagram.Shape;
$("#diagram").kendoDiagram();
var diagram = $("#diagram").data("kendoDiagram");
var shape1 = diagram.addShape( new Shape({ x: 20, y: 180 }));
var shape2 = diagram.addShape( new Shape({ x: 300, y: 180 }));
var connection = new kendo.dataviz.diagram.Connection(shape1, shape2, {
type: "polyline",
points: [
{ x: 150, y: 100 },
{ x: 175, y: 150 },
{ x: 200, y: 100 }
],
selectable: false
});
diagram.addConnection(connection);
$("#getPointsBtn").on("click", function(){
var connection = diagram.connections[0];
/* The result can be observed in the DevTools(F12) console of the browser. */
console.log(connection.points());
});
</script>