Last Comment Bug 572713 - On hover text gets underlined
: On hover text gets underlined
Status: RESOLVED FIXED
: regression, testcase
Product: Core
Classification: Components
Component: Layout (show other bugs)
: Trunk
: All All
: P3 normal with 1 vote (vote)
: mozilla2.0b8
Assigned To: David Baron :dbaron: ⌚️UTC-10
:
: Jet Villegas (:jet)
Mentors:
http://www.netwerknotarissen.nl/page....
: 562039 601425 (view as bug list)
Depends on:
Blocks: 224633 html5-parsing 610454
  Show dependency treegraph
 
Reported: 2010-06-17 09:08 PDT by Martijn Wargers [:mwargers] (not working for Mozilla)
Modified: 2011-08-10 17:35 PDT (History)
10 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---
betaN+


Attachments
testcase (219 bytes, text/html)
2010-06-17 09:08 PDT, Martijn Wargers [:mwargers] (not working for Mozilla)
no flags Details
additional testcases (457 bytes, application/xhtml+xml)
2010-10-19 17:45 PDT, David Baron :dbaron: ⌚️UTC-10
no flags Details
more HTML testcases, standards mode (489 bytes, text/html; charset=UTF-8)
2010-11-18 17:43 PST, David Baron :dbaron: ⌚️UTC-10
no flags Details
more HTML testcases, quirks mode (472 bytes, text/html; charset=UTF-8)
2010-11-18 17:44 PST, David Baron :dbaron: ⌚️UTC-10
no flags Details
more HTML testcases, standards mode (706 bytes, text/html; charset=UTF-8)
2010-11-18 18:08 PST, David Baron :dbaron: ⌚️UTC-10
no flags Details
more HTML testcases, quirks mode (689 bytes, text/html; charset=UTF-8)
2010-11-18 18:08 PST, David Baron :dbaron: ⌚️UTC-10
no flags Details
less-related testcases, standards mode (983 bytes, text/html; charset=UTF-8)
2010-11-19 11:05 PST, David Baron :dbaron: ⌚️UTC-10
no flags Details
less-related testcases, quirks mode (967 bytes, text/html; charset=UTF-8)
2010-11-19 11:06 PST, David Baron :dbaron: ⌚️UTC-10
no flags Details
less-related testcases, standards mode (995 bytes, text/html; charset=UTF-8)
2010-11-19 11:08 PST, David Baron :dbaron: ⌚️UTC-10
no flags Details
less-related testcases, quirks mode (979 bytes, text/html; charset=UTF-8)
2010-11-19 11:08 PST, David Baron :dbaron: ⌚️UTC-10
no flags Details
more quirks mode table cases (1.14 KB, text/html; charset=UTF-8)
2010-11-19 11:17 PST, David Baron :dbaron: ⌚️UTC-10
no flags Details
quirks mode which-table-element testcases (634 bytes, text/html; charset=UTF-8)
2010-11-19 11:28 PST, David Baron :dbaron: ⌚️UTC-10
no flags Details
patch (16.08 KB, patch)
2010-11-19 16:03 PST, David Baron :dbaron: ⌚️UTC-10
roc: review+
Details | Diff | Splinter Review

Description Martijn Wargers [:mwargers] (not working for Mozilla) 2010-06-17 09:08:24 PDT
Created attachment 451971 [details]
testcase

On the url, when hovering over the text, it gets underlined. This doesn't happen on branch builds, because the parser terminates the <a>-tag directly.
This doesn't happen anymore with the new html5 parser. IE and Google Chrome also don't seem to do this, but they don't underline the text either, so perhaps Mozilla should have some default css rule to prevent text inside tables to get underlined when the table is also inside an anchor?
Comment 1 David Baron :dbaron: ⌚️UTC-10 2010-06-17 13:01:48 PDT
There are a bunch of competing issues in this testcase:  parsing, block-within-inline handling, and the rules for propagation of text-decoration.  We have some known bugs with the last, but I don't remember exactly what the spec says for text-decoration rules.
Comment 2 Henri Sivonen (:hsivonen) 2010-06-18 01:39:27 PDT
The same parses the same way in Minefield and Chrome beta channel.
Comment 3 Henri Sivonen (:hsivonen) 2010-06-23 05:18:21 PDT
*** Bug 562039 has been marked as a duplicate of this bug. ***
Comment 4 j.j. 2010-10-03 06:39:29 PDT
*** Bug 601425 has been marked as a duplicate of this bug. ***
Comment 5 j.j. 2010-10-03 06:51:59 PDT
This bug is quirksmode only.

Request blocking because it affects Ebay forums (bug 601425). I saw it on other sites as well.
Comment 6 Boris Zbarsky [:bz] (still a bit busy) 2010-10-03 11:59:58 PDT
> This bug is quirksmode only.

Yes, see the "text-decoration" part of comment 1.
Comment 7 David Baron :dbaron: ⌚️UTC-10 2010-10-12 14:43:40 PDT
According to the (still member confidential, unfortunately) editor's draft of CSS 2.1, our text-decoration behavior here is correct.
Comment 8 David Baron :dbaron: ⌚️UTC-10 2010-10-12 14:50:41 PDT
The text in question in the editor's draft is the first bit of:
http://lists.w3.org/Archives/Public/www-style/2010Aug/0334.html
Comment 9 David Baron :dbaron: ⌚️UTC-10 2010-10-19 17:44:25 PDT
Then again, Chromium has too much underlining on these tests (whereas we have too little):
http://test.csswg.org/suites/css2.1/20101001/xhtml1/text-decoration-086.xht
http://test.csswg.org/suites/css2.1/20101001/xhtml1/text-decoration-088.xht
http://test.csswg.org/suites/css2.1/20101001/html4/text-decoration-086.htm
http://test.csswg.org/suites/css2.1/20101001/html4/text-decoration-088.htm
but still doesn't underline the text in attachment 451971 [details].

