Bug 518357, make reftests less sensitive to default font size settings. r=roc
authorJonathan Kew <jfkthame@gmail.com>
Wed, 23 Sep 2009 15:55:55 +0100
changeset 33064 d88156be6c3fd9ab9281ca992e208b7fdc23e50f
parent 33063 440ef24cd6b337982481a9e5e90eab5997c07acb
child 33065 844d2970be5f6c2184205067f06c0f6d4223bb45
push idunknown
push userunknown
push dateunknown
reviewersroc
bugs518357
milestone1.9.3a1pre
Bug 518357, make reftests less sensitive to default font size settings. r=roc
layout/reftests/bidi/413928-1-ref.html
layout/reftests/bidi/413928-1.html
layout/reftests/bidi/413928-2-ref.html
layout/reftests/bidi/413928-2.html
layout/reftests/box-shadow/boxshadow-inner-basic-ref.html
layout/reftests/box-shadow/boxshadow-inner-basic.html
layout/reftests/bugs/134706-5-ref.html
layout/reftests/bugs/134706-5.html
layout/reftests/bugs/134706-6-ref.html
layout/reftests/bugs/134706-6.html
layout/reftests/bugs/134706-6b-ref.html
layout/reftests/bugs/134706-6b.html
layout/reftests/bugs/134706-6c-ref.html
layout/reftests/bugs/134706-6c.html
layout/reftests/bugs/262151-1-ref.html
layout/reftests/bugs/262151-1.html
layout/reftests/bugs/322436-1-ref.html
layout/reftests/bugs/322436-1.html
layout/reftests/bugs/388980-1-ref.html
layout/reftests/bugs/388980-1.html
layout/reftests/bugs/404149-1-ref.xul
layout/reftests/bugs/404149-1.xul
layout/reftests/bugs/410621-1-ref.html
layout/reftests/bugs/410621-1.html
layout/reftests/bugs/413286-1a.html
layout/reftests/bugs/413286-1b.html
layout/reftests/bugs/413286-1c.html
layout/reftests/bugs/417676-ref.html
layout/reftests/bugs/417676.html
layout/reftests/bugs/424236-9-ref.html
layout/reftests/bugs/430813-3-ref.html
layout/reftests/bugs/430813-3.html
layout/reftests/bugs/433640-1-ref.html
layout/reftests/bugs/433640-1.html
layout/reftests/bugs/433700-ref.html
layout/reftests/bugs/433700.html
layout/reftests/font-face/media-query-remove-1.html
layout/reftests/margin-collapsing/inline-block-sibling-1-ref.html
layout/reftests/margin-collapsing/inline-block-sibling-1a.html
layout/reftests/margin-collapsing/inline-block-sibling-1b.html
layout/reftests/margin-collapsing/inline-block-sibling-1c.html
layout/reftests/marquee/413027-4-ref.html
layout/reftests/marquee/413027-4.html
layout/reftests/pagination/content-inserted-000.ref.xhtml
layout/reftests/pagination/content-inserted-000.xhtml
layout/reftests/pagination/content-inserted-001.ref.xhtml
layout/reftests/pagination/content-inserted-001.xhtml
layout/reftests/pagination/content-inserted-002.ref.xhtml
layout/reftests/pagination/content-inserted-002.xhtml
layout/reftests/pagination/content-inserted-003.xhtml
layout/reftests/pagination/content-inserted-004.xhtml
layout/reftests/pagination/content-inserted-005.xhtml
layout/reftests/pagination/content-inserted-006.xhtml
layout/reftests/pagination/content-inserted-007.xhtml
layout/reftests/pagination/content-inserted-008.xhtml
layout/reftests/pagination/content-inserted-009.xhtml
layout/reftests/pagination/resize-reflow-001.inner.html
layout/reftests/pagination/resize-reflow-001.ref.html
--- a/layout/reftests/bidi/413928-1-ref.html
+++ b/layout/reftests/bidi/413928-1-ref.html
@@ -1,16 +1,16 @@
 <!DOCTYPE html>
 <html>
  <head>
   <meta http-equiv="content-type" content="text/html; charset=UTF-8"/>
   <title>Bug 413928</title>
   <style type="text/css">
 .li {
-  line-height: 24px;
+  line-height: 2em;
 }
 .list-number-he {
   direction: rtl;
   unicode-bidi: bidi-override;
 }
   </style>
  </head>
  <body>
--- a/layout/reftests/bidi/413928-1.html
+++ b/layout/reftests/bidi/413928-1.html
@@ -7,17 +7,17 @@
  ol {
    list-style-type: hebrew;
    list-style-position: inside;
    padding: 0;
    margin: 0;
 }
 
  li {
-   line-height: 24px;
+   line-height: 2em;
 }
   </style>
  </head>
  <body>
   <ol start="-3">
    <li></li>
    <li></li>
    <li></li>
