2004-10-28 Suresh Chandrasekharan <[email protected]>
authorsureshc
Thu, 28 Oct 2004 20:14:34 +0000
changeset 4361 0d06459dc9c5
parent 4360 751f1bf54a3c
child 4362 91d1b9bdef75
2004-10-28 Suresh Chandrasekharan <[email protected]> * libgnomeprint.spec: Added Patch10 * patches/libgnomeprint-10-chinese-ASCII-5090546.diff: Patch for Bugtraq #5090546/Bugzilla bug#156641
ChangeLog
libgnomeprint.spec
patches/libgnomeprint-10-chinese-ASCII-5090546.diff
--- a/ChangeLog	Thu Oct 28 18:39:33 2004 +0000
+++ b/ChangeLog	Thu Oct 28 20:14:34 2004 +0000
@@ -1,3 +1,9 @@
+2004-10-28  Suresh Chandrasekharan <[email protected]>
+
+        * libgnomeprint.spec: Added Patch10
+        * patches/libgnomeprint-10-chinese-ASCII-5090546.diff: Patch for
+         Bugtraq #5090546/Bugzilla bug#156641
+
 2004-10-28  Kazuhiko Maekawa  <[email protected]>
 
 	* javahelp-convert.spec : 
--- a/libgnomeprint.spec	Thu Oct 28 18:39:33 2004 +0000
+++ b/libgnomeprint.spec	Thu Oct 28 20:14:34 2004 +0000
@@ -18,6 +18,7 @@
 Patch7:       libgnomeprint-07-gtkdoc.diff
 Patch8:       libgnomeprint-08-g11n-i18n-ui.diff
 Patch9:       libgnomeprint-09-g11n-potfiles.diff
+Patch10:      libgnomeprint-10-chinese-ASCII-5090546.diff
 URL:          http://www.gnome.org
 BuildRoot:    %{_tmppath}/%{name}-%{version}-build
 Autoreqprov:  on
@@ -76,6 +77,7 @@
 %patch7 -p1
 %patch8 -p1
 %patch9 -p1
+%patch10 -p1
 
 %build
 %ifos linux
@@ -146,6 +148,9 @@
 %{_mandir}/man3/*
 
 %changelog
+* Thu Oct 28 2004 - [email protected]
+- Fix for 5090546. Added libgnomeprint-10-chinese-ASCII-5090546.diff.
+
 * Thu Oct 28 2004 - [email protected]
 - Add libgnomeprint-2.2.3 man page
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/libgnomeprint-10-chinese-ASCII-5090546.diff	Thu Oct 28 20:14:34 2004 +0000
@@ -0,0 +1,55 @@
+diff -urN libgnomeprint-2.6.0.orig/ChangeLog libgnomeprint-2.6.0/ChangeLog
+--- libgnomeprint-2.6.0.orig/ChangeLog	2004-10-28 12:10:56.281229000 -0700
++++ libgnomeprint-2.6.0/ChangeLog	2004-10-28 12:01:28.292154000 -0700
+@@ -1,3 +1,17 @@
++2004-10-27  Suresh Chandrasekharan <[email protected]>
++
++	Bugtraq #5090546
++
++        Fix for bugzilla bug#156641 english text not printed out with specific
++        chinese font (songti.ttf )
++
++        * libgnomeprint/gnome-font-face.c (gnome_font_face_ps_embed_tt): 
++	Additional check to get the right page info from the subfont 
++	name (for PS printing).
++
++        * libgnomeprint/gnome-print-pdf-tt.c
++        (gnome_print_pdf_tt_subset_embed): -do- (for PDF printing).
++
+ 2004-08-10  Suresh Chandrasekharan <[email protected]>
+ 	
+ 	Fix for #149858
+diff -urN libgnomeprint-2.6.0.orig/libgnomeprint/gnome-font-face.c libgnomeprint-2.6.0/libgnomeprint/gnome-font-face.c
+--- libgnomeprint-2.6.0.orig/libgnomeprint/gnome-font-face.c	2004-10-28 12:10:55.305806000 -0700
++++ libgnomeprint-2.6.0/libgnomeprint/gnome-font-face.c	2004-10-27 10:30:00.488166000 -0700
+@@ -1352,7 +1352,12 @@
+ 	nglyphs = pso->face->num_glyphs;
+ 
+ 	len = pso->encodedname ? strlen (pso->encodedname) : 0;
+-	lower = (len > 3) ? atoi (pso->encodedname + len - 3) : 0;
++
++	if (len > 4)
++		lower = *(pso->encodedname + len - 4) == '_' ? atoi (pso->encodedname + len - 3) : 0;
++	else
++		lower = 0;
++
+ 	upper = lower + 1;
+ 
+ 	k = 1;
+diff -urN libgnomeprint-2.6.0.orig/libgnomeprint/gnome-print-pdf-tt.c libgnomeprint-2.6.0/libgnomeprint/gnome-print-pdf-tt.c
+--- libgnomeprint-2.6.0.orig/libgnomeprint/gnome-print-pdf-tt.c	2004-10-28 12:10:55.206742000 -0700
++++ libgnomeprint-2.6.0/libgnomeprint/gnome-print-pdf-tt.c	2004-10-27 17:12:27.162313000 -0700
+@@ -53,7 +53,12 @@
+ 	nglyphs = pso->face->num_glyphs;
+ 
+ 	len = pso->encodedname ? strlen (pso->encodedname) : 0;
+-	lower = (len > 3) ? atoi (pso->encodedname + len - 3) : 0;
++
++	if (len > 4)
++		lower = *(pso->encodedname + len - 4) == '_' ? atoi (pso->encodedname + len - 3) : 0;
++	else
++		lower = 0;
++
+ 	upper = lower + 1;
+ 
+ 	k = 1;