@@ -290,7 +290,7 @@ Text Decoration Line Thickness: the 'text-decoration-thickness' property</h3>
290
290
291
291
<pre class="propdef">
292
292
Name : text-decoration-thickness
293
- Value : auto | from-font | <<length>>
293
+ Value : auto | from-font | <<length>> | <<percentage>>
294
294
Initial : auto
295
295
Applies to : all elements
296
296
Inherited : no
@@ -319,10 +319,19 @@ Text Decoration Line Thickness: the 'text-decoration-thickness' property</h3>
319
319
320
320
<dt> <dfn><<length>></dfn>
321
321
<dd>
322
- Specifies the thickness of text decoration lines as a length.
322
+ Specifies the thickness of text decoration lines as a fixed length.
323
323
The UA must floor the actual value at one device pixel.
324
- Authors are strongly encouraged to use ''em'' units
325
- so that the line thickness scales with the font.
324
+
325
+ Note: A length will inherit as a fixed value,
326
+ and will not scale with the font.
327
+
328
+ <dt> <dfn><<percentage>>
329
+ <dd>
330
+ <p>Specifies the offset of underlines as a percentage of ''1em''.
331
+ The UA must floor the actual value at one device pixel.
332
+
333
+ Note: A percentage will inherit as a relative value,
334
+ and will therefore scale with changes in the font as it inherits.
326
335
</dl>
327
336
328
337
<h4 id="text-decoration-thickness">
@@ -605,7 +614,7 @@ Text Underline Offset: the 'text-underline-offset' property</h3>
605
614
606
615
<pre class="propdef">
607
616
Name : text-underline-offset
608
- Value : auto | <<length>>
617
+ Value : auto | <<length>> | <<percentage>>
609
618
Initial : auto
610
619
Applies to : all elements
611
620
Inherited : yes
@@ -637,6 +646,13 @@ Text Underline Offset: the 'text-underline-offset' property</h3>
637
646
638
647
Note: A length will inherit as a fixed value,
639
648
and will not scale with the font.
649
+
650
+ <dt><dfn><<percentage>>
651
+ <dd>
652
+ <p>Specifies the offset of underlines as a percentage of ''1em''.
653
+
654
+ Note: A percentage will inherit as a relative value,
655
+ and will therefore scale with changes in the font as it inherits.
640
656
</dl>
641
657
642
658
When the value of the 'text-decoration-line' property is either
@@ -1872,6 +1888,22 @@ Appendix B: Default UA Stylesheet</h2>
1872
1888
<h2 class="no-num" id="changes">Appendix C:
1873
1889
Changes</h2>
1874
1890
1891
+ <h3 class="no-num" id="changes-2018">
1892
+ Changes since the 13 March 2018 Working Draft</h3>
1893
+
1894
+ <ul>
1895
+ <li> Merged in entire contents of <a href="https://www.w3.org/TR/css-text-decor-3/">CSS Text Decoration Level 3</a> ,
1896
+ so that this is no longer a diff spec.
1897
+ <li> Renamed <css> text-decoration-width</css> to 'text-decoration-thickness' .
1898
+ <li> Defined 'text-underline-offset' postion values as outsets rather than insets,
1899
+ because this was more intuitive to users.
1900
+ <li> Moved ''text-underline-position/from-font'' keyword from 'text-underline-offset' to 'text-underline-position' .
1901
+ (<a href="https://github.com/w3c/csswg-drafts/issues/3118#issuecomment-432297480">Issue 3118</a> )
1902
+ <li> Added <<percentage>> values to 'text-decoration-thickness' and 'text-underline-offset' .
1903
+ (<a href="https://github.com/w3c/csswg-drafts/issues/2165">Issue 2165</a> )
1904
+ <li>
1905
+ </ul>
1906
+
1875
1907
<h3 class="no-num" id="additions-l3">
1876
1908
Additions Since Level 3</h3>
1877
1909
@@ -1880,6 +1912,7 @@ The following features have been added since <a href="https://www.w3.org/TR/css-
1880
1912
<ul>
1881
1913
<li> Added ''spelling-error'' and ''grammar-error'' values to 'text-decoration-line' .
1882
1914
<li> Added 'text-decoration-thickness' and 'text-underline-offset' properties.
1915
+ <li> Added ''text-underline-position/from-font'' value to 'text-underline-position' .
1883
1916
<li> Drafted 'text-emphasis-skip' property.
1884
1917
<li> Added [=spread distance=] value to 'text-shadow' .
1885
1918
</ul>
0 commit comments