rotate

Rotates the point around the given center.

Parameters

angle Number

Angle in decimal degrees. Measured in clockwise direction with 0 pointing "right". Negative values or values greater than 360 will be normalized.

center kendo.geometry.Point|Array (default: [0, 0])

The rotation center. Can be a Point instance or an [x, y] array.

Returns

kendo.geometry.Point The current Point instance.

Example

<script>
var geom = kendo.geometry;
var point = new geom.Point(10, 0);
var center = new geom.Point(0, 0);

console.log("Before rotation:", point.toString()); // outputs: "10 0"
point.rotate(90, center);
console.log("After 90° rotation:", point.toString()); // outputs: "0 10"
</script>
In this article
rotate
Not finding the help you need?
Contact Support