[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

alex at webkit.org alex at webkit.org
Wed Dec 22 14:40:05 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit dc6e9c0a9b38cfba14df75cc8a709abec90e6fea
Author: alex at webkit.org <alex at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Fri Oct 15 08:33:53 2010 +0000

    2010-10-15  Alejandro G. Castro  <alex at igalia.com>
    
            Reviewed by Martin Robinson.
    
            compile fail with gtk >= 2.22
            https://bugs.webkit.org/show_bug.cgi?id=47483
    
            * platform/graphics/gtk/FontGtk.cpp: Removed the shrink operation,
            it was added long time ago and currently it is not adding any real
            area to the clip vertically, actually the gtk3 shrink version did
            not work.
            (WebCore::Font::drawComplexText):
            * platform/gtk/gtk2drawing.c: Undef the deprecation flags, this
            file is full of gtk2 stuff, and it does not seem interesting to
            upgrade because we are already creating a new version of the file
            for gtk3.
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@69845 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 16d165f..83752cf 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,20 @@
+2010-10-15  Alejandro G. Castro  <alex at igalia.com>
+
+        Reviewed by Martin Robinson.
+
+        compile fail with gtk >= 2.22
+        https://bugs.webkit.org/show_bug.cgi?id=47483
+
+        * platform/graphics/gtk/FontGtk.cpp: Removed the shrink operation,
+        it was added long time ago and currently it is not adding any real
+        area to the clip vertically, actually the gtk3 shrink version did
+        not work.
+        (WebCore::Font::drawComplexText):
+        * platform/gtk/gtk2drawing.c: Undef the deprecation flags, this
+        file is full of gtk2 stuff, and it does not seem interesting to
+        upgrade because we are already creating a new version of the file
+        for gtk3.
+
 2010-10-14  Ilya Tikhonovsky  <loislo at chromium.org>
 
         Reviewed by Pavel Feldman.
diff --git a/WebCore/platform/graphics/gtk/FontGtk.cpp b/WebCore/platform/graphics/gtk/FontGtk.cpp
index d5b6959..fd0e062 100644
--- a/WebCore/platform/graphics/gtk/FontGtk.cpp
+++ b/WebCore/platform/graphics/gtk/FontGtk.cpp
@@ -181,29 +181,6 @@ bool Font::canReturnFallbackFontsForComplexText()
     return false;
 }
 
-#ifndef GTK_API_VERSION_2
-static void cairo_region_shrink(cairo_region_t* region, int dx, int dy)
-{
-    int nRects = cairo_region_num_rectangles(region);
-    // Clear region.
-    cairo_region_subtract(region, region);
-
-    for (int i = 0; i < nRects; i++) {
-        cairo_rectangle_int_t rect;
-        cairo_region_get_rectangle(region, i, &rect);
-
-        if (rect.width <= 2 * dx || rect.height <= 2 * dy)
-            continue;
-
-        rect.x += dx;
-        rect.y += dy;
-        rect.width -= 2 * dx;
-        rect.height -= 2 * dy;
-        cairo_region_union_rectangle(region, &rect);
-    }
-}
-#endif
-
 void Font::drawComplexText(GraphicsContext* context, const TextRun& run, const FloatPoint& point, int from, int to) const
 {
 #if defined(USE_FREETYPE)
@@ -231,17 +208,13 @@ void Font::drawComplexText(GraphicsContext* context, const TextRun& run, const F
 #else
     cairo_region_t* partialRegion = 0;
 #endif
+
     if (to - from != run.length()) {
         // Clip the region of the run to be rendered
         char* start = g_utf8_offset_to_pointer(utf8, from);
         char* end = g_utf8_offset_to_pointer(start, to - from);
         int ranges[] = {start - utf8, end - utf8};
         partialRegion = gdk_pango_layout_line_get_clip_region(layoutLine, 0, 0, ranges, 1);
-#ifdef GTK_API_VERSION_2
-        gdk_region_shrink(partialRegion, 0, -pixelSize());
-#else
-        cairo_region_shrink(partialRegion, 0, -pixelSize());
-#endif
     }
 
     Color fillColor = context->fillColor();
diff --git a/WebCore/platform/gtk/gtk2drawing.c b/WebCore/platform/gtk/gtk2drawing.c
index d2d8b20..2f2edb6 100644
--- a/WebCore/platform/gtk/gtk2drawing.c
+++ b/WebCore/platform/gtk/gtk2drawing.c
@@ -46,6 +46,9 @@
 
 #ifdef GTK_API_VERSION_2
 
+#undef GTK_DISABLE_DEPRECATED
+#undef GDK_DISABLE_DEPRECATED
+
 #include <gdk/gdkprivate.h>
 #include "gtkdrawing.h"
 #include "GtkVersioning.h"

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list