--- a/layout/reftests/bidi/413928-2-ref.html
+++ b/layout/reftests/bidi/413928-2-ref.html
@@ -1,16 +1,16 @@
 <!DOCTYPE html>
 <html>
  <head>
   <meta http-equiv="content-type" content="text/html; charset=UTF-8"/>
   <title>Bug 413928</title>
   <style type="text/css">
 .li {
-  line-height: 24px;
+  line-height: 2em;
 }
 .list-number-he {
   direction: rtl;
   unicode-bidi: bidi-override;
 }
   </style>
  </head>
  <body dir="rtl">
--- a/layout/reftests/bidi/413928-2.html
+++ b/layout/reftests/bidi/413928-2.html
@@ -7,17 +7,17 @@
  ol {
    list-style-type: hebrew;
    list-style-position: inside;
    padding: 0;
    margin: 0;
 }
 
  li {
-   line-height: 24px;
+   line-height: 2em;
 }
   </style>
  </head>
  <body dir="rtl">
   <ol start="-3">
    <li></li>
    <li></li>
    <li></li>
--- a/layout/reftests/box-shadow/boxshadow-inner-basic-ref.html
+++ b/layout/reftests/box-shadow/boxshadow-inner-basic-ref.html
@@ -1,1 +1,12 @@
-<div style="background-color: grey; width: 300px; height: 300px; -moz-border-radius: 5px; position: absolute; top: 20px; left: 20px;">inset</div><div style="-moz-border-radius: 5px; width: 300px; height: 300px; background-color: white; position: absolute; top: 40px; left: 40px;">&nbsp;</div>
+<body style="font-size: 16px;">
+<div style="background-color: grey;
+  width: 15em; height: 15em;
+  -moz-border-radius: 0.5em;
+  position: absolute;
+  top: 1em; left: 1em;">inset</div>
+<div style="-moz-border-radius: 0.5em;
+  width: 15em; height: 15em;
+  background-color: white;
+  position: absolute;
+  top: 3em; left: 3em;">&nbsp;</div>
+</body>
--- a/layout/reftests/box-shadow/boxshadow-inner-basic.html
+++ b/layout/reftests/box-shadow/boxshadow-inner-basic.html
@@ -1,1 +1,7 @@
-<div style="-moz-box-shadow: 20px 20px grey inset; width: 300px; height: 300px; -moz-border-radius: 5px; position: absolute; top: 20px; left: 20px;">inset</div>
+<body style="font-size: 16px;">
+<div style="-moz-box-shadow: 2em 2em grey inset;
+  width: 15em; height: 15em;
+  -moz-border-radius: .5em;
+  position: absolute;
+  top: 1em; left: 1em;">inset</div>
+</body>
--- a/layout/reftests/bugs/134706-5-ref.html
+++ b/layout/reftests/bugs/134706-5-ref.html
@@ -1,16 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 <html lang="en-US">
 <head>
 	<title>Testcase, bug 134706</title>
 	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
 	<meta http-equiv="Content-Style-Type" content="text/css">
 	<style type="text/css">
 
+	body { font-size: 10px; }
+
 	</style>
 </head>
 <body>
 
 <div style="width: 300px; height: 40px;background: aqua">
   <div style="float:left; background:blue; width: 200px; height: 20px"></div>
   <div style="float:left; clear: left; background: yellow; width: 150px; height: 20px">50%</div>
 </div>
--- a/layout/reftests/bugs/134706-5.html
+++ b/layout/reftests/bugs/134706-5.html
@@ -1,16 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 <html lang="en-US">
 <head>
 	<title>Testcase, bug 134706</title>
 	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
 	<meta http-equiv="Content-Style-Type" content="text/css">
 	<style type="text/css">
 
+	body { font-size: 10px; }
+
 	table { margin: 0; border-spacing: 0; }
 	td, th { padding: 0; vertical-align: top; }
 
 	</style>
 </head>
 <body>
 
 <table width="300" style="background: aqua"><tr><td>
--- a/layout/reftests/bugs/134706-6-ref.html
+++ b/layout/reftests/bugs/134706-6-ref.html
@@ -1,16 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 <html lang="en-US">
 <head>
 	<title>Testcase, bug 134706</title>
 	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
 	<meta http-equiv="Content-Style-Type" content="text/css">
 	<style type="text/css">
 
+	body { font-size: 16px; }
+
 	table { margin: 0; border-spacing: 0; }
 	caption, td, th { padding: 0; vertical-align: top; text-align: left; }
 
 	.capref { background: yellow; }
 	.tabref { background: purple; }
 
 	</style>
 </head>
--- a/layout/reftests/bugs/134706-6.html
+++ b/layout/reftests/bugs/134706-6.html
@@ -1,16 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 <html lang="en-US">
 <head>
 	<title>Testcase, bug 134706</title>
 	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
 	<meta http-equiv="Content-Style-Type" content="text/css">
 	<style type="text/css">
 
+	body { font-size: 16px; }
+
 	table { margin: 0; border-spacing: 0; }
 	caption, td, th { padding: 0; vertical-align: top; text-align: left; }
 
 	table table caption { background: yellow; }
 	table table { background: purple; }
 
 	</style>
 </head>
