Bug 588271 - Part 1: Mask corners of some reftests because of AA differences. r=roc
authorBas Schouten <bschouten@mozilla.com>
Thu, 02 Dec 2010 14:17:52 +0100
changeset 58475 554d37bb2aff81d43091a4290aedfd9cea842df5
parent 58474 7ab0eb4c345b12838f45bfe19f3088be8025215a
child 58476 262d9ccb5da56d2e30bd89f3c35d5c9e025d19df
push idunknown
push userunknown
push dateunknown
reviewersroc
bugs588271
milestone2.0b8pre
Bug 588271 - Part 1: Mask corners of some reftests because of AA differences. r=roc
layout/reftests/table-bordercollapse/bordercol.css
layout/reftests/table-bordercollapse/frame_below_rules_none_ref.html
layout/reftests/table-bordercollapse/frame_border_rules_cols.html
layout/reftests/table-bordercollapse/frame_border_rules_none.html
layout/reftests/table-bordercollapse/frame_border_rules_none_ref.html
layout/reftests/table-bordercollapse/frame_box_rules_none.html
layout/reftests/table-bordercollapse/frame_box_rules_none_ref.html
--- a/layout/reftests/table-bordercollapse/bordercol.css
+++ b/layout/reftests/table-bordercollapse/bordercol.css
@@ -15,9 +15,10 @@ table.leftLight {border-left: 1px solid 
 table.right {border-right: 1px solid  black}
 table.rightDark {border-right: 1px solid #444444}
 table.top {border-top: 1px solid  black}
 table.left {border-left: 1px solid  black}
 table.bc {border-collapse:collapse}
 tbody.border{border-top: 1px solid  black; border-bottom: 1px solid black; }
 tr.border{border-top: 1px solid black; border-bottom: 1px solid  black; }
 td.border{border-left:1px solid black;}
+div.maskPixel{position:absolute; background-color:Black; width:1px; height:1px; }
 
--- a/layout/reftests/table-bordercollapse/frame_below_rules_none_ref.html
+++ b/layout/reftests/table-bordercollapse/frame_below_rules_none_ref.html
@@ -1,9 +1,9 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
 <html lang="en">
 <head>
 	<meta http-equiv="content-type" content="text/html; charset=UTF-8">
 	<title>Frame="below" and Rules="none"</title>
       <link rel="stylesheet" type="text/css" href="bordercol.css" />
 </head>
 <body>
 <table class="bottomDark">
--- a/layout/reftests/table-bordercollapse/frame_border_rules_cols.html
+++ b/layout/reftests/table-bordercollapse/frame_border_rules_cols.html
@@ -1,9 +1,9 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
 <html lang="en"><head>
 
 
 	<meta http-equiv="content-type" content="text/html; charset=UTF-8">
 	<title>Frame="border" and Rules="cols"</title>
 	<link rel="stylesheet" type="text/css" href="bordercol.css" />
 </head>
 <body>
--- a/layout/reftests/table-bordercollapse/frame_border_rules_none.html
+++ b/layout/reftests/table-bordercollapse/frame_border_rules_none.html
@@ -1,20 +1,29 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
 <html lang="en"><head>
 
 
 	<meta http-equiv="content-type" content="text/html; charset=UTF-8">
 	<title>Frame="border" and Rules="none"</title>
 	<link rel="stylesheet" type="text/css" href="bordercol.css" />
+        <script language=javascript>
+          function onReftestLoad() {
+            document.getElementById('topRightMask').style.left = (document.getElementById('tablehead').getBoundingClientRect().right + 2) + 'px';
+            document.getElementById('topRightMask').style.top = (document.getElementById('tablehead').getBoundingClientRect().top - 3) + 'px';
+            document.getElementById('bottomLeftMask').style.top = (document.getElementById('tablefooter').getBoundingClientRect().bottom + 2) + 'px';
+          }        
+        </script>
 </head>
-<body>
-<table rules="none" frame="border">
+<body onload='onReftestLoad();'>
+<div class="maskPixel" id="bottomLeftMask"></div>
+<div class="maskPixel" id="topRightMask"></div>
+<table rules="none" frame="border" id="testtable">
 	<caption><a name="void-none">Frame="border" and Rules="none"</caption>
-	<thead>
+	<thead id="tablehead">
 		<tr>
 			<td>Row 1, Cell 1</td>
 			<td>Row 1, Cell 2</td>
 			<td>Row 1, Cell 3</td>
 		</tr>
 	</thead>
 	<tbody>
 		<tr>
@@ -24,17 +33,17 @@
 		<tr>
 			<td>Row 3, Cell 2</td>
 			<td rowspan="2">Row 3, Cell 3</td>
 		</tr>
 		<tr>
 			<td colspan="2">Row 4, Cell 1</td>
 		</tr>
 	</tbody>
-	<tfoot>
+	<tfoot id='tablefooter'>
 		<tr>
 			<td>Row 5, Cell 1</td>
 			<td>Row 5, Cell 2</td>
 			<td>Row 5, Cell 3</td>
 		</tr>
 	</tfoot>
 </table>
 
--- a/layout/reftests/table-bordercollapse/frame_border_rules_none_ref.html
+++ b/layout/reftests/table-bordercollapse/frame_border_rules_none_ref.html
@@ -1,19 +1,28 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
 <html lang="en">
 <head>
 	<meta http-equiv="content-type" content="text/html; charset=UTF-8">
 	<title>Frame="border" and Rules="none"</title>
       <link rel="stylesheet" type="text/css" href="bordercol.css" />
+      <script language=javascript>
+        function onReftestLoad() {
+          document.getElementById('topRightMask').style.left = (document.getElementById('tablehead').getBoundingClientRect().right + 2) + 'px';
+          document.getElementById('topRightMask').style.top = (document.getElementById('tablehead').getBoundingClientRect().top - 3) + 'px';
+          document.getElementById('bottomLeftMask').style.top = (document.getElementById('tablefooter').getBoundingClientRect().bottom + 2) + 'px';
+        }        
+      </script>
 </head>
-<body>
+<body onload='onReftestLoad();'>
+<div class="maskPixel" id="bottomLeftMask"></div>
+<div class="maskPixel" id="topRightMask"></div>
 <table class="leftLight topLight rightDark  bottomDark">
 	<caption><a name="void-none">Frame="border" and Rules="none"</caption>
-	<thead>
+	<thead id="tablehead">
 		<tr>
 			<td>Row 1, Cell 1</td>
 			<td>Row 1, Cell 2</td>
 			<td>Row 1, Cell 3</td>
 		</tr>
 	</thead>
 	<tbody>
 		<tr>
@@ -23,17 +32,17 @@
 		<tr>
 			<td>Row 3, Cell 2</td>
 			<td rowspan="2">Row 3, Cell 3</td>
 		</tr>
 		<tr>
 			<td colspan="2">Row 4, Cell 1</td>
 		</tr>
 	</tbody>
-	<tfoot>
+	<tfoot id='tablefooter'>
 		<tr>
 			<td>Row 5, Cell 1</td>
 			<td>Row 5, Cell 2</td>
 			<td>Row 5, Cell 3</td>
 		</tr>
 	</tfoot>
 </table>
 
--- a/layout/reftests/table-bordercollapse/frame_box_rules_none.html
+++ b/layout/reftests/table-bordercollapse/frame_box_rules_none.html
@@ -1,20 +1,29 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
 <html lang="en"><head>
 
 
 	<meta http-equiv="content-type" content="text/html; charset=UTF-8">
 	<title>Frame="box" and Rules="none"</title>
 	<link rel="stylesheet" type="text/css" href="bordercol.css" />
+        <script language=javascript>
+          function onReftestLoad() {
+            document.getElementById('topRightMask').style.left = (document.getElementById('tablehead').getBoundingClientRect().right + 2) + 'px';
+            document.getElementById('topRightMask').style.top = (document.getElementById('tablehead').getBoundingClientRect().top - 3) + 'px';
+            document.getElementById('bottomLeftMask').style.top = (document.getElementById('tablefooter').getBoundingClientRect().bottom + 2) + 'px';
+          }        
+        </script>
 </head>
-<body>
+<body onload='onReftestLoad();'>
+<div class="maskPixel" id="bottomLeftMask"></div>
+<div class="maskPixel" id="topRightMask"></div>
 <table rules="none" frame="box">
 	<caption><a name="void-none">Frame="box" and Rules="none"</caption>
-	<thead>
+	<thead id="tablehead">
 		<tr>
 			<td>Row 1, Cell 1</td>
 			<td>Row 1, Cell 2</td>
 			<td>Row 1, Cell 3</td>
 		</tr>
 	</thead>
 	<tbody>
 		<tr>
@@ -24,17 +33,17 @@
 		<tr>
 			<td>Row 3, Cell 2</td>
 			<td rowspan="2">Row 3, Cell 3</td>
 		</tr>
 		<tr>
 			<td colspan="2">Row 4, Cell 1</td>
 		</tr>
 	</tbody>
-	<tfoot>
+	<tfoot id='tablefooter'>
 		<tr>
 			<td>Row 5, Cell 1</td>
 			<td>Row 5, Cell 2</td>
 			<td>Row 5, Cell 3</td>
 		</tr>
 	</tfoot>
 </table>
 
--- a/layout/reftests/table-bordercollapse/frame_box_rules_none_ref.html
+++ b/layout/reftests/table-bordercollapse/frame_box_rules_none_ref.html
@@ -1,19 +1,28 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
 <html lang="en">
 <head>
 	<meta http-equiv="content-type" content="text/html; charset=UTF-8">
 	<title>Frame="box" and Rules="none"</title>
       <link rel="stylesheet" type="text/css" href="bordercol.css" />
+      <script language=javascript>
+        function onReftestLoad() {
+          document.getElementById('topRightMask').style.left = (document.getElementById('tablehead').getBoundingClientRect().right + 2) + 'px';
+          document.getElementById('topRightMask').style.top = (document.getElementById('tablehead').getBoundingClientRect().top - 3) + 'px';
+          document.getElementById('bottomLeftMask').style.top = (document.getElementById('tablefooter').getBoundingClientRect().bottom + 2) + 'px';
+        }        
+      </script>
 </head>
-<body>
+<body onload='onReftestLoad();'>
+<div class="maskPixel" id="bottomLeftMask"></div>
+<div class="maskPixel" id="topRightMask"></div>
 <table class="rightDark leftLight topLight bottomDark">
 	<caption><a name="void-none">Frame="box" and Rules="none"</caption>
-	<thead>
+	<thead id="tablehead">
 		<tr>
 			<td>Row 1, Cell 1</td>
 			<td>Row 1, Cell 2</td>
 			<td>Row 1, Cell 3</td>
 		</tr>
 	</thead>
 	<tbody>
 		<tr>
@@ -23,17 +32,17 @@
 		<tr>
 			<td>Row 3, Cell 2</td>
 			<td rowspan="2">Row 3, Cell 3</td>
 		</tr>
 		<tr>
 			<td colspan="2">Row 4, Cell 1</td>
 		</tr>
 	</tbody>
-	<tfoot>
+	<tfoot id='tablefooter'>
 		<tr>
 			<td>Row 5, Cell 1</td>
 			<td>Row 5, Cell 2</td>
 			<td>Row 5, Cell 3</td>
 		</tr>
 	</tfoot>
 </table>