transform

Gets or sets the transformation of the element. Inherited from Element.transform

Parameters

transform kendo.geometry.Transformation

The transformation to apply to the element.

Returns

kendo.geometry.Transformation The current transformation on the element.

Example

<div id="surface"></div>
<script>
    var draw = kendo.drawing;
    var geom = kendo.geometry;

    var rectGeometry = new geom.Rect([50, 50], [100, 100]);
    var rect = new draw.Rect(rectGeometry).fill("cyan");

    // Apply scale and rotation transformation
    var transform = geom.transform().scale(1.5, 1.5).rotate(30, [100, 100]);
    rect.transform(transform);

    // Get current transformation
    var currentTransform = rect.transform();
    console.log("Current transformation:", currentTransform);

    var surface = draw.Surface.create($("#surface"));
    surface.draw(rect);
</script>
In this article
transform
Not finding the help you need?
Contact Support