draggable.containment String|Element|jQuery
default: ""
Defines the element in which the window will be able to move. The containment option overrides the appendTo setting and attaches the Window to the specified DOM element. Accepts either a selector or an element.
The containment element has to be positioned, that is, its CSS
position
attribute has to be set torelative
,absolute
, orfixed
.
Example
<style>
#container {
position: relative;
width: 500px;
height: 500px;
border: 1px solid grey;
}
</style>
<div id="container">
<div id="window">
<p>Alvar Aalto is one of the greatest names in modern architecture and design.
Glassblowers at the iittala factory still meticulously handcraft the legendary vases
that are variations on one theme, fluid organic shapes that let the end user decide the use.
</p>
</div>
</div>
<script>
$(document).ready(function() {
$("#window").kendoWindow({
width: "300px",
height: "200px",
draggable: {
containment: "#container"
}
});
});
</script>