Skip to content

Commit b522279

Browse files
committed
[css-color-4] Define where percentages are allowed. See w3c#5894
1 parent 347f2a5 commit b522279

1 file changed

Lines changed: 41 additions & 0 deletions

File tree

css-color-4/Overview.bs

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3150,6 +3150,9 @@ Profiled, Device-dependent Colors</h2>
31503150
(such as ''display-p3'');
31513151
if it is a <<dashed-ident>> it denotes a custom
31523152
colorspace, defined by a ''@color-profile'' rule.
3153+
Individual <a href="#predefined">predefined colorspaces</a>
3154+
may further restrict whether <<number>>s or <<percentage>>s
3155+
or both, may be used.
31533156

31543157
If the <<ident>> names a non-existent colorspace
31553158
(a name that does not match one of the <a href="#predefined">predefined colorspaces</a>),
@@ -3348,6 +3351,10 @@ Predefined colorspaces: ''srgb'', ''display-p3'', ''a98-rgb'', ''prophoto-rgb'',
33483351
<tr><th>White luminance</th><td colspan="2">80.0 cd/m<sup>2</sup></td></tr>
33493352
<tr><th>Black luminance</th><td colspan="2">0.80 cd/m<sup>2</sup></td></tr>
33503353
<tr><th>Image state</th><td colspan="2">display-referred</td></tr>
3354+
<tr>
3355+
<th>Percentages</th>
3356+
<td colspan="2">Allowed for R, G and B</td>
3357+
</tr>
33513358
</table>
33523359

33533360
<pre class="lang-javascript">
@@ -3396,6 +3403,10 @@ Predefined colorspaces: ''srgb'', ''display-p3'', ''a98-rgb'', ''prophoto-rgb'',
33963403
<tr><th>White luminance</th><td colspan="2">80.0 cd/m<sup>2</sup></td></tr>
33973404
<tr><th>Black luminance</th><td colspan="2">0.80 cd/m<sup>2</sup></td></tr>
33983405
<tr><th>Image state</th><td colspan="2">display-referred</td></tr>
3406+
<tr>
3407+
<th>Percentages</th>
3408+
<td colspan="2">Allowed for R, G and B</td>
3409+
</tr>
33993410
</table>
34003411

34013412
<figure>
@@ -3447,6 +3458,10 @@ Predefined colorspaces: ''srgb'', ''display-p3'', ''a98-rgb'', ''prophoto-rgb'',
34473458
<tr><th>White luminance</th><td colspan="2">160.0 cd/m<sup>2</sup></td></tr>
34483459
<tr><th>Black luminance</th><td colspan="2">0.5557 cd/m<sup>2</sup></td></tr>
34493460
<tr><th>Image state</th><td colspan="2">display-referred</td></tr>
3461+
<tr>
3462+
<th>Percentages</th>
3463+
<td colspan="2">Allowed for R, G and B</td>
3464+
</tr>
34503465
</table>
34513466

34523467
<figure>
@@ -3504,6 +3519,10 @@ Predefined colorspaces: ''srgb'', ''display-p3'', ''a98-rgb'', ''prophoto-rgb'',
35043519
<tr><th>White luminance</th><td colspan="2">160.0 to 640.0 cd/m<sup>2</sup></td></tr>
35053520
<tr><th>Black luminance</th><td colspan="2">See text</td></tr>
35063521
<tr><th>Image state</th><td colspan="2">display-referred</td></tr>
3522+
<tr>
3523+
<th>Percentages</th>
3524+
<td colspan="2">Allowed for R, G and B</td>
3525+
</tr>
35073526
</table>
35083527

35093528
<pre class="lang-javascript">
@@ -3555,6 +3574,10 @@ Predefined colorspaces: ''srgb'', ''display-p3'', ''a98-rgb'', ''prophoto-rgb'',
35553574
<tr><th>White chromaticity</th><td>0.3127</td><td>0.3290</td><td>(D65)</td></tr>
35563575
<tr><th>Transfer function</th><td colspan="2">1/2.4 (see note)</td></tr>
35573576
<tr><th>Image state</th><td colspan="2">display-referred</td></tr>
3577+
<tr>
3578+
<th>Percentages</th>
3579+
<td colspan="2">Allowed for R, G and B</td>
3580+
</tr>
35583581
</table>
35593582

35603583
Note: rec2020 references a different transfer curve for cameras. However
@@ -3590,6 +3613,15 @@ Predefined colorspaces: ''srgb'', ''display-p3'', ''a98-rgb'', ''prophoto-rgb'',
35903613
but can occur as a result of chromatic adaptation,
35913614
and likewise must not be clamped.
35923615

3616+
It has the following characteristics:
3617+
3618+
<table>
3619+
<tr>
3620+
<th>Percentages</th>
3621+
<td colspan="2">Disallowed</td>
3622+
</tr>
3623+
</table>
3624+
35933625
<div class="example" id="ex-xyz">
35943626
These are exactly equivalent:
35953627

@@ -3624,6 +3656,15 @@ Predefined colorspaces: ''srgb'', ''display-p3'', ''a98-rgb'', ''prophoto-rgb'',
36243656
predefined-013.html
36253657
</wpt>
36263658

3659+
It has the following characteristics:
3660+
3661+
<table>
3662+
<tr>
3663+
<th>Percentages</th>
3664+
<td colspan="2">Required for L; disallowed for a and b.</td>
3665+
</tr>
3666+
</table>
3667+
36273668
</dl>
36283669

36293670
<h4 id="predefined-to-lab">

0 commit comments

Comments
 (0)