From 0b8f2fa287b083f0a3b758161ba3f4f813c168a8 Mon Sep 17 00:00:00 2001 From: Tilman Hausherr Date: Mon, 6 Jan 2025 08:33:44 +0000 Subject: [PATCH] =?UTF-8?q?PDFBOX-5920:=20revert=20previous=20commit=20and?= =?UTF-8?q?=20check=20whether=20the=20name=20exists=20in=20PDType1CFont.ge?= =?UTF-8?q?tWidth(),=20as=20suggested=20by=20Andreas=20Lehmk=C3=83=C2=BChl?= =?UTF-8?q?er?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: https://svn.apache.org/repos/asf/pdfbox/trunk@1922914 13f79535-47bb-0310-9956-ffa450edef68 --- pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDFont.java | 2 -- 1 file changed, 2 deletions(-) diff --git a/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDFont.java b/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDFont.java index f17338cc5ff..3310acfa5ef 100644 --- a/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDFont.java +++ b/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDFont.java @@ -575,8 +575,6 @@ public float getSpaceWidth() try { // PDFBOX-5920: try with encoding, which gets the correct code - encode(" "); // this throws an exception if space doesn't exist, - // getStringWidth() not always fontWidthOfSpace = getStringWidth(" "); } catch (IllegalArgumentException | UnsupportedOperationException ex)