--- a/layout/reftests/bugs/134706-6b-ref.html
+++ b/layout/reftests/bugs/134706-6b-ref.html
@@ -1,16 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 <html lang="en-US">
 <head>
 	<title>Testcase, bug 134706</title>
 	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
 	<meta http-equiv="Content-Style-Type" content="text/css">
 	<style type="text/css">
 
+	body { font-size: 16px; }
+
 	table { margin: 0; border-spacing: 0; }
 	caption, td, th { padding: 0; vertical-align: top; text-align: left; }
 
 	.capref { background: yellow; }
 	.tabref { background: purple; }
 
 	</style>
 </head>
--- a/layout/reftests/bugs/134706-6b.html
+++ b/layout/reftests/bugs/134706-6b.html
@@ -1,16 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 <html lang="en-US">
 <head>
 	<title>Testcase, bug 134706</title>
 	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
 	<meta http-equiv="Content-Style-Type" content="text/css">
 	<style type="text/css">
 
+	body { font-size: 16px; }
+
 	table { margin: 0; border-spacing: 0; }
 	caption, td, th { padding: 0; vertical-align: top; text-align: left; }
 
 	table table caption { background: yellow; }
 	table table { background: purple; }
 
 	</style>
 </head>
--- a/layout/reftests/bugs/134706-6c-ref.html
+++ b/layout/reftests/bugs/134706-6c-ref.html
@@ -1,16 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 <html lang="en-US">
 <head>
 	<title>Testcase, bug 134706</title>
 	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
 	<meta http-equiv="Content-Style-Type" content="text/css">
 	<style type="text/css">
 
+	body { font-size: 16px; }
+
 	table { margin: 0; border-spacing: 0; }
 	caption, td, th { padding: 0; vertical-align: top; text-align: left; }
 
 	.capref { background: yellow; }
 	.tabref { background: purple; }
 
 	</style>
 </head>
--- a/layout/reftests/bugs/134706-6c.html
+++ b/layout/reftests/bugs/134706-6c.html
@@ -1,16 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 <html lang="en-US">
 <head>
 	<title>Testcase, bug 134706</title>
 	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
 	<meta http-equiv="Content-Style-Type" content="text/css">
 	<style type="text/css">
 
+	body { font-size: 16px; }
+
 	table { margin: 0; border-spacing: 0; }
 	caption, td, th { padding: 0; vertical-align: top; text-align: left; }
 
 	table table caption { background: yellow; }
 	table table { background: purple; }
 
 	</style>
 </head>
--- a/layout/reftests/bugs/262151-1-ref.html
+++ b/layout/reftests/bugs/262151-1-ref.html
@@ -1,9 +1,9 @@
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
 <html>
 <head>
   <title>Bug 262151 Reference</title>
 </head>
-<body style="text-align: right">
+<body style="text-align: right; font-size: 16px;">
 <span>This text should all </span><span>be on one line.</span>
 </body>
 </html>
--- a/layout/reftests/bugs/262151-1.html
+++ b/layout/reftests/bugs/262151-1.html
@@ -1,15 +1,15 @@
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
 <html>
 <head>
   <title>Bug 262151</title>
   <style type="text/css">table {border-collapse: collapse} td {padding: 0px}</style>
 </head>
-<body>
+<body style="font-size: 16px;">
 <table width="100%">
   <tr>
     <td><div style="width: 20em"></div></td>
     <td>
       <table align="right">
         <tr><td>This text should all <script type="text/javascript">var v = document.body.offsetHeight;</script>be on one line.</td></tr>
       </table>
     </td>
--- a/layout/reftests/bugs/322436-1-ref.html
+++ b/layout/reftests/bugs/322436-1-ref.html
@@ -1,12 +1,16 @@
 <html>
 
 <head>
 
 </head>
 
 <body>
 There should be floating text here!  Look at the source!
-This text should show up
+This&nbsp;text&nbsp;should&nbsp;show&nbsp;up
+<!-- using non-breaking spaces here because the box in the testcase
+     will always wrap (or not) as a complete unit, depending on
+     font size and window width -->
+
 </body>
 
 </html>
--- a/layout/reftests/bugs/322436-1.html
+++ b/layout/reftests/bugs/322436-1.html
@@ -1,12 +1,14 @@
 <html>
 
 <head>
 
 </head>
 
 <body>
 There should be floating text here!  Look at the source!
-<div style="display: -moz-box;"><div style="float: left;">This text should show up</div></div>
+<div style="display: -moz-box;"><div style="float: left;">This&nbsp;text&nbsp;should&nbsp;show&nbsp;up</div></div>
+<!-- using non-breaking spaces here to match the reference -->
+
 </body>
 
 </html>
--- a/layout/reftests/bugs/388980-1-ref.html
+++ b/layout/reftests/bugs/388980-1-ref.html
@@ -1,14 +1,14 @@
 <html>
 <head>
 <title>Reftest for bug 388980</title></html>
 <script type="text/javascript">
 
