Title: [114796] trunk/Tools
Revision
114796
Author
mrobin...@webkit.org
Date
2012-04-20 16:18:16 -0700 (Fri, 20 Apr 2012)

Log Message

[GTK] Revert changes that disabled Cairo fonts metrics hinting
https://bugs.webkit.org/show_bug.cgi?id=84502

Reviewed by Daniel Bates.

Re-enable Cairo metrics hinting, which seems to ensure consistent results in
reference and pixel test results. This makes our font metrics a bit different
than the Mac port's, but it's a decent price to pay for consistent results.

* DumpRenderTree/gtk/DumpRenderTree.cpp:
(initializeGtkFontSettings):
* WebKitTestRunner/InjectedBundle/gtk/ActivateFontsGtk.cpp:
(WTR::initializeGtkSettings):

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (114795 => 114796)


--- trunk/Tools/ChangeLog	2012-04-20 23:04:39 UTC (rev 114795)
+++ trunk/Tools/ChangeLog	2012-04-20 23:18:16 UTC (rev 114796)
@@ -1,3 +1,19 @@
+2012-04-20  Martin Robinson  <mrobin...@igalia.com>
+
+        [GTK] Revert changes that disabled Cairo fonts metrics hinting
+        https://bugs.webkit.org/show_bug.cgi?id=84502
+
+        Reviewed by Daniel Bates.
+
+        Re-enable Cairo metrics hinting, which seems to ensure consistent results in
+        reference and pixel test results. This makes our font metrics a bit different
+        than the Mac port's, but it's a decent price to pay for consistent results.
+
+        * DumpRenderTree/gtk/DumpRenderTree.cpp:
+        (initializeGtkFontSettings):
+        * WebKitTestRunner/InjectedBundle/gtk/ActivateFontsGtk.cpp:
+        (WTR::initializeGtkSettings):
+
 2012-04-04  Jer Noble  <jer.no...@apple.com>
 
         apple.com top navigation bar appears inside video during full screen exit animation

Modified: trunk/Tools/DumpRenderTree/gtk/DumpRenderTree.cpp (114795 => 114796)


--- trunk/Tools/DumpRenderTree/gtk/DumpRenderTree.cpp	2012-04-20 23:04:39 UTC (rev 114795)
+++ trunk/Tools/DumpRenderTree/gtk/DumpRenderTree.cpp	2012-04-20 23:18:16 UTC (rev 114796)
@@ -157,16 +157,6 @@
         g_object_set(settings, "gtk-xft-rgba", "rgb", NULL);
     else
         g_object_set(settings, "gtk-xft-rgba", "none", NULL);
-
-    GdkScreen* screen = gdk_screen_get_default();
-    ASSERT(screen);
-    const cairo_font_options_t* screenOptions = gdk_screen_get_font_options(screen);
-    ASSERT(screenOptions);
-    cairo_font_options_t* options = cairo_font_options_copy(screenOptions);
-    // Turn off text metrics hinting, which quantizes metrics to pixels in device space.
-    cairo_font_options_set_hint_metrics(options, CAIRO_HINT_METRICS_OFF);
-    gdk_screen_set_font_options(screen, options);
-    cairo_font_options_destroy(options);
 }
 
 CString getTopLevelPath()

Modified: trunk/Tools/WebKitTestRunner/InjectedBundle/gtk/ActivateFontsGtk.cpp (114795 => 114796)


--- trunk/Tools/WebKitTestRunner/InjectedBundle/gtk/ActivateFontsGtk.cpp	2012-04-20 23:04:39 UTC (rev 114795)
+++ trunk/Tools/WebKitTestRunner/InjectedBundle/gtk/ActivateFontsGtk.cpp	2012-04-20 23:18:16 UTC (rev 114796)
@@ -50,16 +50,6 @@
                  "gtk-font-name", "Liberation Sans 12",
                  "gtk-theme-name", "Raleigh",
                  "gtk-xft-rgba", "none", NULL);
-
-    GdkScreen* screen = gdk_screen_get_default();
-    ASSERT(screen);
-    const cairo_font_options_t* screenOptions = gdk_screen_get_font_options(screen);
-    ASSERT(screenOptions);
-    cairo_font_options_t* options = cairo_font_options_copy(screenOptions);
-    // Turn off text metrics hinting, which quantizes metrics to pixels in device space.
-    cairo_font_options_set_hint_metrics(options, CAIRO_HINT_METRICS_OFF);
-    gdk_screen_set_font_options(screen, options);
-    cairo_font_options_destroy(options);
 }
 
 static CString getTopLevelPath()
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to