Break underlines for descenders

UNCONFIRMED
Unassigned

Status

()

Core
Layout: Block and Inline
UNCONFIRMED
4 years ago
3 months ago

People

(Reporter: Erwann Mest, Unassigned)

Tracking

32 Branch
x86
Mac OS X
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

4 years ago
Created attachment 8433172 [details]
BpKMTnpIQAIoPOZ.png_large.png

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:32.0) Gecko/20100101 Firefox/32.0 (Beta/Release)
Build ID: 20140602072051

Steps to reproduce:

On Safari beta for Yosemite, it breaks underlines for descenders. Firefox should also do that.

Comment 1

4 years ago
I'm tempted to dup this on bug 812990 as it will implement text-decoration-skip: ink; it actually looks like safari breaks the specifications here as the initial value is meant to be "objects" not "objects ink".

Updated

4 years ago
See Also: → bug 812990
Component: Untriaged → Layout: Block and Inline
Product: Firefox → Core

Comment 2

4 years ago
The initial value for new properties is chosen largely due to compat concerns. If it's better and doesn't break a lot of sites to have a different initial value, we could ask the CSSWG to change the initial value.

Comment 3

5 months ago
According to 
CSS2.x, section E.2 Painting order
https://www.w3.org/TR/CSS21/zindex.html#painting-order
and
https://www.w3.org/TR/CSS22/zindex.html#painting-order
(look for 
4. For inline elements:
  1.
    1.
      1. any underlining affecting the text of the element (...) and 3. the text. 
)
underlining painting is done before glyphs are painted; therefore, if the underlining crosses the descenders (glyphs like 'g', 'j', 'p', 'q', 'y' have a descender), then the descender part must overlap the underline. This is also re-confirmed by CSS3 Text-decoration:

https://www.w3.org/TR/css-text-decor-3/#underline-auto

The descender of black "p" overlaps the blue underline in figure 3. 

We have a test 
(you must install Ahem font for this test:
AHEM____.TTF
from
https://www.w3.org/Style/CSS/Test/Fonts/Ahem/
)
on this:

http://test.csswg.org/suites/css2.1/nightly-unstable/html4/painting-order-underline-001.htm

Firefox 52+ and Chrome 60+ pass this test.

attachment 8433172 [details] would be good, correct for a 'text-decoration-skip: ink' test.

Comment 4

3 months ago
Sounds likes Chrome has just implemented this. Any chance we can get it triaged and maybe confirmed and assigned?
You need to log in before you can comment on or make changes to this bug.