Skip to content

Commit cd13b43

Browse files
committed
[various][editorial] Switch relevant uses of 'intrinsic width/height/aspect ratio/size' to 'natural', per w3c#4961.
1 parent 7dd743a commit cd13b43

File tree

13 files changed

+121
-120
lines changed

13 files changed

+121
-120
lines changed

css-backgrounds-3/Overview.bs

+15-15
Original file line numberDiff line numberDiff line change
@@ -929,13 +929,13 @@ layer.
929929

930930
<dl dfn-for=background-size dfn-type=value>
931931
<dt><dfn>contain</dfn></dt>
932-
<dd>Scale the image, while preserving its intrinsic aspect ratio
932+
<dd>Scale the image, while preserving its [=natural aspect ratio=]
933933
(if any), to the largest size such that both its width and its
934934
height can fit inside the <span class=index>background
935935
positioning area.</span></dd>
936936

937937
<dt><dfn>cover</dfn></dt>
938-
<dd>Scale the image, while preserving its intrinsic aspect ratio
938+
<dd>Scale the image, while preserving its [=natural aspect ratio=]
939939
(if any), to the smallest size such that both its width and its
940940
height can completely cover the background positioning area.</dd>
941941

@@ -949,14 +949,14 @@ layer.
949949
<p>A percentage is relative to the background positioning area.
950950

951951
<p>An ''background-size/auto'' value for one dimension is resolved by using the
952-
image's intrinsic ratio and the size of the other dimension, or
953-
failing that, using the image's intrinsic size, or failing that,
952+
image's [=natural aspect ratio=] and the size of the other dimension, or
953+
failing that, using the image's [=natural size=], or failing that,
954954
treating it as 100%.
955955

956-
<p>If both values are ''background-size/auto'' then the intrinsic width and/or
957-
height of the image should be used, if any, the missing dimension
956+
<p>If both values are ''background-size/auto'' then the [=natural width=] and/or
957+
[=natural height|height=] of the image should be used, if any, the missing dimension
958958
(if any) behaving as ''background-size/auto'' as described above. If the image has
959-
neither an intrinsic width nor an intrinsic height, its size is
959+
neither [=natural size=], its size is
960960
determined as for ''contain''.
961961

962962
<p>Negative values are invalid.
@@ -994,7 +994,7 @@ para {
994994
background-image: url(tile.png)}
995995
</pre>
996996

997-
<p>This example uses the image's intrinsic size. Note that this is the
997+
<p>This example uses the image's natural size. Note that this is the
998998
only possible behavior in CSS level&nbsp;1 and 2.
999999

10001000
<pre>
@@ -1038,7 +1038,7 @@ step: that other dimension is scaled so that the original aspect ratio
10381038
is restored.
10391039

10401040
<div class=example>
1041-
<p>In this example the background image is shown at its intrinsic size:
1041+
<p>In this example the background image is shown at its natural size:
10421042

10431043
<pre>
10441044
div {
@@ -2338,7 +2338,7 @@ as if a nonempty transparent image had been specified for those
23382338
parts. Analogously for the top and bottom values.
23392339

23402340
<p>If the image must be sized to determine the slices
2341-
(for example, for SVG images with no intrinsic size),
2341+
(for example, for SVG images with no [=natural dimensions=]),
23422342
then it is sized using the <a href="https://www.w3.org/TR/css3-images/#default-sizing">default sizing algorithm</a>
23432343
with no <i>specified size</i> and the <i>border image area</i> as the <i>default object size</i>.
23442344

@@ -2414,9 +2414,9 @@ Values have the following meanings:</p>
24142414

24152415
<dt><dfn>auto</dfn>
24162416
<dd>If ''border-image-width/auto'' is specified then the border image width is the
2417-
intrinsic width or height (whichever is applicable) of the
2417+
[=natural size|natural=] width or height (whichever is applicable) of the
24182418
corresponding image slice (see 'border-image-slice'). If the image
2419-
does not have the required intrinsic dimension then the
2419+
does not have the required [=natural dimension=] then the
24202420
corresponding computed <a href="#the-border-width">border-width</a> is used
24212421
instead.
24222422
</dl>
@@ -3210,9 +3210,9 @@ Candidate Recommendation</a>:
32103210
<ul>
32113211
<li><a href="#the-background-size">Section 3.9</a>:
32123212
Defined what happens if 'background-size' has two ''background-size/auto'' values
3213-
and the image is missing an intrinsic dimension.
3213+
and the image is missing a natural size.
32143214
<blockquote>
3215-
<p>If both values are ''background-size/auto'' then the intrinsic width and/or
3215+
<p>If both values are ''background-size/auto'' then the natural width and/or
32163216
height of the image should be used, if any<ins>, the missing
32173217
dimension (if any) behaving as ‘auto’ as described above</ins>.
32183218
</blockquote>
@@ -3244,7 +3244,7 @@ Candidate Recommendation</a>:
32443244
Added:
32453245
<blockquote>
32463246
<p><ins>If the image must be sized to determine the slices (for
3247-
example, for SVG images with no intrinsic size), then it is sized
3247+
example, for SVG images with no natural size), then it is sized
32483248
as for an auto-sized background, using the border image area as
32493249
the default object size in place of the background positioning
32503250
area.</ins>

