clip | NN 4 IE 4 CSS 2
| Inherited: No
Defines a clipping region of a positionable element. The clipping region is the area of the element layer in which content is visible. For the best results in clipping content, wrap the content-holding element inside a div element with its clip attribute set to the desired region. Clipping may not work properly in Internet Explorer 4 for the Macintosh, but it is fine in Version 5. Also, when a clipped element is displayed at the very bottom of a page in Navigator 4, the browser window may not allow you to scroll to view the very bottom of the clipping region.
CSS Syntax
    clip: rect(lengthTop lengthRight lengthBottom lengthLeft) | auto
Value
Extending to CSS2, the only shape recognized for the clip attribute is rect. Other shapes may be admitted in the future. When specifying lengths for each side of the clipping rectangle, observe the clockwise order of values: top, right, bottom, left. See the discussion about length values at the beginning of this chapter. A value of auto sets the clipping region to the block that contains the content (a block that may extend in IE 4 to the width of the next outermost container, like the body element).
Initial Value
auto
Example
    <span style="position: absolute; clip: rect(10px 110px 80px 10px)">
    <img src="desk1.gif" height="90" width="120">
    </span>
Applies To
Block-level, replaced, and positioned elements.
Object Model Reference
    [window.]document.getElementById("elementID").style.clip