You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pdfbox.apache.org by ti...@apache.org on 2026/09/26 19:28:02 UTC

svn commit: r1938547 - in pdfbox/branches/3.0: pdfbox-layout-awt/src/main/java/org/apache/pdfbox/glyphlayout/awt pdfbox-layout-awt/src/test/java/org/apache/pdfbox/glyphlayout/awt pdfbox-layout-fop/src/main/java/org/apache/pdfbox/glyphlayout/fop pdfbox/...

Author: tilman
Date: Sat Sep 26 19:28:02 2026
New Revision: 1938547

Log:
PDFBOX-6256: fix formatting / remove super() / fix javadoc / Sonar fix

Modified:
   pdfbox/branches/3.0/pdfbox-layout-awt/src/main/java/org/apache/pdfbox/glyphlayout/awt/GlyphLayoutProcessorAwt.java
   pdfbox/branches/3.0/pdfbox-layout-awt/src/test/java/org/apache/pdfbox/glyphlayout/awt/GlyphLayoutLigaturesAndKerningTest.java
   pdfbox/branches/3.0/pdfbox-layout-fop/src/main/java/org/apache/pdfbox/glyphlayout/fop/GlyphLayoutProcessorFop.java
   pdfbox/branches/3.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/AbstractGlyphLayoutProcessor.java

Modified: pdfbox/branches/3.0/pdfbox-layout-awt/src/main/java/org/apache/pdfbox/glyphlayout/awt/GlyphLayoutProcessorAwt.java
==============================================================================
--- pdfbox/branches/3.0/pdfbox-layout-awt/src/main/java/org/apache/pdfbox/glyphlayout/awt/GlyphLayoutProcessorAwt.java	Sat Sep 26 19:27:57 2026	(r1938546)
+++ pdfbox/branches/3.0/pdfbox-layout-awt/src/main/java/org/apache/pdfbox/glyphlayout/awt/GlyphLayoutProcessorAwt.java	Sat Sep 26 19:28:02 2026	(r1938547)
@@ -53,6 +53,7 @@ public class GlyphLayoutProcessorAwt ext
     /**
      * Constructs a GlyphLayoutProcessorFop with options
      *
+     * @param options
      */
     public GlyphLayoutProcessorAwt(AbstractGlyphLayoutProcessor.GlyphLayoutProcessorOptions options)
     {

Modified: pdfbox/branches/3.0/pdfbox-layout-awt/src/test/java/org/apache/pdfbox/glyphlayout/awt/GlyphLayoutLigaturesAndKerningTest.java
==============================================================================
--- pdfbox/branches/3.0/pdfbox-layout-awt/src/test/java/org/apache/pdfbox/glyphlayout/awt/GlyphLayoutLigaturesAndKerningTest.java	Sat Sep 26 19:27:57 2026	(r1938546)
+++ pdfbox/branches/3.0/pdfbox-layout-awt/src/test/java/org/apache/pdfbox/glyphlayout/awt/GlyphLayoutLigaturesAndKerningTest.java	Sat Sep 26 19:28:02 2026	(r1938547)
@@ -139,7 +139,7 @@ class GlyphLayoutLigaturesAndKerningTest
 
         String outputBaseName = String.format("GlyphLayoutLigaturesAndKerning%s", sActualText);
         String outputPDFFilename = "target/" + outputBaseName + ".pdf";
-        String outputTextFilename = String.format("target/" + outputBaseName + ".txt");
+        String outputTextFilename = String.format("target/%s.txt", outputBaseName);
 
         String firaPath = "/ttf/FiraCode-Regular.ttf";
         String dejavuPath = "/ttf/DejaVuSans.ttf"; // ligatures not in Liberation nor in Arimo

Modified: pdfbox/branches/3.0/pdfbox-layout-fop/src/main/java/org/apache/pdfbox/glyphlayout/fop/GlyphLayoutProcessorFop.java
==============================================================================
--- pdfbox/branches/3.0/pdfbox-layout-fop/src/main/java/org/apache/pdfbox/glyphlayout/fop/GlyphLayoutProcessorFop.java	Sat Sep 26 19:27:57 2026	(r1938546)
+++ pdfbox/branches/3.0/pdfbox-layout-fop/src/main/java/org/apache/pdfbox/glyphlayout/fop/GlyphLayoutProcessorFop.java	Sat Sep 26 19:28:02 2026	(r1938547)
@@ -141,6 +141,7 @@ public class GlyphLayoutProcessorFop ext
      * @param text text
      * @param bidiLevel Bidi Level
      * @return string width
+     * @throws java.io.IOException
      */
     @Override
     protected float getStringWidthUni(PDType0Font font, float fontSize, String text, int bidiLevel) throws IOException

Modified: pdfbox/branches/3.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/AbstractGlyphLayoutProcessor.java
==============================================================================
--- pdfbox/branches/3.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/AbstractGlyphLayoutProcessor.java	Sat Sep 26 19:27:57 2026	(r1938546)
+++ pdfbox/branches/3.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/AbstractGlyphLayoutProcessor.java	Sat Sep 26 19:28:02 2026	(r1938547)
@@ -102,7 +102,7 @@ public abstract class AbstractGlyphLayou
      *
      * @param options Options for creation
      */
-    public AbstractGlyphLayoutProcessor(GlyphLayoutProcessorOptions options)
+    protected AbstractGlyphLayoutProcessor(GlyphLayoutProcessorOptions options)
     {
         useActualText = options.useActualText;
     }
@@ -110,7 +110,7 @@ public abstract class AbstractGlyphLayou
     /**
      * Creates an AbstractGlyphLayoutProcessor with standard options
      */
-    public AbstractGlyphLayoutProcessor()
+    protected AbstractGlyphLayoutProcessor()
     {
         useActualText = false;
     }
@@ -123,6 +123,7 @@ public abstract class AbstractGlyphLayou
      * @param text text
      * @param bidiLevel Bidi Level
      * @return string width
+     * @throws java.io.IOException
      */
     protected abstract float getStringWidthUni(PDType0Font font, float fontSize, String text, int bidiLevel)
             throws IOException;
@@ -134,6 +135,7 @@ public abstract class AbstractGlyphLayou
      * @param fontSize font size
      * @param text text
      * @return string width
+     * @throws IOException
      */
     public float getStringWidth(PDType0Font font, float fontSize, String text) throws IOException
     {
@@ -164,6 +166,7 @@ public abstract class AbstractGlyphLayou
     /**
      * End a marked content sequence.
      *
+     * @param contentStream
      * @throws IOException If the content stream could not be written
      */
     protected void endMarkedContent(ContentStreamForGlyphLayoutInterface contentStream) throws IOException
@@ -197,6 +200,7 @@ public abstract class AbstractGlyphLayou
      * @throws IOException if an I/O exception occurs
      * @throws IllegalArgumentException if glyphs are missing
      */
+    @Override
     public void showText(ContentStreamForGlyphLayoutInterface contentStream, PDType0Font font, float fontSize, String text)
             throws IOException
     {