You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[css-text-decor] text-decoration-skip: ink should allow not to skip for CJK and certain ideographic scripts #707
Currently we're considering implementing text-decoration-skip: ink, and investigating what to do with CJK.
CJK does not want to skip ink in general.
Blink has not implemented heuristics to draw underlines to under position for CJK yet, and therefore underlines have high possibility to overlap with glyphs.
Implementing text-underline-position: auto to draw at under position for CJK is one way to solve this, and we're investigating this option.
The other option, we found WebKit does not skip ink for characters in CJK and Linear B ideogram blocks.
This might make sense since when font-size is small, no matter what we do, there may be overlaps.
On the other hand, some special fancy CJK fonts such as Kazuraki may want to skip ink.
I haven't come to the conclusion yet, but should the text-decoration-skip: ink allow not to skip for some scripts or under certain conditions? I mean I think it should, though I'm not clear how to define it properly yet.
It should definitely be left up to the UA. The UA knows the environment where the page is being viewed (such as location) as well as any context the page has already provided (such as lang attribute).
If there are additional signals that web authors may want to declare to control skipping, the current syntax can be extended in the future. However, the default behavior should be to let the UA do the right thing.
I have a slightly different but maybe related question: should text-decoration-skip: ink applied on decoration lines other than underline, namely overline and line-through?
@litherum than you, so something like "UA may decide not to skip for certain scripts such as ideographs or under condition where UA determines is appropriate not to skip. Future CSS may provide additional controls for such behavior if desired"?
@upsuper that's really a good question, I don't know the answer from top of my head. Probably worth an issue by itself?
For special CJK fonts(Kazuraki), I do not know whether the specification is not supposed to add a new attribute that allows the developer to define the behavior of the ink itself.
This seems like more of a case for adjusting the position of the underline, which the UA is already allowed to do, than fixing the ink-skipping rules... If the underline is too close to the CJK glyphs, it already looks bad, even if we turn off skipping. Another thing that is under control of the UA is how much ink to skip: it looks like rather too much skipping in the screenshot.
Personally, I don't think there is anything to fix in the specs here. Blink just needs a better implementation of the existing spec.
>This seems like more of a case for adjusting the position of the underline
I think that's different topic.
CJK characters may use up to full em-box, while underline should be drawn at the bottom of em-box, so this could happen even with underline-position: under, especially in small digital fonts,
Skipping ink looks like cheap fancy supermarket advertisement in CJK typesetting tradition.
The UA can pull the underline below the em-box if necessary. There is no restriction on the position. Afaict it will look bad if it overlaps, whether or not ink is skipped, no?
In any case, if for some reason the underline is positioned to overlap (e.g. author sets text-underline-offset to create this overlap), then the ink-skipping, if specified, should be honored.
It's hard to explain in short, but position and skipping are two independent issues. Positioning can mitigate skipping ink issue by making the interceptions very rare though.
I think this discussion is very similar to the one about line-through #711; when author says "skip ink", should we skip ink regardless of how sane it is, or should we interpret "improve typography by skipping ink, but don't skip ink if insane."?
I think we prefer the latter, and let UA be smart enough to know when to skip and when not to.
Activity
litherum commentedon Nov 15, 2016
It should definitely be left up to the UA. The UA knows the environment where the page is being viewed (such as location) as well as any context the page has already provided (such as lang attribute).
If there are additional signals that web authors may want to declare to control skipping, the current syntax can be extended in the future. However, the default behavior should be to let the UA do the right thing.
upsuper commentedon Nov 15, 2016
I have a slightly different but maybe related question: should
text-decoration-skip: inkapplied on decoration lines other than underline, namely overline and line-through?kojiishi commentedon Nov 15, 2016
@litherum than you, so something like "UA may decide not to skip for certain scripts such as ideographs or under condition where UA determines is appropriate not to skip. Future CSS may provide additional controls for such behavior if desired"?
@upsuper that's really a good question, I don't know the answer from top of my head. Probably worth an issue by itself?
upsuper commentedon Nov 15, 2016
Filed #711.
yisibl commentedon Nov 21, 2016
Yes, I think CJK does not want to skip ink in general.
At present, the realization of Blink is very strange:

yisibl commentedon Nov 21, 2016
For special CJK fonts(Kazuraki), I do not know whether the specification is not supposed to add a new attribute that allows the developer to define the behavior of the ink itself.
fantasai commentedon Dec 23, 2016
This seems like more of a case for adjusting the position of the underline, which the UA is already allowed to do, than fixing the ink-skipping rules... If the underline is too close to the CJK glyphs, it already looks bad, even if we turn off skipping. Another thing that is under control of the UA is how much ink to skip: it looks like rather too much skipping in the screenshot.
Personally, I don't think there is anything to fix in the specs here. Blink just needs a better implementation of the existing spec.
kojiishi commentedon Dec 27, 2016
>This seems like more of a case for adjusting the position of the underline
I think that's different topic.
underline-position: under, especially in small digital fonts,fantasai commentedon Dec 27, 2016
The UA can pull the underline below the em-box if necessary. There is no restriction on the position. Afaict it will look bad if it overlaps, whether or not ink is skipped, no?
In any case, if for some reason the underline is positioned to overlap (e.g. author sets
text-underline-offsetto create this overlap), then the ink-skipping, if specified, should be honored.kojiishi commentedon Jan 7, 2017
It's hard to explain in short, but position and skipping are two independent issues. Positioning can mitigate skipping ink issue by making the interceptions very rare though.
I think this discussion is very similar to the one about line-through #711; when author says "skip ink", should we skip ink regardless of how sane it is, or should we interpret "improve typography by skipping ink, but don't skip ink if insane."?
I think we prefer the latter, and let UA be smart enough to know when to skip and when not to.