css-contain-1/Overview.bs

+5-5
Original file line numberDiff line numberDiff line change
@@ -512,10 +512,10 @@ Size Containment</h3>
512512
contain-size-grid-001.html
513513
</wpt>
514514

515-
<a>Replaced elements</a> must be treated as having an intrinsic width and height of 0
516-
and no [=intrinsic aspect ratio=].
515+
<a>Replaced elements</a> must be treated as having a [=natural dimensions|natural=] width and height of 0
516+
and no [=natural aspect ratio=].
517517

518-
Note: Size containment only suppresses the [=intrinsic aspect ratio=],
518+
Note: Size containment only suppresses the [=natural aspect ratio=],
519519
so properties like 'aspect-ratio' which affect that [=preferred aspect ratio=] directly
520520
are honored.
521521

@@ -601,8 +601,8 @@ Size Containment</h3>
601601

602602
If the 'aspect-ratio' property had not been declared,
603603
the image would have been 100px by 0px,
604-
as its intrinsic aspect ratio is suppressed,
605-
and its intrinsic height is treated as 0.
604+
as its [=natural aspect ratio=] is suppressed,
605+
and its [=natural height=] is treated as 0.
606606
</div>
607607

608608
By itself, <a>size containment</a> does not offer much optimization opportunity.

css-contain-2/Overview.bs

+6-6
Original file line numberDiff line numberDiff line change
@@ -543,10 +543,10 @@ Size Containment</h3>
543543
contain-size-grid-001.html
544544
</wpt>
545545

546-
<a>Replaced elements</a> must be treated as having an intrinsic width and height of 0
547-
and no [=intrinsic aspect ratio=].
546+
<a>Replaced elements</a> must be treated as having an [=natural dimensions|natural=] width and height of 0
547+
and no [=natural aspect ratio=].
548548

549-
Note: Size containment only suppresses the [=intrinsic aspect ratio=],
549+
Note: Size containment only suppresses the [=natural aspect ratio=],
550550
so properties like 'aspect-ratio' which affect that [=preferred aspect ratio=] directly
551551
are honored.
552552

@@ -625,8 +625,8 @@ Size Containment</h3>
625625

626626
If the 'aspect-ratio' property had not been declared,
627627
the image would have been 100px by 0px,
628-
as its intrinsic aspect ratio is suppressed,
629-
and its intrinsic height is treated as 0.
628+
as its [=natural aspect ratio=] is suppressed,
629+
and its [=natural height=] is treated as 0.
630630
</div>
631631

632632
By itself, <a>size containment</a> does not offer much optimization opportunity.
@@ -1733,7 +1733,7 @@ Changes from <a href="https://www.w3.org/TR/2019/WD-css-contain-2-20191111/">201
17331733
* Define the interaction between [=paint containment=] and 'overflow-clip-margin'
17341734
* Add the 'content-visibility' property
17351735
* Editorial improvements and clarifications to size and paint containment (in sync with the same improvements made to Level 1)
1736-
* Be explicit that size containment suppresses intrinsic aspect ratio (in sync with the same improvements made to Level 1)
1736+
* Be explicit that size containment suppresses natural aspect ratio (in sync with the same improvements made to Level 1)
17371737
* Change terminology: replace "containing box" with "containment box" (in sync with the same improvements made to Level 1)
17381738

17391739
<h3 id="l1-changes">

css-content-3/Overview.bs

+1-8
Original file line numberDiff line numberDiff line change
@@ -154,20 +154,13 @@ Inserting and replacing content with the 'content' property</h2>
154154
as if they were ''display: none''.
155155

156156
If the <<image>> represents an <a>invalid image</a>,
157-
then it must be treated as instead representing an image with zero intrinsic width and height,
157+
then it must be treated as instead representing an image with zero [=natural dimensions|natural=] width and height,
158158
filled with transparent black.
159159