-var text = '<html><head></head><body>'
+var text = '<html><head></head><body style="font-size:16px;">'
 	+ '<p style="background-color:red;">This paragraph should be red</p>'
 	+ '<p style="background-color:blue;">This paragraph should be blue</p>'
 	+ '<p>This paragraph should not be colored</p>'
 	+ '</body></html>';
 
 function initIFrame() {
 	var doc = document.getElementById('theIFrame').contentDocument;
 	doc.designMode = 'on';
--- a/layout/reftests/bugs/388980-1.html
+++ b/layout/reftests/bugs/388980-1.html
@@ -1,14 +1,14 @@
 <html>
 <head>
 <title>Reftest for bug 388980</title></html>
 <script type="text/javascript">
 
-var text = '<html><head></head><body>'
+var text = '<html><head></head><body style="font-size:16px;">'
 	+ '<p id="redpar">This paragraph should be red</p>'
 	+ '<p id="bluepar">This paragraph should be blue</p>'
 	+ '<p id="normalpar">This paragraph should not be colored</p>'
 	+'</body></html>';
 
 
 function colorPar(par, color) {
 	var doc = document.getElementById('theIFrame').contentDocument;
--- a/layout/reftests/bugs/404149-1-ref.xul
+++ b/layout/reftests/bugs/404149-1-ref.xul
@@ -4,15 +4,16 @@
 label {
   text-align: right;
   width: 60px;
   border: 1px solid black;
   height: 20px;
   padding: 0 2px 0;
   margin: 0 10px 0 -58px;
   font-family: Scheherazade;
+  font-size: 16px;
 }
 " ?>
 <window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
   <box width="100">
     <label value="ف" accesskey="ف" />
   </box>
 </window>
--- a/layout/reftests/bugs/404149-1.xul
+++ b/layout/reftests/bugs/404149-1.xul
@@ -4,15 +4,16 @@
 label {
   text-align: right;
   width: 60px;
   border: 1px solid black;
   height: 20px;
   padding: 0 2px 0;
   margin: 0 10px 0 -58px;
   font-family: Scheherazade;
+  font-size: 16px;
 }
 " ?>
 <window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
   <box width="100">
     <label value="فایرفاکس" accesskey="ف" />
   </box>
 </window>
--- a/layout/reftests/bugs/410621-1-ref.html
+++ b/layout/reftests/bugs/410621-1-ref.html
@@ -6,17 +6,17 @@ td {
  border: 4px solid green;
 }
 table {
  border-collapse: collapse;
 }
 </style>
 </head>
 <body>
-<div style="height: 300px;">
+<div style="height: 20em;">
  <table align="left">
   <tr>
    <td>Entry 1</td>
    <td>Value 1</td>
   </tr>
   <tr>
    <td>Entry 2</td>
    <td>Value 2</td>
--- a/layout/reftests/bugs/410621-1.html
+++ b/layout/reftests/bugs/410621-1.html
@@ -6,17 +6,17 @@ td {
  border: 4px solid green;
 }
 table {
  border-collapse: collapse;
 }
 </style>
 </head>
 <body>
-<div style="overflow: auto; height: 300px;">
+<div style="overflow: auto; height: 20em;">
  <table align="left">
   <tr>
    <td>Entry 1</td>
    <td>Value 1</td>
   </tr>
   <tr>
    <td>Entry 2</td>
    <td>Value 2</td>
--- a/layout/reftests/bugs/413286-1a.html
+++ b/layout/reftests/bugs/413286-1a.html
@@ -1,12 +1,12 @@
 <html>
   <head>
     <style>
-      table     { width: 400px; height: 25px; }
+      table     { width: 400px; height: 25px; font-size: 10px; }
       td.blue   { background: lightblue;  color: rgba(0,0,0,0) }
       td.green  { background: lightgreen; color: rgba(0,0,0,0) }
       col.a     { width: 100px; }
       col.c     { width: 25%;   }
     </style>
   </head>
   <body>
     With colspan:
--- a/layout/reftests/bugs/413286-1b.html
+++ b/layout/reftests/bugs/413286-1b.html
@@ -1,12 +1,12 @@
 <html>
   <head>
     <style>
-      table     { width: 400px; height: 25px; }
+      table     { width: 400px; height: 25px; font-size: 10px; }
       td.blue   { background: lightblue;  color: rgba(0,0,0,0) }
       td.green  { background: lightgreen; color: rgba(0,0,0,0) }
       col.a     { width: 25%;   }
       col.c     { width: 25%;   }
     </style>
   </head>
   <body>
     With colspan:
--- a/layout/reftests/bugs/413286-1c.html
+++ b/layout/reftests/bugs/413286-1c.html
@@ -1,12 +1,12 @@
 <html>
   <head>
     <style>
-      table     { width: 400px; height: 25px; }
+      table     { width: 400px; height: 25px; font-size: 10px; }
       td.blue   { background: lightblue;  color: rgba(0,0,0,0) }
       td.green  { background: lightgreen; color: rgba(0,0,0,0) }
       col.a     { width: 100px; }
       col.c     { width: 100px; }
     </style>
   </head>
   <body>
     With colspan:
--- a/layout/reftests/bugs/417676-ref.html
+++ b/layout/reftests/bugs/417676-ref.html
@@ -1,18 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
 <html class="reftest-print">
 <title>Fixed Positioning Test</title>
 <style type="text/css">
   html, body { margin: 0; padding: 0; }
 </style>
 
-<div style="width: 3in; border: solid;">
+<div style="width: 3in; border: solid; font-size: 16px;">
 This box must be repeated at this same position on the first, second, and third pages.
 </div>
 
-<div style="page-break-before: always; width: 3in; border: solid;">
+<div style="page-break-before: always; width: 3in; border: solid; font-size: 16px;">
 This box must be repeated at this same position on the first, second, and third pages.
 </div>
 
-<div style="page-break-before: always; width: 3in; border: solid;">
+<div style="page-break-before: always; width: 3in; border: solid; font-size: 16px;">
 This box must be repeated at this same position on the first, second, and third pages.
 </div>
--- a/layout/reftests/bugs/417676.html
+++ b/layout/reftests/bugs/417676.html
@@ -1,9 +1,9 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
 <html class="reftest-print">
 <title>Fixed Positioning Test</title>
 
-<div style="position: fixed; left: 0; top: 0; width: 3in; border: solid;">
+<div style="position: fixed; left: 0; top: 0; width: 3in; border: solid; font-size: 16px;">
 This box must be repeated at this same position on the first, second, and third pages.
 </div>
 
 <p style="width: 0; height: 5in;">
\ No newline at end of file
--- a/layout/reftests/bugs/424236-9-ref.html
+++ b/layout/reftests/bugs/424236-9-ref.html
@@ -2,16 +2,17 @@
 	"http://www.w3.org/TR/html4/strict.dtd">
 <html lang="en-US">
 <head>
 	<title>reftest, bug 424236</title>
 	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
 	<meta http-equiv="Content-Style-Type" content="text/css">
 	<style type="text/css">
 
+	body { font-size: 16px; }
 	* { -moz-outline-offset: -1px; outline-offset: -1px; }
 	body > span { outline: 1px dotted black; }
 	/* can't compare to border combined with negative margin because of
 	   margin collapsing */
 	body > div { display: block; outline: 1px dotted black; width: -moz-max-content; width: max-content; }
 
 	</style>
 </head>
--- a/layout/reftests/bugs/430813-3-ref.html
+++ b/layout/reftests/bugs/430813-3-ref.html
@@ -2,13 +2,13 @@
 <html>
 <head>
 	<title>Testcase, bug 430813</title>
 	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
 </head>
 <body>
 <div style="margin-bottom: 1px">text</div>
 <div style="float:left;width:90px;height:300px"></div>
-<div style="margin-left:90px">
+<div style="margin-left:90px; font-size: 16px;">
 <span style="padding:0.2em;">This text should be near the top of the page, not pushed below the float.</span>
 </div>
 </body>
 </html>
--- a/layout/reftests/bugs/430813-3.html
+++ b/layout/reftests/bugs/430813-3.html
@@ -2,13 +2,14 @@
 <html>
 <head>
 	<title>Testcase, bug 430813</title>
 	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
 </head>
 <body>
 <div style="margin-bottom: 1px">text</div>
 <div style="float:left;width:90px;height:300px"></div>
-<div style="overflow:hidden">
+<div style="overflow:hidden; font-size: 16px;">
+<!-- restrict size to prevent wrap, can lead to antialiasing problem in the test -->
 <span style="padding:0.2em;">This text should be near the top of the page, not pushed below the float.</span>
 </div>
 </body>
 </html>
--- a/layout/reftests/bugs/433640-1-ref.html
+++ b/layout/reftests/bugs/433640-1-ref.html
@@ -9,17 +9,17 @@
 
   div.cell {
     float: left;
     width: 100px;
   }
   
   body > div { height:100px; }
   
-  p { height:20px; }
+  p { font-size: 12px; height:20px; }
 </style>
 </head><body>
 
 <div>
 <div class="cell"><p>31    x 32</p><div style="width:31px; background-position:-16px -16px;"  class="image"></div></div>
 <div class="cell"><p>31.1  x 32</p><div style="width:31px; background-position:-16px -16px;"  class="image"></div></div>
 <div class="cell"><p>31.5  x 32</p><div style="width:32px; background-position:-16px -16px;"  class="image"></div></div>
 <div class="cell"><p>31.8  x 32</p><div style="width:32px; background-position:-16px -16px;"  class="image"></div></div>
--- a/layout/reftests/bugs/433640-1.html
+++ b/layout/reftests/bugs/433640-1.html
@@ -12,17 +12,17 @@
     float: left;
     width: 100px;
   }
 
   body > div { height:100px; }
 
   /* ensure that font heights do not affect image placement. Fractional image offsets can
      affect exactly which pixel rects get painted. */
-  p { height:20px; }
+  p { font-size: 12px; height:20px; }
 </style>
 </head><body>
 
 <div>
 <div class="cell"><p>31    x 32</p><div style="width:31px"    class="image"></div></div>
 <div class="cell"><p>31.1  x 32</p><div style="width:31.1px"  class="image"></div></div>
 <div class="cell"><p>31.5  x 32</p><div style="width:31.5px"  class="image"></div></div>
 <div class="cell"><p>31.8  x 32</p><div style="width:31.8px"  class="image"></div></div>
--- a/layout/reftests/bugs/433700-ref.html
+++ b/layout/reftests/bugs/433700-ref.html
@@ -1,15 +1,17 @@
 <html><head>
     <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
     <title>Testcase for bug 433700</title>
     <style type="text/css">
 
+body { font-size: 16px; }
+
 fieldset,legend { padding:0; margin:0; border-width:0; border-style:solid; }
-fieldset { border-right:7px solid blue; }
+fieldset { border-right:7px solid blue; font-size: 16px; }
 
 #test1 { position:fixed; }
 #test1 fieldset { background:lime;}
 #test1 .legend  { margin-left:30px; background:pink; }
 
 #test2 { position:fixed; top:3em; }
 #test2 fieldset { background:lime; width:260px; }
 #test2 .legend  { margin-left: 20px; background:pink; }
--- a/layout/reftests/bugs/433700.html
+++ b/layout/reftests/bugs/433700.html
@@ -1,15 +1,17 @@
 <html><head>
     <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
     <title>Testcase for bug 433700</title>
     <style type="text/css">
 
+body { font-size: 16px; }
+
 fieldset,legend { padding:0; margin:0; border-width:0; border-style:solid; }
-fieldset { border-right:7px solid blue; }
+fieldset { border-right:7px solid blue; font-size: 16px; }
 
 #test1 { position:fixed; }
 #test1 fieldset { padding-left:35px; border-left:25px solid lime; background:lime; }
 #test1 legend  { margin-left: -30px; background:pink; }
 
 #test2 { position:fixed; top:3em; }
 #test2 fieldset { padding-left:35px; border-left:25px solid lime; background:lime; width:200px; }
 #test2 legend  { margin-left: -20%; background:pink; }
--- a/layout/reftests/font-face/media-query-remove-1.html
+++ b/layout/reftests/font-face/media-query-remove-1.html
@@ -9,17 +9,17 @@
 	html, body, iframe { margin: 0; padding: 0; border: none; }
 
 	</style>
 	<script type="application/ecmascript">
 
 	function run() {
 		var iframe = document.getElementsByTagName("iframe")[0]
 		iframe.contentWindow.arm();
-		iframe.style.width = "100px";
+		iframe.style.width = "5em";
 	}
 
 	</script>
 </head>
 <body onload="setTimeout(run, 20)">
 
 <iframe style="height: 5em; width: 300px" src="media-query-inner-1.html"></iframe>
 
--- a/layout/reftests/margin-collapsing/inline-block-sibling-1-ref.html
+++ b/layout/reftests/margin-collapsing/inline-block-sibling-1-ref.html
@@ -1,24 +1,26 @@
 <!DOCTYPE html>
 <html>
 <head>
+<!-- specifying all heights in em units so that large font sizes
+     don't disrupt relationships; everything will scale together -->
 <style type="text/css">
 #a {
  width: 200px;
  background-color: green;
 }
 #b, #c {
  display: inline-block;
