1 <!DOCTYPE html>
2 <html><head>
3 <meta charset="utf-8">
4 <title>CSS Backgrounds and Borders Test: background-origin 'content-box' with background-attachment 'fixed'</title>
5 <link href="http://www.intel.com" rel="author" title="Intel">
6 <link href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" rel="reviewer" title="Gérard Talbot"> <!-- 2012-11-09 -->
7 <link href="http://www.w3.org/TR/css3-background/#the-background-origin" rel="help" title="3.8. Positioning Area: the 'background-origin' property">
8 <link href="reference/background-origin-006-ref.htm" rel="match">
9 <meta content="image" name="flags">
10 <meta content="Check if the 'background-attachment' value is 'fixed' that expecting 'background-origin' has no effect and the background positioning area is the initial containing block." name="assert">
11 <style>
12 html {
13 padding-left: 170px;
14 }
15 div {
16 left: 0px;
17 position: absolute;
18 top: 0px;
19 }
20 #ref-overlapped-red {
21 background-color: red;
22 height: 60px;
23 width: 60px;
24 }
25 #test-overlapping-green {
26 background-attachment: fixed;
27 background-image: url(support/60x60-green.png);
28 background-origin: content-box;
29 background-repeat: no-repeat;
30 border: transparent dotted 5px;
31 height: 100px;
32 padding: 25px;
33 width: 100px;
34 }
35 </style>
36 </head>
37 <body>
38 <p>Test passes if there is a filled green square at the left of the page and <strong>no red</strong>.</p>
39 <div id="ref-overlapped-red">
40 <div id="test-overlapping-green"></div>
41 </div>
42
43
44 </body></html>