@@ -1103,6 +1103,9 @@ Skipping Glyphs: the 'text-decoration-skip-ink' property</h4>
1103
1103
UAs <em> may</em> interrupt underlines and overlines
1104
1104
where the line would cross glyph ink
1105
1105
and to some distance to either side of the glyph outline.
1106
+ UAs <em> should</em> consider the script of the text (see note below)
1107
+ when determining whether to apply ink-skipping behavior to a given
1108
+ range of content.
1106
1109
1107
1110
<dt> <dfn value for="text-decoration-skip-ink">all</dfn> </dt>
1108
1111
<dd>
@@ -1112,10 +1115,58 @@ Skipping Glyphs: the 'text-decoration-skip-ink' property</h4>
1112
1115
1113
1116
<dt> <dfn value for="text-decoration-skip-ink">none</dfn> </dt>
1114
1117
<dd>
1115
- UA must draw continuous underlines and overlines,
1118
+ UA <em> must</em> draw continuous underlines and overlines,
1116
1119
without interruptions when they cross over a glyph.
1117
1120
</dl>
1118
1121
1122
+ <div class="note">
1123
+ Note: Implementation experience shows that ink-skipping behavior often
1124
+ produces undesirable results when underlined text includes ideographic characters,
1125
+ as the underline position (depending on the font and user agent involved)
1126
+ often clashes with almost all the glyphs,
1127
+ such that only occasional fragments of the line remain to be rendered.
1128
+
1129
+ In principle, this could be resolved by authors using
1130
+ ''text-underline-position: under'' (or possibly 'text-underline-offset' )
1131
+ to move the underline to a lower position that does not clash with the glyphs,
1132
+ but this is not always feasible, even if the user agent supports these properties
1133
+ and the author is aware of their potential.
1134
+ In particular, when a page contains arbitrary user-generated content,
1135
+ the author responsible for the design may not know whether CJK content will be present.
1136
+ And with mixed-script content,
1137
+ an underline position designed to work well for CJK content
1138
+ may look bad if the majority of the text is non-CJK.
1139
+
1140
+ Therefore, when ''text-decoration-skip-ink/auto'' is in effect,
1141
+ a UA that implements ink-skipping <em> should</em> refrain from doing so in CJK contexts.
1142
+ (Authors who <em> do</em> want ink-skipping applied to CJK content can use
1143
+ the ''text-decoration-skip-ink/always'' value to explicitly request this.)
1144
+
1145
+ Primarily, this means <em> not</em> applying ink-skipping for characters whose
1146
+ Unicode <a href="http://unicode.org/Public/UCD/latest/ucd/Scripts.txt">Script property</a>
1147
+ is any of the CJK scripts Han, Hiragana, Katakana, Bopomofo, or Hangul,
1148
+ or for characters whose Script property is Inherited or Common,
1149
+ and whose <a href="http://unicode.org/Public/UCD/latest/ucd/ScriptExtensions.txt">ScriptExtensions property</a>
1150
+ includes one or more of the CJK scripts.
1151
+
1152
+ In addition, characters with a Unicode script property of Common and Inherited
1153
+ (primarily generic punctuation and symbols) need to be considered,
1154
+ as these may be used as part of a run of CJK-script content,
1155
+ and it is desirable to treat all text within a given script run in a consistent way.
1156
+ Therefore, the UA <em> should</em> resolve the text into script runs
1157
+ as described in the <a href="https://www.unicode.org/reports/tr24/#Usage_Model">“Implementation Notes”</a>
1158
+ of [[!UAX24]] “Unicode Script Property”, in particular subsections 5.1 and 5.2.
1159
+ After applying the heuristics described there (or a similar analysis of scripts),
1160
+ the UA <em> should</em> disable ink-skipping for all ranges of text
1161
+ that are determined to be in a CJK script.
1162
+
1163
+ Issue: Are there other (non-CJK) scripts where it would be preferable
1164
+ to disable ink-skipping by default
1165
+ (when ''text-decoration-skip-ink/auto'' is in effect)?
1166
+ Perhaps Yi? Arabic?
1167
+ (See also discussion in <a href="https://github.com/w3c/csswg-drafts/issues/1288">Issue 1288</a> .)
1168
+ </div>
1169
+
1119
1170
<h4 id="ink-skip-shape">
1120
1171
Shaping Interruptions</h4>
1121
1172
0 commit comments