Title: [165204] branches/safari-537.75-branch

Diff

Modified: branches/safari-537.75-branch/LayoutTests/ChangeLog (165203 => 165204)


--- branches/safari-537.75-branch/LayoutTests/ChangeLog	2014-03-06 20:00:52 UTC (rev 165203)
+++ branches/safari-537.75-branch/LayoutTests/ChangeLog	2014-03-06 20:15:51 UTC (rev 165204)
@@ -1,5 +1,22 @@
 2014-03-06  Matthew Hanson  <[email protected]>
 
+        Merge r156716.
+
+    2013-10-01  Myles C. Maxfield  <[email protected]>
+
+            Center misspelling dots across width of word
+            https://bugs.webkit.org/show_bug.cgi?id=122046
+
+            Reviewed by Darin Adler.
+
+            This patch only rebaselines a single test. I would have rebaselined
+            the rest of the tests, but they seem to be affected by
+            webkit.org/b/122146. I don't want to commit incorrect expected results.
+
+            * platform/mac/editing/spelling/spelling-expected.png:
+
+2014-03-06  Matthew Hanson  <[email protected]>
+
         Merge r153788.
 
     2013-08-07  Antti Koivisto  <[email protected]>

Modified: branches/safari-537.75-branch/LayoutTests/platform/mac/editing/spelling/spelling-expected.png


(Binary files differ)

Modified: branches/safari-537.75-branch/Source/WebCore/ChangeLog (165203 => 165204)


--- branches/safari-537.75-branch/Source/WebCore/ChangeLog	2014-03-06 20:00:52 UTC (rev 165203)
+++ branches/safari-537.75-branch/Source/WebCore/ChangeLog	2014-03-06 20:15:51 UTC (rev 165204)
@@ -1,5 +1,22 @@
 2014-03-06  Matthew Hanson  <[email protected]>
 
+        Merge r156716.
+
+    2013-10-01  Myles C. Maxfield  <[email protected]>
+
+            Center misspelling dots across width of word
+            https://bugs.webkit.org/show_bug.cgi?id=122046
+
+            Reviewed by Darin Adler.
+
+            Test: editing/spelling/spelling.html
+
+            * platform/graphics/GraphicsContext.h:
+            * platform/graphics/mac/GraphicsContextMac.mm:
+            (WebCore::GraphicsContext::drawLineForDocumentMarker):
+
+2014-03-06  Matthew Hanson  <[email protected]>
+
         Merge r153788.
 
     2013-08-07  Antti Koivisto  <[email protected]>

Modified: branches/safari-537.75-branch/Source/WebCore/platform/graphics/mac/GraphicsContextMac.mm (165203 => 165204)


--- branches/safari-537.75-branch/Source/WebCore/platform/graphics/mac/GraphicsContextMac.mm	2014-03-06 20:00:52 UTC (rev 165203)
+++ branches/safari-537.75-branch/Source/WebCore/platform/graphics/mac/GraphicsContextMac.mm	2014-03-06 20:15:51 UTC (rev 165204)
@@ -146,6 +146,8 @@
         default:
             return;
     }
+    
+    FloatPoint offsetPoint = point;
 
     // Make sure to draw only complete dots.
     // NOTE: Code here used to shift the underline to the left and increase the width
@@ -155,8 +157,10 @@
     if (usingDot) {
         // allow slightly more considering that the pattern ends with a transparent pixel
         float widthMod = fmodf(width, patternWidth);
-        if (patternWidth - widthMod > cMisspellingLinePatternGapWidth)
+        if (patternWidth - widthMod > cMisspellingLinePatternGapWidth) {
+            offsetPoint.move(widthMod / 2, 0);
             width -= widthMod;
+        }
     }
     
     // FIXME: This code should not use NSGraphicsContext currentContext
@@ -172,9 +176,9 @@
 
     [patternColor set];
 
-    wkSetPatternPhaseInUserSpace(context, point);
+    wkSetPatternPhaseInUserSpace(context, offsetPoint);
 
-    NSRectFillUsingOperation(NSMakeRect(point.x(), point.y(), width, patternHeight), NSCompositeSourceOver);
+    NSRectFillUsingOperation(NSMakeRect(offsetPoint.x(), offsetPoint.y(), width, patternHeight), NSCompositeSourceOver);
     
     CGContextRestoreGState(context);
 }
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to