|
1 | 1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> |
2 | 2 | <html lang="en"> |
3 | | -<!-- $Id: colors.src,v 2.33 2003-07-21 14:39:28 bbos Exp $ --> |
| 3 | +<!-- $Id: colors.src,v 2.34 2003-08-04 12:53:20 bbos Exp $ --> |
4 | 4 | <head> |
5 | 5 | <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> |
6 | 6 | <title>Colors and backgrounds</title> |
7 | 7 | <meta name="editor" lang="tr" content="Tantek Çelik"> |
8 | | -<!-- Changed by: Tantek Celik, 2003-07-18 --> |
| 8 | +<!-- Changed by: Tantek Celik, 2003-07-29 --> |
9 | 9 | <style type="text/css"> |
10 | 10 | .current,.proposed,span.delcurrent { background:#feb } |
11 | | -ins.proposed,span.insproposed { background:#bfb } |
| 11 | +ins.proposed,span.insproposed,p.insproposed { background:#bfb } |
12 | 12 | del.proposed,span.delproposed { background:#fbb } |
13 | | -span.insproposed { text-decoration:underline } |
| 13 | +span.insproposed,p.insproposed { text-decoration:underline } |
14 | 14 | span.delproposed,span.delcurrent { text-decoration:line-through } |
15 | 15 | body>del,body>ins {display:block} |
16 | 16 | </style> |
@@ -62,55 +62,64 @@ background will shine through by default because of the initial |
62 | 62 | class="propinst-background-color">'background-color'</span>. |
63 | 63 | </p> |
64 | 64 | <del class="current"> |
65 | | -<p>The background of the box generated by the root element covers the |
66 | | -entire <a href="intro.html#canvas">canvas</a>. |
| 65 | +<p> |
| 66 | +The background of the box generated by the root element covers the |
| 67 | +entire <a href="intro.html#canvas">canvas</a>, |
| 68 | +anchored at the same point as it would be if the root |
| 69 | +element were a block level element. |
67 | 70 | </p> |
68 | 71 | </del> |
69 | 72 | <ins class="proposed"> |
70 | 73 | <p> |
71 | | -The background of the canvas is the same as the background of the |
72 | | -root element, anchored at the same point as it would be if the root |
73 | | -element was a block level element. |
| 74 | +The background of the <a href="intro.html#canvas">canvas</a> covers the entire canvas and is the background of the root element, anchored at the same point as it would be if it was painted only for the root element itself. The root element does not paint this background again. |
74 | 75 | </p> |
75 | 76 | </ins> |
| 77 | + |
76 | 78 | <p>For HTML documents, however, we recommend that authors specify the |
77 | 79 | background for the BODY element rather than the HTML element. User |
78 | 80 | agents should observe the following precedence rules to fill in the |
79 | | -background of the canvas: if the value of the <span |
80 | | -class="propinst-background">'background'</span> property for the HTML |
| 81 | +background of the canvas <span class="insproposed">of HTML documents</span>: |
| 82 | +if the value of the <span class="propinst-background">'background'</span> property for the HTML |
81 | 83 | element is different from 'transparent' then use it, else use the |
82 | 84 | value of the <span class="propinst-background">'background'</span> |
83 | 85 | property for the BODY element. If the resulting value is |
84 | | -'transparent', the rendering is undefined. (This does not apply to |
85 | | -XHTML documents.) |
| 86 | +'transparent', the rendering is undefined. <span class="delproposed">(</span>This does not apply to XHTML documents.<span class="delproposed">)</span> |
86 | 87 | </p> |
87 | 88 | <div class="html-example"><p> |
88 | 89 | According to these rules, the canvas underlying the following |
89 | 90 | HTML document will have a "marble" background: |
90 | 91 | </p> |
91 | 92 | <pre> |
92 | 93 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"> |
| 94 | +<span class="delproposed"> |
93 | 95 | <HTML> |
94 | 96 | <HEAD> |
| 97 | +</span> |
95 | 98 | <TITLE>Setting the canvas background</TITLE> |
96 | 99 | <STYLE type="text/css"> |
97 | 100 | BODY { background: url("http://example.com/marble.png") } |
98 | 101 | </STYLE> |
| 102 | +<span class="delproposed"> |
99 | 103 | </HEAD> |
100 | 104 | <BODY> |
| 105 | +</span> |
101 | 106 | <P>My background is marble. |
| 107 | +<span class="delproposed"> |
102 | 108 | </BODY> |
103 | 109 | </HTML> |
| 110 | +</span> |
104 | 111 | </pre> |
| 112 | +<p class="insproposed"> |
| 113 | +Note that the rule for the BODY element will work even though the BODY tag has been omitted in the HTML source since the HTML parser will infer the missing tag. |
| 114 | +</p> |
105 | 115 | </div> |
106 | 116 |
|
107 | | -<ins class="proposed"> |
108 | 117 | <p> |
109 | 118 | Backgrounds of elements that form a stacking context (see the |
110 | | -'z-index' property) are painted at the bottom of the element's |
111 | | -stacking context, below any other elements in that stacking context. |
| 119 | +<span |
| 120 | +class="propinst-z-index">'z-index'</span> property) are painted at the bottom of the element's |
| 121 | +stacking context, below anything in that stacking context. |
112 | 122 | </p> |
113 | | -</ins> |
114 | 123 |
|
115 | 124 | <h3><a name="background-properties">Background properties</a>: <span |
116 | 125 | class="propinst-background-color">'background-color'</span>, <span |
@@ -301,11 +310,10 @@ padding area. |
301 | 310 | <dd>Same as '100% 100%'.</dd> |
302 | 311 | </dl> |
303 | 312 |
|
304 | | -<p> If only one percentage or length value is given, it sets the |
| 313 | +<p>If only one percentage or length value is given, it sets the |
305 | 314 | horizontal position only, and the vertical position will be 50%. If two |
306 | 315 | values are given, the horizontal position comes first. Combinations of |
307 | | -<span class="insproposed">keyword,</span> length and percentage values are allowed, (e.g., '50% 2cm'<span class="insproposed"> or 'center 2cm' or 'center 10%'</span>). Negative |
308 | | -positions are allowed. |
| 316 | +keyword, length and percentage values are allowed, (e.g., '50% 2cm' or 'center 2cm' or 'center 10%'). For combinations of keyword and non-keyword values, 'left' and 'right' may only be used as the first value, and 'top' and 'bottom' may only be used as the second value. Negative positions are allowed. |
309 | 317 | </p> |
310 | 318 | <p> |
311 | 319 | The computed value of background-position for the purpose of inheritance is |
|
0 commit comments