New issue
Advanced search Search tips

Issue 845902 link

Starred by 1 user

Issue metadata

Status: Duplicate
Merged: issue 40634
Owner: ----
Closed: May 2018
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug



Sign in to add a comment

Intrinsic size and quirky line height calculation affected by collapsed whitespace before forced break

Project Member Reported by mstensho@chromium.org, May 23 2018

Issue description

This fails with the legacy layout engine, but not in LayoutNG:

<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
<div style="width:fit-content; background:red;">
  <div style="display:inline-block; vertical-align:top; width:100px; height:100px; background:green;"></div>
  <br>
</div>

Probably not worth fixing in the legacy engine.
 
Project Member

Comment 1 by bugdroid1@chromium.org, May 24 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/272f0cea27574ab2c14c44b0488cdd826be94dcf

commit 272f0cea27574ab2c14c44b0488cdd826be94dcf
Author: Morten Stenshorne <mstensho@chromium.org>
Date: Thu May 24 08:48:50 2018

[LayoutNG] Rebaseline intrinsic sizing test that actually passes.

Legacy layout is buggy here, so the expected rendering was wrong. Also
wrote a new wpt test for this. When calculating intrinsic size, the
legacy engine makes room for whitespace that is to be collapsed.

Bug:  845902 
Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: I77087577aad68dc249ca33a8ac8a79ef4f35469e
Reviewed-on: https://chromium-review.googlesource.com/1070270
Reviewed-by: Emil A Eklund <eae@chromium.org>
Commit-Queue: Morten Stenshorne <mstensho@chromium.org>
Cr-Commit-Position: refs/heads/master@{#561428}
[modify] https://crrev.com/272f0cea27574ab2c14c44b0488cdd826be94dcf/third_party/WebKit/LayoutTests/FlagExpectations/enable-blink-features=LayoutNG
[modify] https://crrev.com/272f0cea27574ab2c14c44b0488cdd826be94dcf/third_party/WebKit/LayoutTests/TestExpectations
[add] https://crrev.com/272f0cea27574ab2c14c44b0488cdd826be94dcf/third_party/WebKit/LayoutTests/external/wpt/css/css-sizing/whitespace-and-break.html
[add] https://crrev.com/272f0cea27574ab2c14c44b0488cdd826be94dcf/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/block/float/float-in-float-painting-expected.png
[add] https://crrev.com/272f0cea27574ab2c14c44b0488cdd826be94dcf/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/block/float/float-in-float-painting-expected.txt

Summary: Intrinsic size and quirky line height calculation affected by collapsed whitespace before forced break (was: Intrinsic size calculation affected by collapsed whitespace before break)
Here's another very similar problem. I'm not 100% sure it's the same bug, but they do seem very similar, and I guess we have no intent to fix any of them.
quirky-line-height.html
285 bytes View Download
Maybe because of issue 40634?
Mergedinto: 40634
Status: Duplicate (was: WontFix)
That's it! How could I forget about that one? I was involved with an other duplicate less than a month ago. Oh well, I'll mark it as a duplicate now. Thank you for pointing this out!
Project Member

Comment 5 by bugdroid1@chromium.org, Nov 21

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f570d28fd1a34ea3c8ebe1bc7662e84713e5ba6f

commit f570d28fd1a34ea3c8ebe1bc7662e84713e5ba6f
Author: Morten Stenshorne <mstensho@chromium.org>
Date: Wed Nov 21 21:19:26 2018

[LayoutNG] Rebaseline quirky test that actually passes.

(writing-mode has nothing to do with it, FWIW)

Legacy layout is buggy here, so the expected rendering was wrong. Also
wrote a new wpt test for this. When calculating quirky line height, the
legacy engine makes room for whitespace that is to be collapsed.

Bug:  845902 
Change-Id: I004d024578bb147d4f70c58fc1e3213a14174fd7
Reviewed-on: https://chromium-review.googlesource.com/c/1346465
Reviewed-by: Koji Ishii <kojii@chromium.org>
Commit-Queue: Morten Stenshorne <mstensho@chromium.org>
Cr-Commit-Position: refs/heads/master@{#610216}
[modify] https://crrev.com/f570d28fd1a34ea3c8ebe1bc7662e84713e5ba6f/third_party/WebKit/LayoutTests/FlagExpectations/enable-blink-features=LayoutNG
[modify] https://crrev.com/f570d28fd1a34ea3c8ebe1bc7662e84713e5ba6f/third_party/WebKit/LayoutTests/TestExpectations
[add] https://crrev.com/f570d28fd1a34ea3c8ebe1bc7662e84713e5ba6f/third_party/WebKit/LayoutTests/external/wpt/quirks/line-height-trailing-collapsable-whitespace-ref.html
[add] https://crrev.com/f570d28fd1a34ea3c8ebe1bc7662e84713e5ba6f/third_party/WebKit/LayoutTests/external/wpt/quirks/line-height-trailing-collapsable-whitespace.html
[add] https://crrev.com/f570d28fd1a34ea3c8ebe1bc7662e84713e5ba6f/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/writing-mode/fieldsets-expected.png

Sign in to add a comment