[gs-cvs] gs/src

Igor Melichev igor at casper.ghostscript.com
Mon Jul 29 01:42:41 PDT 2002


Update of /cvs/ghostscript/gs/src
In directory casper:/tmp/cvs-serv25778/gs/src

Modified Files:
	gdevpdts.c 
Log Message:
pdfwrite/pdxtext: TJ arguments were inaccurately rounded.


Index: gdevpdts.c
===================================================================
RCS file: /cvs/ghostscript/gs/src/gdevpdts.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- gdevpdts.c	25 Jul 2002 19:11:38 -0000	1.10
+++ gdevpdts.c	29 Jul 2002 08:42:39 -0000	1.11
@@ -120,7 +120,8 @@
 	dw += pts->buffer.moves[--count].amount;
     }
     /* Round dw if it's very close to an integer. */
-    if (fabs(dw - (rounded = floor(dw + 0.5))) < fabs(dw * 0.001))
+    rounded = floor(dw + 0.5);
+    if (fabs(dw - rounded) < 0.001)
 	dw = rounded;
     if (dw != 0) {
 	if (count == MAX_TEXT_BUFFER_MOVES)




More information about the gs-cvs mailing list