160160
Issue: The above <a>invalid image</a> behavior appears to be what Chrome is doing.
161161
Is this okay?
162162
Is there a better behavior we can/should use?
163163

164-
Issue: "Zero intrinsic width and height" gives it an undefined aspect ratio,
165-
and sizing behavior is thus... undefined.
166-
At least, if you give it an explicit width or height,
167-
the other dimension remains at zero in Chrome.
168-
This might need to be explicitly defined over in the Images spec;
169-
needs some investigation around whether browsers act this way for 0x0 SVGs and rasters.
170-
171164
Note: Replaced elements use different layout rules than normal elements.
172165
(In effect, it becomes equivalent to an HTML <{img}> element.)
173166

css-display-3/Overview.bs

+9-9
Original file line numberDiff line numberDiff line change
@@ -1018,20 +1018,20 @@ Appendix A: Glossary</h2>
10181018
For example, the content of the HTML <{img}> element
10191019
is often replaced by the image that its <{img/src}> attribute designates.
10201020
</span>
1021-
Replaced elements often have intrinsic dimensions:
1022-
an intrinsic width, an intrinsic height, and an intrinsic ratio.
1023-
For example, a bitmap image has an intrinsic width and an intrinsic height specified in absolute units
1024-
(from which the intrinsic ratio can obviously be determined).
1025-
On the other hand, other documents may not have any intrinsic dimensions
1021+
Replaced elements often have [=natural dimensions=].
1022+
For example, a bitmap image has a natural width and a natural height specified in absolute units
1023+
(from which the natural ratio can obviously be determined).
1024+
On the other hand, other objects may not have any natural dimensions
10261025
(for example, a blank HTML document).
1026+
See [[css-images-3]].
10271027

1028-
User agents may consider a replaced element to not have any intrinsic dimensions
1028+
User agents may consider a [=replaced element=] to not have any [=natural dimensions=]
10291029
if it is believed that those dimensions could leak sensitive information to a third party.
1030-
For example, if an HTML document changed intrinsic size depending on the user's bank balance,
1031-
then the UA might want to act as if that resource had no intrinsic dimensions.
1030+
For example, if an HTML document changed natural size depending on the user's bank balance,
1031+
then the UA might want to act as if that resource had no [=natural dimensions=].
10321032

10331033
The content of replaced elements is not considered in the CSS formatting model;
1034-
however, their intrinsic dimensions are used in various layout calculations.
1034+
however, their [=natural dimensions=] are used in various layout calculations.
10351035

10361036
A <dfn lt="non-replaced | non-replaced element">non-replaced</dfn> element is one that is not <a>replaced</a>,
10371037
i.e. whose rendering is dictated by the CSS model.

css-grid-1/Overview.bs

+8-8
Original file line numberDiff line numberDiff line change
@@ -1110,13 +1110,13 @@ Grid Items</h2>
11101110

11111111
A <a>grid item</a> is sized within the containing block defined by its <a>grid area</a>.
11121112

