New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 675689 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner: ----
Closed: Oct 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Mac
Pri: 2
Type: Bug



Sign in to add a comment

Wrong interpretation of 4-values syntax for background-position with edge offsets

Reported by bj.b...@gmail.com, Dec 19 2016

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:50.0) Gecko/20100101 Firefox/50.0

Steps to reproduce the problem:
1. Assign a repeating background-image to an element.
2. Set background-position to, for example, "right 0px bottom 0px".

What is the expected behavior?
The right bottom corner of the background image should be aligned with the right bottom corner of the element.

What went wrong?
The alignment is not correct. The situation gets even worse when offsets different from 0 are used.

Did this work before? N/A 

Does this work in other browsers? Yes

Chrome version: 55.0.2883.87  Channel: stable
OS Version: 10.0
Flash Version: 

JSFiddle: https://jsfiddle.net/boa9ct0c/1/

The alignment is correct if the background image is not repeating.
 
bug.html
550 bytes View Download
bug.png
126 KB View Download

Comment 1 by ajha@chromium.org, Dec 20 2016

Labels: M-55 prestable-55.0.2883.87
Labels: needs
Status: Untriaged (was: Unconfirmed)
Labels: -needs Needs-Bisect
Cc: brajkumar@chromium.org
Labels: -Needs-Bisect OS-Linux OS-Mac
Able to reproduce this issue on Windows-10, Ubuntu 14.04 and Mac OS 10.12 using chrome latest stable M55-55.0.2883.87. By opening the provided test case link observed the the alignment is not correct as seen in firefox.

Tested the same on chrome earlier version of M35-35.0.1849.0 and observed the letters are getting chopped at the bottom. Considering this is a non-regression issue and marking it as untriaged.

Note: Attaching M-35 screen-shot for reference.

Thanks!
M35.PNG
304 KB View Download
Status: Available (was: Untriaged)

Comment 6 by meade@chromium.org, Feb 13 2017

Labels: Update-Quarterly
Project Member

Comment 7 by bugdroid1@chromium.org, Feb 23 2017

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

commit e9e49a4e35605dfeb0511c751613596d7b16463b
Author: shoon.kim <shoon.kim@lge.com>
Date: Thu Feb 23 19:15:20 2017

Fix repeat background position problem

In the case of right and bottom edge, the factional position within tile
should be calculated in same manner on left and top edge.

BUG= 675689 
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2

Review-Url: https://codereview.chromium.org/2709153003
Cr-Commit-Position: refs/heads/master@{#452576}

[add] https://crrev.com/e9e49a4e35605dfeb0511c751613596d7b16463b/third_party/WebKit/LayoutTests/fast/backgrounds/background-position-repeat-rendering-2-expected.html
[add] https://crrev.com/e9e49a4e35605dfeb0511c751613596d7b16463b/third_party/WebKit/LayoutTests/fast/backgrounds/background-position-repeat-rendering-2.html
[modify] https://crrev.com/e9e49a4e35605dfeb0511c751613596d7b16463b/third_party/WebKit/Source/core/paint/BackgroundImageGeometry.cpp

Comment 8 by shend@chromium.org, Oct 12 2017

Status: Fixed (was: Available)
This looks fixed in #c7?

Sign in to add a comment