Closed Bug 1321703 Opened 3 years ago Closed 3 years ago

[css-align] Synthesizing a baseline from a block line with a non-visible-overflow kid is using the border-box

Categories

(Core :: Layout: Block and Inline, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla53
Tracking Status
firefox53 --- fixed

People

(Reporter: mats, Assigned: mats)

Details

(Keywords: testcase, Whiteboard: [parity-chrome][parity-edge][parity-ie11])

Attachments

(3 files)

Attached file Testcase #1
Chrome, Edge and IE11 is using the margin-box.
I think we should do the same for compatibility.
OS: Unspecified → All
Hardware: Unspecified → All
Version: 51 Branch → unspecified
Attached patch fixSplinter Review
Attachment #8816436 - Flags: review?(dholbert)
Attached patch reftestSplinter Review
Comment on attachment 8816436 [details] [diff] [review]
fix

Review of attachment 8816436 [details] [diff] [review]:
-----------------------------------------------------------------

r=me, one nit:

::: layout/base/nsLayoutUtils.cpp
@@ +5942,5 @@
>            kid->GetLogicalNormalPosition(aWM, containerSize).B(aWM);
>          return true;
>        } else if (kid->GetType() == nsGkAtoms::scrollFrame) {
> +        // Synthesize a baseline from the margin-box.
> +        kidBaseline = kid->GetLogicalBaseline(aWM);

I didn't initially understand the connection between this comment and the code that follows (which doesn't mention margin/margin-box at all).  Could you reword that to make it a bit clearer?

Maybe something like "Defer to scrollframe's GetLogicalBaseline method (which synthesizes a baseline from the margin-box)"
Attachment #8816436 - Flags: review?(dholbert) → review+
Pushed by mpalmgren@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/bd4568a3fd8b
Use the margin-box when synthesizing a baseline from a block line with a non-visible-overflow child frame.  r=dholbert
https://hg.mozilla.org/integration/mozilla-inbound/rev/90ad2f05b90d
Reftest.
Flags: in-testsuite+
https://hg.mozilla.org/mozilla-central/rev/bd4568a3fd8b
https://hg.mozilla.org/mozilla-central/rev/90ad2f05b90d
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla53
You need to log in before you can comment on or make changes to this bug.