Last Comment Bug 714519 - [quirks] list bullet/number disappears when item that wraps has all contents in 2 nested inlines and inner inline has vertical-align: top/bottom
: [quirks] list bullet/number disappears when item that wraps has all contents ...
Product: Core
Classification: Components
Component: Layout: Block and Inline (show other bugs)
: Trunk
: All All
P4 normal (vote)
: mozilla12
Assigned To: David Baron :dbaron: ⌚️UTC-8
: Jet Villegas (:jet)
Depends on:
  Show dependency treegraph
Reported: 2012-01-01 07:55 PST by David Baron :dbaron: ⌚️UTC-8
Modified: 2012-01-02 09:38 PST (History)
5 users (show)
ryanvm: in‑testsuite+
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---

testcase (385 bytes, text/html)
2012-01-01 07:55 PST, David Baron :dbaron: ⌚️UTC-8
no flags Details
original (less simplified) testcase (2.00 KB, text/html)
2012-01-01 07:56 PST, David Baron :dbaron: ⌚️UTC-8
no flags Details
patch (6.97 KB, patch)
2012-01-01 11:36 PST, David Baron :dbaron: ⌚️UTC-8
roc: review+
Details | Diff | Splinter Review

Description User image David Baron :dbaron: ⌚️UTC-8 2012-01-01 07:55:36 PST
Created attachment 585204 [details]

This is simplified from a report on css-d on December 23; original was

In quirks mode or almost-standards mode, the list bullet or number disappears when:
 (a) a list item wraps to two lines, and
 (b) the entire contents of the list item are nested within two (or more) inlines, and an inline other than the outer one has vertical-align: top or bottom

The underlying reason for this is a bug in nsLineLayout::IsZeroHeight() (in layout/generic/nsLineLayout.cpp).  What it does to check for the line being zero height is not sufficient in quirks mode; it needs to look inside the children of the line since there might be top/bottom aligned frames that don't influence the height of their parent.

This breaks nsBlockFrame::PlaceLine (which uses two different tests for emptiness).

Then again, maybe we should fix this by limiting the inline layout quirks when there are top/bottom children, since that would also fix the text-decoration issue with the original testcase.
Comment 1 User image David Baron :dbaron: ⌚️UTC-8 2012-01-01 07:56:44 PST
Created attachment 585205 [details]
original (less simplified) testcase

... saved from url in comment 0.
Comment 2 User image David Baron :dbaron: ⌚️UTC-8 2012-01-01 11:36:38 PST
Created attachment 585219 [details] [diff] [review]
Comment 3 User image David Baron :dbaron: ⌚️UTC-8 2012-01-01 14:39:54 PST
Comment 4 User image Phil Ringnalda (:philor) 2012-01-01 21:10:00 PST

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