- height: 20px; width: 200px;
+ height: 2em; width: 200px;
  background-color: blue;
  vertical-align: bottom;
 }
 #b {
- margin-bottom: 20px;
+ margin-bottom: 2em;
 }
 </style>
 </head>
 <body>
 <div id="a">
  <div id="b"></div>
  <div id="c"></div>
 </div>
--- a/layout/reftests/margin-collapsing/inline-block-sibling-1a.html
+++ b/layout/reftests/margin-collapsing/inline-block-sibling-1a.html
@@ -3,25 +3,25 @@
 <head>
 <style type="text/css">
 #a {
  width: 200px;
  background-color: green;
 }
 #b, #c {
  display: inline-block;
- height: 20px; width: 200px;
+ height: 2em; width: 200px;
  background-color: blue;
  vertical-align: bottom;
 }
 #b {
- margin-bottom: 5px;
+ margin-bottom: .5em;
 }
 #c {
- margin-top: 15px;
+ margin-top: 1.5em;
 }
 </style>
 </head>
 <body>
 <div id="a">
  <div id="b"></div>
  <div id="c"></div>
 </div>
--- a/layout/reftests/margin-collapsing/inline-block-sibling-1b.html
+++ b/layout/reftests/margin-collapsing/inline-block-sibling-1b.html
@@ -3,25 +3,25 @@
 <head>
 <style type="text/css">
 #a {
  width: 200px;
  background-color: green;
 }
 #b, #c {
  display: inline-block;
