Backed out 2 changesets (bug 1415214) for failures in 1415214.html
authorPhil Ringnalda <philringnalda@gmail.com>
Thu, 09 Nov 2017 22:46:22 -0800
changeset 391069 257e3b6e6cf823fa6a5b38dc4e68696f94acd0f6
parent 391068 54a656b4c58718bbd3bf672a2dec8e017d165406
child 391070 e2df7f0bf18245e0644b170a7b0173928da76afc
push id97189
push userphilringnalda@gmail.com
push dateFri, 10 Nov 2017 06:46:33 +0000
treeherdermozilla-inbound@257e3b6e6cf8 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1415214
milestone58.0a1
backs out54a656b4c58718bbd3bf672a2dec8e017d165406
dbd2b14a7466ce46b5b66056df599416e38d5b8d
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Backed out 2 changesets (bug 1415214) for failures in 1415214.html Backed out changeset 54a656b4c587 (bug 1415214) Backed out changeset dbd2b14a7466 (bug 1415214) MozReview-Commit-ID: 3NOHVkBjMVD
layout/generic/nsTextFrame.cpp
layout/reftests/text-decoration/1415214-ref.html
layout/reftests/text-decoration/1415214.html
layout/reftests/text-decoration/reftest.list
--- a/layout/generic/nsTextFrame.cpp
+++ b/layout/generic/nsTextFrame.cpp
@@ -7280,34 +7280,29 @@ nsTextFrame::DrawTextRunAndDecorations(R
     //   "text-combine-upright" (Bug 1408825)
     bool skipClipping = aRange.Length() == mTextRun->GetLength() ||
                         verticalDec != verticalRun;
 
     gfxRect clipRect;
     if (!skipClipping) {
       // Get the inline-size according to the specified range.
       gfxFloat clipLength = mTextRun->GetAdvanceWidth(aRange, aParams.provider);
-      nsRect visualRect = GetVisualOverflowRect();
+
+      clipRect.width = verticalDec ? frameSize.width : clipLength / app;
+      clipRect.height = verticalDec ? clipLength / app : frameSize.height;
 
       const bool isInlineReversed = mTextRun->IsInlineReversed();
       if (verticalDec) {
-        clipRect.x = aParams.framePt.x + visualRect.x;
-        clipRect.y = isInlineReversed ? aTextBaselinePt.y - clipLength
-                                      : aTextBaselinePt.y;
-        clipRect.width = visualRect.width;
-        clipRect.height = clipLength;
+        clipRect.y = (isInlineReversed ? aTextBaselinePt.y - clipLength
+                                       : aTextBaselinePt.y) / app;
       } else {
-        clipRect.x = isInlineReversed ? aTextBaselinePt.x - clipLength
-                                      : aTextBaselinePt.x;
-        clipRect.y = aParams.framePt.y + visualRect.y;
-        clipRect.width = clipLength;
-        clipRect.height = visualRect.height;
-      }
-
-      clipRect.Scale(1 / app);
+        clipRect.x = (isInlineReversed ? aTextBaselinePt.x - clipLength
+                                       : aTextBaselinePt.x) / app;
+      }
+
       clipRect.Round();
       params.context->Clip(clipRect);
     }
 
     // Underlines
     params.decoration = NS_STYLE_TEXT_DECORATION_LINE_UNDERLINE;
     for (const LineDecoration& dec : Reversed(aDecorations.mUnderlines)) {
       paintDecorationLine(dec, &Metrics::underlineSize,
deleted file mode 100644
--- a/layout/reftests/text-decoration/1415214-ref.html
+++ /dev/null
@@ -1,18 +0,0 @@
-<!DOCTYPE html>
-<html>
-  <head>
-    <meta charset="utf-8" />
-    <title>clip-rect-correctness-ref</title>
-    <style>
-      p {
-        font-size: 4px;
-      }
-    </style>
-  </head>
-  <body>
-    <p style="position: fixed; bottom: 0; margin: 0">
-      <span>link1</span>
-      <span>link2</span>
-    </p>
-  </body>
-</html>
deleted file mode 100644
--- a/layout/reftests/text-decoration/1415214.html
+++ /dev/null
@@ -1,18 +0,0 @@
-<!DOCTYPE html>
-<html>
-  <head>
-    <meta charset="utf-8" />
-    <title>clip-rect-correctness</title>
-    <style>
-      p {
-        font-size: 4px;
-      }
-    </style>
-  </head>
-  <body>
-    <p style="position: fixed; bottom: 0; margin: 0">
-      <span style="text-decoration: underline overline line-through">link1</span>
-      <span style="text-decoration: underline overline line-through">link2</span>
-    </p>
-  </body>
-</html>
--- a/layout/reftests/text-decoration/reftest.list
+++ b/layout/reftests/text-decoration/reftest.list
@@ -107,9 +107,8 @@ fuzzy-if(OSX==1010,1,4) == underline-but
 fuzzy-if(OSX==1010,1,2) == underline-button-2.html underline-button-2-ref.html
 fuzzy-if(skiaContent,4,2) == underline-select-1.html underline-select-1-ref.html
 == underline-select-2.html underline-select-2-ref.html
 == 1133392.html 1133392-ref.html
 != 1159729-offset-adjustment.html 1159729-offset-adjustment-notref.html
 == emphasis-style-dynamic.html emphasis-style-dynamic-ref.html
 == vertical-mode-decorations-1.html vertical-mode-decorations-1-ref.html
 == vertical-mode-decorations-2.html vertical-mode-decorations-2-ref.html
-!= 1415214.html 1415214-notref.html