Skip to content

Commit 907b8d7

Browse files
committed
[css-box-3] Define all the box keywords in the box spec. Relates to w3c/fxtf-drafts#66
1 parent 24f2c35 commit 907b8d7

File tree

1 file changed

+52
-0
lines changed

1 file changed

+52
-0
lines changed

css-box-3/Overview.bs

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,58 @@ The CSS Box Model {#box-model}
193193
is specified in [[css-break-3]]
194194
and controlled by the 'box-decoration-break' property.
195195

196+
Box-edge Keywords {#keywords}
197+
-----------------
198+
199+
The following CSS keywords are defined for use
200+
in properties (such as 'transform-box' and 'background-clip')
201+
that need to refer to various box edges:
202+
203+
<dl dfn-for="<box>,<shape-box>,<geometry-box>" dfn-type=value>
204+
<dt><dfn>content-box</dfn>
205+
<dd>
206+
Refers to the [=content box=] or [=content edge=].
207+
(In an SVG context, treated as ''<box>/fill-box''.)
208+
209+
<dt><dfn>padding-box</dfn>
210+
<dd>
211+
Refers to the [=padding box=] or [=padding edge=].
212+
(In an SVG context, treated as ''<box>/fill-box''.)
213+
214+
<dt><dfn>border-box</dfn>
215+
<dd>
216+
Refers to the [=border box=] or [=border edge=].
217+
(In an SVG context, treated as ''<box>/stroke-box''.)
218+
219+
<dt><dfn>margin-box</dfn>
220+
<dd>
221+
Refers to the [=margin box=] or [=margin edge=].
222+
(In an SVG context, treated as ''<box>/stroke-box''.)
223+
224+
<dt><dfn>fill-box</dfn>
225+
<dd>
226+
Refers to the [=object bounding box=] or its edges.
227+
(In a CSS box context, treated as ''<box>/content-box''.)
228+
229+
<dt><dfn>stroke-box</dfn>
230+
<dd>
231+
Refers to the [=stroke bounding box=] or its edges.
232+
(In a CSS box context, treated as ''<box>/border-box''.)
233+
234+
<dt><dfn>view-box</dfn>
235+
<dd>
236+
Refers to the nearest [=SVG viewport=].
237+
(In a CSS box context, treated as ''<box>/border-box''.)
238+
</dl>
239+
240+
For convenience, the following value types are defined:
241+
<pre>
242+
<dfn><<visual-box>></dfn> = content-box | padding-box | border-box
243+
<dfn><<layout-box>></dfn> = content-box | padding-box | border-box | margin-box
244+
<dfn><<paint-box>></dfn> = content-box | padding-box | border-box | fill-box | stroke-box
245+
<dfn><<coord-box>></dfn> = content-box | padding-box | border-box | fill-box | stroke-box | view-box
246+
</pre>
247+
196248
Margins {#margins}
197249
=======
198250

0 commit comments

Comments
 (0)