[Webkit-unassigned] [Bug 18013] Margin auto: difference between centered divs and images in body background

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Feb 2 19:56:22 PST 2011


https://bugs.webkit.org/show_bug.cgi?id=18013


Eric Celeste <efc at clst.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |efc at clst.org




--- Comment #5 from Eric Celeste <efc at clst.org>  2011-02-02 19:56:22 PST ---
There is a nice description of this bug at http://www.hackvalue.nl/en/article/85/off-by-one_errors_in_background_placement_in_web_browsers with an even simpler example http://www.hackvalue.nl/bug.html available.

I have noticed that this bug can also result in a one pixel VERTICAL offset when using Mobile Safari (AppleWebKit/533.17.9) on iOS.

Using a wrapper div with the background-position exhibits the bug (both horizontal and vertical):


   background-image: url(images/rea-back.png);
   background-position: center top;

Using a wrapper div with the margin auto resolves the bug (both horizontal and vertical):

   background-image: url(images/rea-back.png);
   width: 1020px;
   margin: 0px auto;

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list