Re: unicode, rendering, and a minor doc typeo patch



martine cs washington edu (Evan Martin) writes:

> > It sounds reasonable. I think there I may have heard about some
> > problems with one-character layouts, though I can't reproduce that in
> > some quick tests. If you can produce a test case that exhibits the
> > problem, I'll take a look.
> 
> Actually, this is using a small (45 byte) UTF-8 file.
> 
> Attached test case and file.

Fixed in CVS. Thanks for the test case.

Regards,
                                        Owen

Thu Jan 24 18:05:54 2002  Owen Taylor  <otaylor redhat com>

	* pango/pango-layout.c (get_items_log_attrs): Fix problems with
	computing the length of the paragraph delimiter. (Reported by Evan Martin)

Index: pango-layout.c
===================================================================
RCS file: /cvs/gnome/pango/pango/pango-layout.c,v
retrieving revision 1.88
retrieving revision 1.89
diff -u -p -r1.88 -r1.89
--- pango-layout.c	2002/01/21 21:22:37	1.88
+++ pango-layout.c	2002/01/24 23:18:03	1.89
@@ -2791,8 +2791,8 @@ get_items_log_attrs (const char   *text,
       /* Break the paragraph delimiters with the last item */
       if (items->next == NULL)
 	{
+	  tmp_item.num_chars += g_utf8_strlen (text + index + tmp_item.length, para_delimiter_len);
 	  tmp_item.length += para_delimiter_len;
-	  tmp_item.num_chars += g_utf8_strlen (text + index, para_delimiter_len);
 	}
 
       pango_break (text + index, tmp_item.length, &tmp_item.analysis,



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]