pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From til...@apache.org
Subject svn commit: r1867925 - /pdfbox/trunk/examples/src/main/java/org/apache/pdfbox/examples/util/DrawPrintTextLocations.java
Date Thu, 03 Oct 2019 10:00:27 GMT
Author: tilman
Date: Thu Oct  3 10:00:27 2019
New Revision: 1867925

URL: http://svn.apache.org/viewvc?rev=1867925&view=rev
Log:
PDFBOX-4071: remove segment that is never reached (all PDSimpleFont classes are PDVectorFont
except PDType3Font)

Modified:
    pdfbox/trunk/examples/src/main/java/org/apache/pdfbox/examples/util/DrawPrintTextLocations.java

Modified: pdfbox/trunk/examples/src/main/java/org/apache/pdfbox/examples/util/DrawPrintTextLocations.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/examples/src/main/java/org/apache/pdfbox/examples/util/DrawPrintTextLocations.java?rev=1867925&r1=1867924&r2=1867925&view=diff
==============================================================================
--- pdfbox/trunk/examples/src/main/java/org/apache/pdfbox/examples/util/DrawPrintTextLocations.java
(original)
+++ pdfbox/trunk/examples/src/main/java/org/apache/pdfbox/examples/util/DrawPrintTextLocations.java
Thu Oct  3 10:00:27 2019
@@ -37,7 +37,6 @@ import org.apache.pdfbox.pdmodel.PDPage;
 import org.apache.pdfbox.pdmodel.common.PDRectangle;
 import org.apache.pdfbox.pdmodel.font.PDCIDFontType2;
 import org.apache.pdfbox.pdmodel.font.PDFont;
-import org.apache.pdfbox.pdmodel.font.PDSimpleFont;
 import org.apache.pdfbox.pdmodel.font.PDTrueTypeFont;
 import org.apache.pdfbox.pdmodel.font.PDType0Font;
 import org.apache.pdfbox.pdmodel.font.PDType3CharProc;
@@ -180,15 +179,6 @@ public class DrawPrintTextLocations exte
                 }
             }
         }
-        else if (font instanceof PDSimpleFont)
-        {
-            PDSimpleFont simpleFont = (PDSimpleFont) font;
-
-            // these two lines do not always work, e.g. for the TT fonts in file 032431.pdf
-            // which is why PDVectorFont is tried first.
-            String name = simpleFont.getEncoding().getName(code);
-            path = simpleFont.getPath(name);
-        }
         else
         {
             // shouldn't happen, please open issue in JIRA



Mime
View raw message