Pages

CSS3 background-clip Property

Definition and Usage

The background-clip property specifies the painting area of the background.
Default value: border-box
Inherited: no
Version: CSS3
JavaScript syntax: object.style.backgroundClip="content-box"


Syntax

background-clip: border-box|padding-box|content-box;

Example

<!DOCTYPE html>
<html>
<head>
<style>
div
{
width:300px;
height:300px;
padding:50px;
background-color:yellow;
background-clip:content-box;
border:2px solid #92b901;
}
</style>
</head>
<body>

<div>
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat. Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi.
</div>

</body>
</html>

No comments:

Flag Counter
Designed by vnBloggertheme.com | Copyright © 2013 Remote Tutor