[SCM] WebKit Debian packaging branch, webkit-1.3, updated. upstream/1.3.7-4207-g178b198
mario at webkit.org
mario at webkit.org
Mon Feb 21 00:30:23 UTC 2011
The following commit has been merged in the webkit-1.3 branch:
commit 794efc675a7fa8a93e67daa03c86a6e2f8876a06
Author: mario at webkit.org <mario at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Tue Feb 1 09:54:23 2011 +0000
2011-02-01 Mario Sanchez Prada <msanchez at igalia.com>
Reviewed by Martin Robinson.
[GTK] character range extents is off when the end of a wrapped line is included
https://bugs.webkit.org/show_bug.cgi?id=53323
Fixed wrong calculation getting the range extents.
* accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
(webkit_accessible_text_get_range_extents): Removed '+1' since the
requested interval shouldn't include the last character.
2011-02-01 Mario Sanchez Prada <msanchez at igalia.com>
Reviewed by Martin Robinson.
[GTK] character range extents is off when the end of a wrapped line is included
https://bugs.webkit.org/show_bug.cgi?id=53323
Update unit test to check the fix for this bug.
* tests/testatk.c:
(testWebkitAtkGetExtents): Check that the extent for a full line
are the same height than for a partial section of the same line.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@77234 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog
index ae4b349..6a10852 100644
--- a/Source/WebCore/ChangeLog
+++ b/Source/WebCore/ChangeLog
@@ -2,6 +2,19 @@
Reviewed by Martin Robinson.
+ [GTK] character range extents is off when the end of a wrapped line is included
+ https://bugs.webkit.org/show_bug.cgi?id=53323
+
+ Fixed wrong calculation getting the range extents.
+
+ * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
+ (webkit_accessible_text_get_range_extents): Removed '+1' since the
+ requested interval shouldn't include the last character.
+
+2011-02-01 Mario Sanchez Prada <msanchez at igalia.com>
+
+ Reviewed by Martin Robinson.
+
[GTK] Caret Offset is one off at the end of wrapped lines
https://bugs.webkit.org/show_bug.cgi?id=53300
diff --git a/Source/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp b/Source/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp
index b675af8..815fcf1 100644
--- a/Source/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp
+++ b/Source/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp
@@ -1544,7 +1544,7 @@ static void webkit_accessible_text_get_character_extents(AtkText* text, gint off
static void webkit_accessible_text_get_range_extents(AtkText* text, gint startOffset, gint endOffset, AtkCoordType coords, AtkTextRectangle* rect)
{
- IntRect extents = textExtents(text, startOffset, endOffset - startOffset + 1, coords);
+ IntRect extents = textExtents(text, startOffset, endOffset - startOffset, coords);
rect->x = extents.x();
rect->y = extents.y();
rect->width = extents.width();
diff --git a/Source/WebKit/gtk/ChangeLog b/Source/WebKit/gtk/ChangeLog
index 4de0efb..95f48ae 100644
--- a/Source/WebKit/gtk/ChangeLog
+++ b/Source/WebKit/gtk/ChangeLog
@@ -2,6 +2,19 @@
Reviewed by Martin Robinson.
+ [GTK] character range extents is off when the end of a wrapped line is included
+ https://bugs.webkit.org/show_bug.cgi?id=53323
+
+ Update unit test to check the fix for this bug.
+
+ * tests/testatk.c:
+ (testWebkitAtkGetExtents): Check that the extent for a full line
+ are the same height than for a partial section of the same line.
+
+2011-02-01 Mario Sanchez Prada <msanchez at igalia.com>
+
+ Reviewed by Martin Robinson.
+
[GTK] Caret Offset is one off at the end of wrapped lines
https://bugs.webkit.org/show_bug.cgi?id=53300
diff --git a/Source/WebKit/gtk/tests/testatk.c b/Source/WebKit/gtk/tests/testatk.c
index 9940c6d..b823283 100644
--- a/Source/WebKit/gtk/tests/testatk.c
+++ b/Source/WebKit/gtk/tests/testatk.c
@@ -1193,6 +1193,21 @@ static void testWebkitAtkGetExtents()
g_assert_cmpint(y, ==, mline_window.y + mline_window.height - height);
g_assert_cmpint(height, <=, mline_window.height);
+ /* Check that extent for a full line are the same height than for
+ a partial section of the same line */
+ gint startOffset;
+ gint endOffset;
+ gchar* text = atk_text_get_text_at_offset(multilineText, 0, ATK_TEXT_BOUNDARY_LINE_START, &startOffset, &endOffset);
+ g_free(text);
+
+ AtkTextRectangle fline_window;
+ AtkTextRectangle afline_window;
+ atk_text_get_range_extents(multilineText, startOffset, endOffset, ATK_XY_WINDOW, &fline_window);
+ atk_text_get_range_extents(multilineText, startOffset, endOffset - 1, ATK_XY_WINDOW, &afline_window);
+ g_assert_cmpint(fline_window.x, ==, afline_window.x);
+ g_assert_cmpint(fline_window.y, ==, afline_window.y);
+ g_assert_cmpint(fline_window.height, ==, afline_window.height);
+
g_object_unref(shortText1);
g_object_unref(shortText2);
g_object_unref(longText);
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list