New issue
Advanced search Search tips

Issue 707720 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner: ----
Closed: Apr 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 3
Type: Bug



Sign in to add a comment

Strange difference between a single line paragraph vs a multi-line one

Project Member Reported by r...@igalia.com, Apr 3 2017

Issue description


I stumbled upon this strange issue while working on something completely unrelated.

The problem appears if you have a layout test where the original file
and the reference only varies in the number of lines but not the content.

Basically the following simple test:
<!DOCTYPE html>
<p>Test passes if, when the element below is focused,
it is surrounded by a thick green border.
There must be no red or blue once it is focused.</p>

vs the 1-line version:
<!DOCTYPE html>
<p>Test passes if, when the element below is focused, it is surrounded by a thick green border. There must be no red or blue once it is focused.</p>

I created a CL to test this and it only fails on Mac:
https://codereview.chromium.org/2788683004/
The diff seems to be around *be no red* letters.

On Linux I cannot reproduce it, however on HDPI screens I can see a small difference
if I use zoom (the test still passes though).

Dunno if this is a fonts issue or something else, but it was really strange
to get a failure in a test due to this. :-)
 
my-test.html
200 bytes View Download
my-test-expected.html
200 bytes View Download
my-test-diff.png
5.0 KB View Download

Comment 1 by rtoy@chromium.org, Apr 4 2017

Components: -Blink Blink>Layout

Comment 2 by e...@chromium.org, Apr 6 2017

Status: WontFix (was: Untriaged)
This has to do with snapping of line boxes and whitespace collapsing. With the current line layout implementation we cannot make any guarantees about pixel perfect rendering if the source content has different amounts of whitspace.

LayoutNG will fix this as it seprates white space collapsing into a separate pipeline stage and merges adjacent items before painting.

Comment 3 by r...@igalia.com, Apr 7 2017

@eae thanks for the info. I was somehow suspecting this was already a known issue.

Sign in to add a comment