- height: 20px; width: 200px;
+ height: 2em; width: 200px;
  background-color: blue;
  vertical-align: bottom;
 }
 #b {
- margin-bottom: 15px;
+ margin-bottom: 1.5em;
 }
 #c {
- margin-top: 5px;
+ margin-top: .5em;
 }
 </style>
 </head>
 <body>
 <div id="a">
  <div id="b"></div>
  <div id="c"></div>
 </div>
--- a/layout/reftests/margin-collapsing/inline-block-sibling-1c.html
+++ b/layout/reftests/margin-collapsing/inline-block-sibling-1c.html
@@ -3,25 +3,25 @@
 <head>
 <style type="text/css">
 #a {
  width: 200px;
  background-color: green;
 }
 #b, #c {
  display: inline-block;
- height: 20px; width: 200px;
+ height: 2em; width: 200px;
  background-color: blue;
  vertical-align: bottom;
 }
 #b {
- margin-bottom: 10px;
+ margin-bottom: 1em;
 }
 #c {
- margin-top: 10px;
+ margin-top: 1em;
 }
 </style>
 </head>
 <body>
 <div id="a">
  <div id="b"></div>
  <div id="c"></div>
 </div>
--- a/layout/reftests/marquee/413027-4-ref.html
+++ b/layout/reftests/marquee/413027-4-ref.html
@@ -1,10 +1,10 @@
 <html><head>
 <title>Testcase for bug 413027 - Marquee height is sized too small, clipping text vertically</title>
 </head>
 <body>
 
 <div style="background-color: lime; width: 600px; float:left;">
