From commits-return-15823-archive-asf-public=cust-asf.ponee.io@pdfbox.apache.org Thu Oct 3 10:00:29 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id 09D5418065B for ; Thu, 3 Oct 2019 12:00:28 +0200 (CEST) Received: (qmail 93427 invoked by uid 500); 3 Oct 2019 10:00:28 -0000 Mailing-List: contact commits-help@pdfbox.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@pdfbox.apache.org Delivered-To: mailing list commits@pdfbox.apache.org Received: (qmail 93418 invoked by uid 99); 3 Oct 2019 10:00:28 -0000 Received: from Unknown (HELO svn01-us-west.apache.org) (209.188.14.144) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 03 Oct 2019 10:00:28 +0000 Received: from svn01-us-west.apache.org (localhost [127.0.0.1]) by svn01-us-west.apache.org (ASF Mail Server at svn01-us-west.apache.org) with ESMTP id 9A4EB3A0114 for ; Thu, 3 Oct 2019 10:00:27 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit 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 -0000 To: commits@pdfbox.apache.org From: tilman@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20191003100027.9A4EB3A0114@svn01-us-west.apache.org> 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