layout/reftests/box-sizing/computed-size-reporting-ref.html

Thu, 15 Jan 2015 21:03:48 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 15 Jan 2015 21:03:48 +0100
branch
TOR_BUG_9701
changeset 11
deefc01c0e14
permissions
-rw-r--r--

Integrate friendly tips from Tor colleagues to make (or not) 4.5 alpha 3;
This includes removal of overloaded (but unused) methods, and addition of
a overlooked call to DataStruct::SetData(nsISupports, uint32_t, bool.)

michael@0 1 <!DOCTYPE HTML>
michael@0 2 <meta charset=utf-8>
michael@0 3 <title>Bug 520992</title>
michael@0 4
michael@0 5 <style>
michael@0 6 #borderBox {
michael@0 7 background:gold;
michael@0 8 height:100px;
michael@0 9 box-sizing:border-box;
michael@0 10 }
michael@0 11
michael@0 12 #paddingBox {
michael@0 13 background:gold;
michael@0 14 height:100px;
michael@0 15 box-sizing:padding-box;
michael@0 16 }
michael@0 17
michael@0 18 </style>
michael@0 19
michael@0 20 <div id="borderBox"></div>
michael@0 21 <p id="heightWidth1"></p>
michael@0 22
michael@0 23 <div id="paddingBox"></div>
michael@0 24 <p id="heightWidth2"></p>
michael@0 25 <script>
michael@0 26 var divs = document.getElementsByTagName("div");
michael@0 27 var textEle1 = document.getElementById("heightWidth1");
michael@0 28 textEle1.innerHTML += "height = " + getComputedStyle(divs[0]).height;
michael@0 29 textEle1.innerHTML += ", width = " + getComputedStyle(divs[0]).width;
michael@0 30
michael@0 31 var textEle2 = document.getElementById("heightWidth2");
michael@0 32 textEle2.innerHTML += "height = " + getComputedStyle(divs[1]).height;
michael@0 33 textEle2.innerHTML += ", width = " + getComputedStyle(divs[1]).width;
michael@0 34 </script>

mercurial