WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED CONFIGURATION CHANGED
95647
Margins in percentage are not always referring to the width of the container
https://bugs.webkit.org/show_bug.cgi?id=95647
Summary
Margins in percentage are not always referring to the width of the container
dzmail90-dev
Reported
2012-09-01 10:31:37 PDT
In current WebKit builds, when these conditions are met: - a container block has the value absolute, relative or fixed on property position - and a content block has the property position:absolute then the margin-top and margin-bottom property of the content, when expressed in percentages, are NOT referring to the width of the containing block, but they are referring to the height of the containing block. This is in contrast to what Firefox and Opera do: they always use the width of the container to calculate the margin (top/bottom/right/left) of the content when it is expressed in percentage. A test case is visible here:
http://jsfiddle.net/YyBeV/12/
Attachments
Add attachment
proposed patch, testcase, etc.
Brent Fulgham
Comment 1
2022-07-13 10:56:59 PDT
Safari, Chrome, and Firefox all agree on rendering for this test case. I don't believe there is any remaining compatibility issue.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug