diff options
author | Havoc Pennington <hp@redhat.com> | 2001-02-15 20:46:49 +0000 |
---|---|---|
committer | Havoc Pennington <hp@src.gnome.org> | 2001-02-15 20:46:49 +0000 |
commit | 6c11912ab8c1797bcf0209a6e47a86653f561ecf (patch) | |
tree | 8281124f4f286a3168b924451d7f10402cf6254b /pango/pango-layout.c | |
parent | 0bca108a0ab7e081dc57640af3fbf9870749e7b8 (diff) | |
download | pango-6c11912ab8c1797bcf0209a6e47a86653f561ecf.tar.gz |
fix another "count line lengths to get line start" bug
2001-02-13 Havoc Pennington <hp@redhat.com>
* pango/pango-layout.c (pango_layout_line_get_x_ranges): fix
another "count line lengths to get line start" bug
Diffstat (limited to 'pango/pango-layout.c')
-rw-r--r-- | pango/pango-layout.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/pango/pango-layout.c b/pango/pango-layout.c index 73d61d3e..230e2d0a 100644 --- a/pango/pango-layout.c +++ b/pango/pango-layout.c @@ -2998,13 +2998,8 @@ pango_layout_line_get_x_ranges (PangoLayoutLine *line, /* FIXME it seems to me that width can be -1 here? */ get_x_offset (line->layout, line, width, logical_rect.width, &x_offset); - - tmp_list = line->layout->lines; - while (tmp_list->data != line) - { - line_start_index += ((PangoLayoutLine *)tmp_list->data)->length; - tmp_list = tmp_list->next; - } + + line_start_index = line->start_index; /* Allocate the maximum possible size */ if (ranges) |