r764 - branches/stable/source/src/texk/web2c/pdftexdir

karl at freefriends.org karl at freefriends.org
Sat Nov 5 00:29:20 CET 2016


Author: karl
Date: 2016-11-04 23:29:20 +0000 (Fri, 04 Nov 2016)
New Revision: 764

Modified:
   branches/stable/source/src/texk/web2c/pdftexdir/pdftoepdf.cc
Log:
zround+doc fix, tl 41713 and 42328

Modified: branches/stable/source/src/texk/web2c/pdftexdir/pdftoepdf.cc
===================================================================
--- branches/stable/source/src/texk/web2c/pdftexdir/pdftoepdf.cc	2016-07-05 17:53:31 UTC (rev 763)
+++ branches/stable/source/src/texk/web2c/pdftexdir/pdftoepdf.cc	2016-11-04 23:29:20 UTC (rev 764)
@@ -1,5 +1,5 @@
 /*
-Copyright 1996-2014 Han The Thanh, <thanh at pdftex.org>
+Copyright 1996-2016 Han The Thanh, <thanh at pdftex.org>
 
 This file is part of pdfTeX.
 
@@ -71,6 +71,7 @@
 // does not allow it.
 extern int getpdfsuppresswarningpagegroup(void);
 extern integer getpdfsuppressptexinfo(void);
+extern integer zround(double);
 }
 
 // The prefix "PTEX" for the PDF keys is special to pdfTeX;
@@ -425,9 +426,11 @@
                                                      &ffsubtype)->isName()
                 && !strcmp(ffsubtype->getName(), "Type1C")))
         && (fontmap = lookup_fontmap(basefont->getName())) != NULL) {
-        // copy the value of /StemV
+        // round /StemV value, since the PDF input is a float
+        // (see Font Descriptors in PDF reference), but we only store an
+        // integer, since we don't want to change the struct.
         fontdesc->dictLookup("StemV", &stemV);
-        fd = epdf_create_fontdescriptor(fontmap, stemV->getInt());
+        fd = epdf_create_fontdescriptor(fontmap, zround(stemV->getNum()));
         if (fontdesc->dictLookup("CharSet", &charset) &&
             charset->isString() && is_subsetable(fontmap))
             epdf_mark_glyphs(fd, charset->getString()->getCString());



More information about the pdftex-commits mailing list