[evolution-patches] patch for zh_CN.gb18030 C&P appointment to a mail compose window create junk



Hi All,
	Attached pl. find the patch for zh_CN.gb18030 C&P appointment to a mail 
compose window create junk. Not sure of the bugzilla bug id as it is down. 

Thanks & Regards,
Suresh
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/gtkhtml/src/ChangeLog,v
retrieving revision 1.1814.2.6
diff -u -r1.1814.2.6 ChangeLog
--- ChangeLog	6 Aug 2003 06:25:41 -0000	1.1814.2.6
+++ ChangeLog	8 Aug 2003 23:49:03 -0000
@@ -1,3 +1,9 @@
+2003-08-08  Suresh Chandrasekharan  <suresh chandrasekharan sun com>
+
+	* gtkhtml.c (selection_received): Check to see whether a string is
+	already a UTF-8 string before passing to gtk_selection_data_get_text.
+	Needed for correclty pasting utf8 appointments to mail compose window.
+		
 2003-08-01  Radek Doulik  <rodo ximian com>
 
 	* htmlobject.c (get_length): objects not accepting cursor have
Index: gtkhtml.c
===================================================================
RCS file: /cvs/gnome/gtkhtml/src/gtkhtml.c,v
retrieving revision 1.520.2.4
diff -u -r1.520.2.4 gtkhtml.c
--- gtkhtml.c	7 Aug 2003 15:37:13 -0000	1.520.2.4
+++ gtkhtml.c	8 Aug 2003 23:49:03 -0000
@@ -1861,7 +1861,10 @@
 				g_warning ("selection was empty");
 
 			g_free (utf8);			
-		} else if ((utf8 = gtk_selection_data_get_text (selection_data))) {
+		} else if (( selection_data->length && 
+			    g_utf8_validate ( selection_data->data,  selection_data->length - 1, NULL) &&
+			 (utf8 = g_strdup (selection_data->data))) ||
+			 (utf8 = gtk_selection_data_get_text (selection_data))) {
 			if (as_cite) {
 				char *encoded;
 				


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