2011-04-08 Mike Reed <reed@google.com>
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 8 Apr 2011 20:08:01 +0000 (20:08 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 8 Apr 2011 20:08:01 +0000 (20:08 +0000)
        Reviewed by Eric Seidel.

        Replace SKIA_TEXT with isNativeFontRenderingAllowed() for print-preview to work
        https://bugs.webkit.org/show_bug.cgi?id=57782

        No new tests. This change only affects print-preview and build option SKIA_GPU

        * platform/graphics/skia/SkiaFontWin.cpp:
        (WebCore::paintSkiaText):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@83329 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/skia/SkiaFontWin.cpp

index 2141dc0..e0e88fc 100644 (file)
@@ -1,3 +1,15 @@
+2011-04-08  Mike Reed  <reed@google.com>
+
+        Reviewed by Eric Seidel.
+
+        Replace SKIA_TEXT with isNativeFontRenderingAllowed() for print-preview to work
+        https://bugs.webkit.org/show_bug.cgi?id=57782
+
+        No new tests. This change only affects print-preview and build option SKIA_GPU 
+
+        * platform/graphics/skia/SkiaFontWin.cpp:
+        (WebCore::paintSkiaText):
+
 2011-04-08  Ryosuke Niwa  <rniwa@webkit.org>
 
         Reviewed by Tony Chang, Darin Adler, and Enrica Casucci.
index b56b84b..c40c4a9 100644 (file)
@@ -377,10 +377,10 @@ bool paintSkiaText(GraphicsContext* context,
         paint.reset();
         platformContext->setupPaintForStroking(&paint, 0, 0);
         paint.setFlags(SkPaint::kAntiAlias_Flag);
-#if ENABLE(SKIA_TEXT)
-        paint.setTextEncoding(SkPaint::kGlyphID_TextEncoding);
-        setupPaintForFont(hfont, &paint);
-#endif
+        if (!platformContext->isNativeFontRenderingAllowed()) {
+            paint.setTextEncoding(SkPaint::kGlyphID_TextEncoding);
+            setupPaintForFont(hfont, &paint);
+        }
 
         if (didFill) {
             // If there is a shadow and we filled above, there will already be