summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2005-04-07 05:38:05 +0000
committerMatthias Clasen <matthiasc@src.gnome.org>2005-04-07 05:38:05 +0000
commitba516ae78362dfc74d2e564953af8f17ab66828c (patch)
tree3e890b3c65be27563ad4a97889e8cb0cfa939838
parent711600ea498939d5f17c608dca74722f70521b7c (diff)
downloadgtk+-ba516ae78362dfc74d2e564953af8f17ab66828c.tar.gz
Ignore regions which fall completely outside the line. (#165862, Felipe
2005-04-07 Matthias Clasen <mclasen@redhat.com> * gdk/gdkpango.c (gdk_pango_layout_line_get_clip_region): Ignore regions which fall completely outside the line. (#165862, Felipe Heidrich)
-rw-r--r--ChangeLog6
-rw-r--r--ChangeLog.pre-2-106
-rw-r--r--ChangeLog.pre-2-86
-rw-r--r--gdk/gdkpango.c14
4 files changed, 26 insertions, 6 deletions
diff --git a/ChangeLog b/ChangeLog
index 81c81d8514..4fe05e8323 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2005-04-07 Matthias Clasen <mclasen@redhat.com>
+
+ * gdk/gdkpango.c (gdk_pango_layout_line_get_clip_region):
+ Ignore regions which fall completely outside the line.
+ (#165862, Felipe Heidrich)
+
2005-04-06 Matthias Clasen <mclasen@redhat.com>
* gtk/*.c, gdk/gdkdisplaymanager.c: s/G-OBJECT/G_OBJECT/g,
diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10
index 81c81d8514..4fe05e8323 100644
--- a/ChangeLog.pre-2-10
+++ b/ChangeLog.pre-2-10
@@ -1,3 +1,9 @@
+2005-04-07 Matthias Clasen <mclasen@redhat.com>
+
+ * gdk/gdkpango.c (gdk_pango_layout_line_get_clip_region):
+ Ignore regions which fall completely outside the line.
+ (#165862, Felipe Heidrich)
+
2005-04-06 Matthias Clasen <mclasen@redhat.com>
* gtk/*.c, gdk/gdkdisplaymanager.c: s/G-OBJECT/G_OBJECT/g,
diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8
index 81c81d8514..4fe05e8323 100644
--- a/ChangeLog.pre-2-8
+++ b/ChangeLog.pre-2-8
@@ -1,3 +1,9 @@
+2005-04-07 Matthias Clasen <mclasen@redhat.com>
+
+ * gdk/gdkpango.c (gdk_pango_layout_line_get_clip_region):
+ Ignore regions which fall completely outside the line.
+ (#165862, Felipe Heidrich)
+
2005-04-06 Matthias Clasen <mclasen@redhat.com>
* gtk/*.c, gdk/gdkdisplaymanager.c: s/G-OBJECT/G_OBJECT/g,
diff --git a/gdk/gdkpango.c b/gdk/gdkpango.c
index d317b0faab..c5d2dedd5f 100644
--- a/gdk/gdkpango.c
+++ b/gdk/gdkpango.c
@@ -1316,12 +1316,14 @@ gdk_pango_layout_line_get_clip_region (PangoLayoutLine *line,
/* Note that get_x_ranges returns layout coordinates
*/
- pango_layout_line_get_x_ranges (line,
- index_ranges[i*2],
- index_ranges[i*2+1],
- &pixel_ranges, &n_pixel_ranges);
-
- for (j=0; j < n_pixel_ranges; j++)
+ if (index_ranges[i*2+1] >= line->start_index &&
+ index_ranges[i*2] < line->start_index + line->length)
+ pango_layout_line_get_x_ranges (line,
+ index_ranges[i*2],
+ index_ranges[i*2+1],
+ &pixel_ranges, &n_pixel_ranges);
+
+ for (j = 0; j < n_pixel_ranges; j++)
{
GdkRectangle rect;