pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From til...@apache.org
Subject svn commit: r1857945 - /pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDType1CFont.java
Date Mon, 22 Apr 2019 10:38:35 GMT
Author: tilman
Date: Mon Apr 22 10:38:35 2019
New Revision: 1857945

URL: http://svn.apache.org/viewvc?rev=1857945&view=rev
Log:
PDFBOX-3819: try also uniNNNN names

Modified:
    pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDType1CFont.java

Modified: pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDType1CFont.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDType1CFont.java?rev=1857945&r1=1857944&r2=1857945&view=diff
==============================================================================
--- pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDType1CFont.java (original)
+++ pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDType1CFont.java Mon
Apr 22 10:38:35 2019
@@ -164,6 +164,7 @@ public class PDType1CFont extends PDSimp
     public boolean hasGlyph(int code) throws IOException
     {
         String name = getEncoding().getName(code);
+        name = getNameInFont(name);
         return hasGlyph(name);
     }
 
@@ -171,6 +172,7 @@ public class PDType1CFont extends PDSimp
     public GeneralPath getPath(int code) throws IOException
     {
         String name = getEncoding().getName(code);
+        name = getNameInFont(name);
         return getPath(name);
     }
 
@@ -178,6 +180,7 @@ public class PDType1CFont extends PDSimp
     public GeneralPath getNormalizedPath(int code) throws IOException
     {
         String name = getEncoding().getName(code);
+        name = getNameInFont(name);
         GeneralPath path = getPath(name);
         if (path == null)
         {
@@ -297,6 +300,7 @@ public class PDType1CFont extends PDSimp
     public float getWidthFromFont(int code) throws IOException
     {
         String name = codeToName(code);
+        name = getNameInFont(name);
         float width = genericFont.getWidth(name);
 
         Point2D p = new Point2D.Float(width, 0);



Mime
View raw message