-  <div style="margin: 100px 0px;">text</div>
+  <div style="margin: 100px 0px; padding-left: 2px;">text</div>
 </div>
       
 </body></html>
--- a/layout/reftests/marquee/413027-4.html
+++ b/layout/reftests/marquee/413027-4.html
@@ -1,12 +1,15 @@
 <html><head>
 <title>Testcase for bug 413027 - Marquee height is sized too small, clipping text vertically</title>
 </head>
 <body>
 
 <marquee scrollamount="0" behavior="alternate" direction="right" style="background-color: lime; width: 600px;">
 <div>
-  <div style="margin: 100px 0px;">text</div>
+<!-- padding-left used to avoid risk of an antialiasing pixel that may
+     project to the left of the origin, causing a spurious test failure
+     (see bugs 476927, 475968) -->
+  <div style="margin: 100px 0px; padding-left: 2px;">text</div>
 </div>
 </marquee>
       
 </body></html>
--- a/layout/reftests/pagination/content-inserted-000.ref.xhtml
+++ b/layout/reftests/pagination/content-inserted-000.ref.xhtml
@@ -1,14 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
   <title>Content Appended in {ib} Pagination with Overflow Containers</title>
 
   <style type="text/css">
+    body {
+      font-size: 16px;
+    }
+
     #colset {
       height: 400px;
       width: 450px;
       -moz-column-width: 150px;
       -moz-column-gap: 0;
       border: 3px solid silver;
     }
 
--- a/layout/reftests/pagination/content-inserted-000.xhtml
+++ b/layout/reftests/pagination/content-inserted-000.xhtml
@@ -1,14 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
   <title>Content Appended in {ib} Pagination with Overflow Containers</title>
 
   <style type="text/css">
+    body {
+      font-size: 16px;
+    }
+
     #colset {
       height: 400px;
       width: 450px;
       -moz-column-width: 150px;
       -moz-column-gap: 0;
       border: 3px solid silver;
     }
 
--- a/layout/reftests/pagination/content-inserted-001.ref.xhtml
+++ b/layout/reftests/pagination/content-inserted-001.ref.xhtml
@@ -1,14 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
   <title>Content Appended in Paginated Element</title>
 
   <style type="text/css">
+    body {
+      font-size: 16px;
+    }
+
     #colset {
       height: 200px;
       width: 450px;
       -moz-column-width: 150px;
       -moz-column-gap: 0;
       border: 3px solid silver;
     }
 
--- a/layout/reftests/pagination/content-inserted-001.xhtml
+++ b/layout/reftests/pagination/content-inserted-001.xhtml
@@ -1,14 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
   <title>Content Appended in Paginated Element</title>
 
   <style type="text/css">
+    body {
+      font-size: 16px;
+    }
+
     #colset {
       height: 200px;
       width: 450px;
       -moz-column-width: 150px;
       -moz-column-gap: 0;
       border: 3px solid silver;
     }
 
--- a/layout/reftests/pagination/content-inserted-002.ref.xhtml
+++ b/layout/reftests/pagination/content-inserted-002.ref.xhtml
@@ -1,14 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
   <title>Content Appended in Pagination</title>
 
   <style type="text/css">
+    body {
+      font-size: 16px;
+    }
+
     #colset {
       height: 200px;
       width: 450px;
       -moz-column-width: 150px;
       -moz-column-gap: 0;
       border: 3px solid silver;
     }
 
