rect
Gets or sets the rectangle defines the image position and size.
Example - resizing the image
<div id="surface" style="width: 250px; height: 250px;"></div>
<script>
var draw = kendo.drawing;
var geom = kendo.geometry;
var rect = new geom.Rect(
[10, 10], // Position of the top left corner
[240, 240] // Size of the rectangle
);
var image = new draw.Image("https://goo.gl/6ov8Gw", rect);
var surface = draw.Surface.create($("#surface"));
surface.draw(image);
setTimeout(function() {
image.rect().setSize([120, 120]);
}, 1000);
</script>
Parameters
value kendo.geometry.Rect
The new image rectangle.
Returns
kendo.geometry.Rect
The current image rectangle.