[Webkit-unassigned] [Bug 24511] Computed style margins calculated incorrectly for sized elements.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Oct 6 03:11:51 PDT 2009


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





--- Comment #6 from Nigel White <nigelw at forwardcomputers.co.uk>  2009-10-06 03:11:50 PDT ---
The simple test:

<html>
<head>
<title>Margin bug</title>
<script type="text/javascript">
runTest = function() {
    var inner = document.getElementById("inner");
    var lm = parseInt(document.defaultView.getComputedStyle(inner,
null).marginLeft, 10);
    var rm = parseInt(document.defaultView.getComputedStyle(inner,
null).marginRight, 10);
    var m = lm + rm;
    inner.innerHTML ='My left+right margins are ' + m;
};
</script>
</head>
<body onload="runTest();">
<div id="outer" style="height:300px;width:500px;border:1px solid black">
    <div id="inner"
style="height:200px;width:200px;background-color:red"></div>
</div>
</body>
</html>

-- 
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