--- a/layout/reftests/pagination/content-inserted-002.xhtml
+++ b/layout/reftests/pagination/content-inserted-002.xhtml
@@ -1,14 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
   <title>Content Appended in Pagination before ::after</title>
 
   <style type="text/css">
+    body {
+      font-size: 16px;
+    }
+
     #colset {
       height: 200px;
       width: 450px;
       -moz-column-width: 150px;
       -moz-column-gap: 0;
       border: 3px solid silver;
     }
 
--- a/layout/reftests/pagination/content-inserted-003.xhtml
+++ b/layout/reftests/pagination/content-inserted-003.xhtml
@@ -1,14 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
   <title>Content Appended in Pagination before ::after (alternate)</title>
 
   <style type="text/css">
+    body {
+      font-size: 16px;
+    }
+
     #colset {
       height: 200px;
       width: 450px;
       -moz-column-width: 150px;
       -moz-column-gap: 0;
       border: 3px solid silver;
     }
 
--- a/layout/reftests/pagination/content-inserted-004.xhtml
+++ b/layout/reftests/pagination/content-inserted-004.xhtml
@@ -1,14 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
   <title>Content Inserted in Pagination after ::before</title>
 
   <style type="text/css">
+    body {
+      font-size: 16px;
+    }
+
     #colset {
       height: 200px;
       width: 450px;
       -moz-column-width: 150px;
       -moz-column-gap: 0;
       border: 3px solid silver;
     }
 
--- a/layout/reftests/pagination/content-inserted-005.xhtml
+++ b/layout/reftests/pagination/content-inserted-005.xhtml
@@ -1,14 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
   <title>Content Appended in Pagination after ::before</title>
 
   <style type="text/css">
+    body {
+      font-size: 16px;
+    }
+
     #colset {
       height: 200px;
       width: 450px;
       -moz-column-width: 150px;
       -moz-column-gap: 0;
       border: 3px solid silver;
     }
 
--- a/layout/reftests/pagination/content-inserted-006.xhtml
+++ b/layout/reftests/pagination/content-inserted-006.xhtml
@@ -1,14 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
   <title>Content Appended in Pagination before ::after (alternate)</title>
 
   <style type="text/css">
+    body {
+      font-size: 16px;
+    }
+
     #colset {
       height: 200px;
       width: 450px;
       -moz-column-width: 150px;
       -moz-column-gap: 0;
       border: 3px solid silver;
     }
 
--- a/layout/reftests/pagination/content-inserted-007.xhtml
+++ b/layout/reftests/pagination/content-inserted-007.xhtml
@@ -1,14 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
   <title>Content Inserted in Pagination after ::before</title>
 
   <style type="text/css">
+    body {
+      font-size: 16px;
+    }
+
     #colset {
       height: 200px;
       width: 450px;
       -moz-column-width: 150px;
       -moz-column-gap: 0;
       border: 3px solid silver;
     }
 
--- a/layout/reftests/pagination/content-inserted-008.xhtml
+++ b/layout/reftests/pagination/content-inserted-008.xhtml
@@ -1,14 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
   <title>Content Appended in Pagination before ::after</title>
 
   <style type="text/css">
+    body {
+      font-size: 16px;
+    }
+
     #colset {
       height: 200px;
       width: 450px;
       -moz-column-width: 150px;
       -moz-column-gap: 0;
       border: 3px solid silver;
     }
 
--- a/layout/reftests/pagination/content-inserted-009.xhtml
+++ b/layout/reftests/pagination/content-inserted-009.xhtml
@@ -1,14 +1,18 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
   <title>Content Appended in Pagination before ::after</title>
 
   <style type="text/css">
+    body {
+      font-size: 16px;
+    }
+
     #colset {
       height: 200px;
       width: 450px;
       -moz-column-width: 150px;
       -moz-column-gap: 0;
       border: 3px solid silver;
     }
 
--- a/layout/reftests/pagination/resize-reflow-001.inner.html
+++ b/layout/reftests/pagination/resize-reflow-001.inner.html
@@ -6,17 +6,17 @@
     html, body { margin: 0; padding: 0; }
     html { overflow: hidden }
   </style>
 </head>
 <body>
 
 <div style="-moz-column-width: 12em;
             border: silver solid;
-            height: 3em;">
+            height: 4em;">
   <div style="border: dotted;
               background: aqua;
               color: gray;">
         blah<br>
         blah<br>
         blah<br>
         blah
   </div>
--- a/layout/reftests/pagination/resize-reflow-001.ref.html
+++ b/layout/reftests/pagination/resize-reflow-001.ref.html
@@ -2,17 +2,17 @@
 <html>
 <head>
   <title>Resize Reflow Test</title>
 </head>
 <body style="width: 28em">
 
 <div style="-moz-column-width: 12em;
             border: silver solid;
-            height: 3em;">
+            height: 4em;">
   <div style="border: dotted;
               background: aqua;
               color: gray;">
         blah<br>
         blah<br>
         blah<br>
         blah
   </div>