Comment #1 on issue 23816 by Nige.Animal: Computed style margins return  
incorrect values.
http://code.google.com/p/chromium/issues/detail?id=23816

Don't believe it? Here's a simpler test page:

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

--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings

--~--~---------~--~----~------------~-------~--~----~
Automated mail from issue updates at http://crbug.com/
Subscription options: http://groups.google.com/group/chromium-bugs
-~----------~----~----~----~------~----~------~--~---

Reply via email to