dojo.contentBox
<script src="../../js/dojo.js"></script>
defined in dojo/_base/html.js
Returns an object in the expected format of box (regardless if box is passed).
The object might look like:
{ l: 50, t: 200, w: 300: h: 150 }
for a node offset from its parent 50px to the left, 200px from
the top with a content width of 300px and a content-height of
150px. Note that the content box may have a much larger border
or margin box, depending on the box model currently in use and
CSS values set/inherited for node.
parameter | type | description |
---|---|---|
node | DomNode|String | id or reference to DOM Node to get/set box for |
box | Object | Optional. If passed, denotes that dojo.contentBox() should update/set the content box for node. Box is an object in the above format. All properties are optional if passed. |