Name

CLIP — NN 4 IE n/a HTML n/a

Synopsis

CLIP="[leftPixel, topPixel,] rightPixel, bottomPixel"

Optional

A clipping region is a rectangular view to the full LAYER content. Only content that is within the clipping rectangle can be seen on the page. The default value of the CLIP attribute is either the default size of the content or the LAYER element’s width by the automatically flowing content length. Setting the CLIP attribute lets you rein in long content that might flow beyond a fixed rectangle desired for the page design.

Example

<LAYER BGCOLOR="yellow" SRC="instrux.html" CLIP="50,50" WIDTH=200 HEIGHT=300>
</LAYER>

Value

CLIP attribute values are pixel measures from the top and left edges of the element as it flows in the document. The order of values is clockwise from the left edge, around the rectangle sides: left, top, right, bottom. If you supply only two values, Navigator assumes the left and top values are zero, meaning that you wish to adjust only the right and bottom edges. Thus, a setting of "50,50" means that the clipping region is 50-pixels square, starting at the top-left corner of the layer’s rectangle. If you want the same size view starting 10 pixels in from the left, the CLIP attribute setting becomes "10,0,60,50".

Default

Naturally flowing viewing area of LAYER content.

Object Model Reference

NN

[window.]document.layerName.clip.left

[window.]document.layerName.clip.top

[window.]document.layerName.clip.right

[window.]document.layerName.clip.bottom

Get Dynamic HTML: The Definitive Reference now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.