1. Home
  2. Computing & Technology
  3. Web Design / HTML

clip

By Jennifer Kyrnin, About.com

clip Description:

The clip property defines the portion of an element's content that is visible.

clip in CSS Versions:

clip Syntax:

clip: <shape> | auto | inherit

  • <shape>
    The only valid <shape> value is rect(<top> <right> <bottom> <left>), where <top>, <right>, <bottom>, and <left> are offsets from the respective sides of the box.
  • auto
    The element does not clip
  • inherit
    The element should have the same value as the parent element.

clip Initial Value:

auto

clip Applies To:

Absolutely positioned elements.

clip Inheritance:

This property is not inherited.

clip Browser Support:

clip Media Type:

  • Visual

clip Examples:

Standard clip property

<p style="clip: rect(5px 100px 30px 5px);">
This paragraph will be clipped into a rectangle.
</p>

clip Special Notes:

  • This requires the style-property position: absolute to be set.

More clip Information

Return to the Style Library

Explore Web Design / HTML

More from About.com

  1. Home
  2. Computing & Technology
  3. Web Design / HTML
  4. CSS
  5. Style Properties
  6. CSS Style Property: clip

©2008 About.com, a part of The New York Times Company.

All rights reserved.