However, the actual relevant difference in our text-decoration behavior isn't the handling of inlines, it's the handling of tables.  Chromium doesn't propagate text-decorations into a table from anything (block or inline) outside of it; we do (as I *think* is required by the spec).
Comment 10 David Baron :dbaron: ⌚️UTC-10 2010-10-19 17:45:15 PDT
Created attachment 484575 [details]
additional testcases
Comment 11 David Baron :dbaron: ⌚️UTC-10 2010-10-19 17:58:32 PDT
http://lists.w3.org/Archives/Public/www-style/2010Oct/0407.html
Comment 12 David Baron :dbaron: ⌚️UTC-10 2010-10-19 17:59:01 PDT
(And I'd note the CSS 2.1 test suite has no tests testing propagation into tables.)
Comment 13 David Baron :dbaron: ⌚️UTC-10 2010-11-18 17:43:40 PST
Created attachment 491732 [details]
more HTML testcases, standards mode
Comment 14 David Baron :dbaron: ⌚️UTC-10 2010-11-18 17:44:11 PST
Created attachment 491734 [details]
more HTML testcases, quirks mode
Comment 15 David Baron :dbaron: ⌚️UTC-10 2010-11-18 18:08:01 PST
Created attachment 491738 [details]
more HTML testcases, standards mode
Comment 16 David Baron :dbaron: ⌚️UTC-10 2010-11-18 18:08:34 PST
Created attachment 491739 [details]
more HTML testcases, quirks mode
Comment 17 David Baron :dbaron: ⌚️UTC-10 2010-11-18 18:17:10 PST
based on attachment 491738 [details] and attachment 491739 [details]:

Differences between mozilla-central and Firefox 3.6:
 * propagation of standards-mode text-decoration from blocks to tables (we now underline)
 * parsing of <a> without an </a> (quirky handling removed)

Differences between mozilla-central and Chromium:
 * propagation of standards-mode text-decoration from blocks to tables (we underline)
 * propagation of quirks-mode text-decoration from blocks and inlines to tables (we underline)

Differences between mozilla-central and Opera:
 * propagation of standards-mode text-decoration from inlines to tables (they underline)
 * propagation of quirks-mode text-decoration from blocks and inlines to tables (we underline)

I'd like to test IE7, IE8, and IE9, but given what I know so far, I think Opera's behavior is the most sensible, and we should make our quirks-mode text-decoration handling more quirky and (perhaps not in this bug) our standards-mode text-decoration handling follow the spec.
Comment 18 David Baron :dbaron: ⌚️UTC-10 2010-11-18 18:20:10 PST
It looks like IE8 matches Opera (I'd need to double-check the standards-mode case, but I'm pretty sure I'm remembering the quirks-mode case correctly).
Comment 19 David Baron :dbaron: ⌚️UTC-10 2010-11-18 18:22:55 PST
However, the original URL for the testcases for this bug and bug 562039 are in standards mode.

That said, the eBay forums (bug 601425) are in quirks mode; they're probably the most important to fix.
Comment 20 David Baron :dbaron: ⌚️UTC-10 2010-11-18 18:24:33 PST
That said, I don't see any problems on the two pages that are in standards mode (http://www.netwerknotarissen.nl/page.asp?id=10722&menu=8&kid=2 and http://www.camino.pl/ ).
Comment 21 David Baron :dbaron: ⌚️UTC-10 2010-11-19 11:05:29 PST
Created attachment 491883 [details]
less-related testcases, standards mode
Comment 22 David Baron :dbaron: ⌚️UTC-10 2010-11-19 11:06:00 PST
Created attachment 491885 [details]
less-related testcases, quirks mode
Comment 23 David Baron :dbaron: ⌚️UTC-10 2010-11-19 11:08:10 PST
Created attachment 491887 [details]
less-related testcases, standards mode
Comment 24 David Baron :dbaron: ⌚️UTC-10 2010-11-19 11:08:37 PST
Created attachment 491888 [details]
less-related testcases, quirks mode
Comment 25 David Baron :dbaron: ⌚️UTC-10 2010-11-19 11:17:36 PST
Created attachment 491892 [details]
more quirks mode table cases
Comment 26 David Baron :dbaron: ⌚️UTC-10 2010-11-19 11:28:33 PST
Created attachment 491898 [details]
quirks mode which-table-element testcases
Comment 27 David Baron :dbaron: ⌚️UTC-10 2010-11-19 11:59:47 PST
I have a patch, but want to write additional tests.

I'm planning to make two changes:
 * don't propagate quirks-mode text-decoration across HTML table elements, to fix this bug (and compat with WebKit (mostly, though it also does the same for display:table) and IE)
 * don't propagate quirks-mode text-decoration across inline-block and inline-table, to match spec and WebKit

I'm also setting up the quirks-mode code to be usable for all modes.  This means that I make the first of the above two fixes conditioned on quirks mode but the second apply to all modes, and additionally add a standards-mode check for floating and abs-pos to match the spec's propagation rules.
Comment 28 David Baron :dbaron: ⌚️UTC-10 2010-11-19 16:03:37 PST
Created attachment 491983 [details] [diff] [review]
patch

See comment 27 for explanation.
Comment 29 David Baron :dbaron: ⌚️UTC-10 2010-11-21 15:53:59 PST
http://hg.mozilla.org/mozilla-central/rev/4847e1cf6cf4

Note You need to log in before you can comment on or make changes to this bug.