1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2 <html>
3 <head>
4 <title>CSS Test: 'clip': Basic Test</title>
5 <link rel="author" title="David Hyatt" href="mailto:hyatt@netscape.com">
6 <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch">
7 <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/clipping/001.html" type="text/html">
8 <link rel="help" href="http://www.w3.org/TR/CSS21/visufx.html#clipping">
9 <style type="text/css">
10 .green {
11 width: 200px;
12 height: 200px;
13 background-color: green;
14 }
15
16 .red {
17 width: 100px;
18 height: 100px;
19 background-color: red;
20 }
21
22 .clip {
23 position: absolute;
24 clip: rect(100px, 200px, 200px, 100px);
25 }
26 </style>
27 </head>
28 <body>
29
30 <p>Test passes if there is <strong>a green square</strong> and <strong>no red</strong>.</p>
31
32 <div class="green clip"><div class="red"></div></div></body>
33 </html>