1113-
Grid item calculations for 'auto' widths and heights
1113+
[=Grid item=] calculations for [=automatic sizes=] in a given dimensions
11141114
vary by their [[css-align-3#self-alignment|self-alignment values]]:
11151115

11161116
: ''align-self/normal''
11171117
::
1118-
If the grid item is a [=replaced element=] with an intrinsic size in the relevant dimension
1119-
(or with an aspect ratio and an intrinsic size in the other dimension)
1118+
If the grid item is a [=replaced element=] with a [=natural size=] in the relevant dimension
1119+
(or with a [=preferred aspect ratio=] and a [=natural size=] in the other dimension)
11201120
the grid item is sized as for ''align-self: start''
11211121
(consistent with the width calculation rules for block-level replaced elements in [[CSS2/visudet#block-replaced-width]]).
11221122

@@ -1153,15 +1153,15 @@ Grid Items</h2>
11531153
<tr>
11541154
<th scope=row>''align-self/normal''
11551155
<td>Fill grid area
1156-
<td>Use intrinsic size
1156+
<td>Use [=natural size=]
11571157
<tr>
11581158
<th scope=row>''align-self/stretch''
11591159
<td>Fill grid area
11601160
<td>Fill grid area
11611161
<tr>
11621162
<th scope=row>''align-self/start''/''align-self/center''/etc.
11631163
<td>''width/fit-content'' sizing (like floats)
1164-
<td>Use intrinsic size
1164+
<td>Use [=natural size=]
11651165
</table>
11661166
</div>
11671167

@@ -4679,7 +4679,7 @@ Changes since the <a href="https://www.w3.org/TR/2020/CR-css-grid-1-20200818/">1
46794679
<li id="change-2020-align-normal-aspect-ratio">
46804680
Fix errors introduced by in the previous CR by an undocumented attempt to clarify [[#grid-item-sizing]] interaction with 'aspect-ratio'.
46814681
<li id="change-2020-preferred-aspect-ratio">
4682-
Updated some instances of [=intrinsic aspect ratio=]
4682+
Updated some instances of [=natural aspect ratio=]
46834683
to use the more generic term [=preferred aspect ratio=].
46844684
(<a href="https://github.com/w3c/csswg-drafts/issues/4962">Issue 4962</a>)
46854685
</ul>
@@ -5337,8 +5337,8 @@ Major Changes</h4>
53375337

53385338
<li id="change-2016-auto-ratio">
53395339
Changed [[#grid-item-sizing|automatic sizing]]
5340-
of grid items (such as images) with an intrinsic size or ratio
5341-
so that they maintain their intrinsic size/ratio
5340+
of grid items (such as images) with [=natural dimensions=]
5341+
so that they maintain their [=natural dimensions=]
53425342
whenever the alignment properties are ''align-self/normal'' (the default case).
53435343
(<a href="https://github.com/w3c/csswg-drafts/issues/523">Issue #523</a>)
53445344
See [[#grid-item-sizing]]

css-grid-2/Overview.bs

+6-6
Original file line numberDiff line numberDiff line change
@@ -1156,13 +1156,13 @@ Grid Items</h2>
11561156

11571157
A <a>grid item</a> is sized within the containing block defined by its <a>grid area</a>.
11581158

1159-
Grid item calculations for 'auto' widths and heights
1159+
[=Grid item=] calculations for [=automatic sizes=] in a given dimensions
11601160
vary by their [[css-align-3#self-alignment|self-alignment values]]:
11611161

11621162
: ''align-self/normal''
11631163
::
1164-
If the grid item is a [=replaced element=] with an intrinsic size in the relevant dimension
1165-
(or with an aspect ratio and an intrinsic size in the other dimension)
1164+
If the grid item is a [=replaced element=] with a [=natural size=] in the relevant dimension
1165+
(or with a [=preferred aspect ratio=] and a [=natural size=] in the other dimension)
11661166
the grid item is sized as for ''align-self: start''
11671167
(consistent with the width calculation rules for block-level replaced elements in [[CSS2/visudet#block-replaced-width]]).
11681168

@@ -1197,15 +1197,15 @@ Grid Items</h2>
11971197
<tr>
11981198
<th scope=row>''align-self/normal''
11991199
<td>Fill grid area
1200-
<td>Use intrinsic size
1200+
<td>Use [=natural size=]
12011201
<tr>
12021202
<th scope=row>''align-self/stretch''
12031203
<td>Fill grid area
12041204
<td>Fill grid area
12051205
<tr>
12061206
<th scope=row>''align-self/start''/''align-self/center''/etc.
12071207
<td>''width/fit-content'' sizing (like floats)
1208-
<td>Use intrinsic size
1208+
<td>Use [=natural size=]
12091209
</table>
12101210
</div>
12111211

@@ -5313,7 +5313,7 @@ Changes since the <a href="https://www.w3.org/TR/2020/CR-css-grid-2-20200818/">A
53135313
<li id="change-2020-align-normal-aspect-ratio">
53145314
Fix errors introduced by in the previous CR of CSS Grid 1 by an undocumented attempt to clarify [[#grid-item-sizing]] interaction with 'aspect-ratio'.
53155315
<li id="change-2020-preferred-aspect-ratio">
5316-
Updated some instances of [=intrinsic aspect ratio=]
5316+
Updated some instances of [=natural aspect ratio=]
53175317
to use the more generic term [=preferred aspect ratio=].
53185318
(<a href="https://github.com/w3c/csswg-drafts/issues/4962">Issue 4962</a>)
53195319
</ul>

css-images-3/Overview.bs

+3
Original file line numberDiff line numberDiff line change
@@ -1196,6 +1196,9 @@ Object-Sizing Terminology {#sizing-terms}
11961196
if multiple sizes tie for the largest area,
11971197
the widest size is chosen as its [=natural dimensions=].
11981198

1199+
The [=natural width=] and [=natural height=]
1200+
are collectively referred to the <dfn lt="natural size">natural sizes</dfn>.
1201+
11991202
<dt><dfn>specified size</dfn>
12001203
<dd>
12011204
The specified size of an [=object=] is given by CSS,

0 commit comments

Comments
 (0)