diff options
Diffstat (limited to 'pdf-as-pdfbox-2/src/main/java/at')
2 files changed, 9 insertions, 8 deletions
diff --git a/pdf-as-pdfbox-2/src/main/java/at/gv/egiz/pdfas/lib/impl/pdfbox2/positioning/Positioning.java b/pdf-as-pdfbox-2/src/main/java/at/gv/egiz/pdfas/lib/impl/pdfbox2/positioning/Positioning.java index 4fbedac7..8ed12db8 100644 --- a/pdf-as-pdfbox-2/src/main/java/at/gv/egiz/pdfas/lib/impl/pdfbox2/positioning/Positioning.java +++ b/pdf-as-pdfbox-2/src/main/java/at/gv/egiz/pdfas/lib/impl/pdfbox2/positioning/Positioning.java @@ -82,9 +82,9 @@ public class Positioning { */ public static PositioningInstruction determineTablePositioning( TablePos pos, String signature_type, PDDocument pdfDataSource, - IPDFVisualObject pdf_table, boolean legacy32, boolean legacy40, ISettings settings) throws PdfAsException { + IPDFVisualObject pdf_table, ISettings settings) throws PdfAsException { return adjustSignatureTableandCalculatePosition(pdfDataSource, - pdf_table, pos, legacy32, legacy40, settings); + pdf_table, pos, settings); } private static PDRectangle rotateBox(PDRectangle cropBox, int rotation) { @@ -159,7 +159,7 @@ public class Positioning { */ public static PositioningInstruction adjustSignatureTableandCalculatePosition( final PDDocument pdfDataSource, IPDFVisualObject pdf_table, - TablePos pos, boolean legacy32, boolean legacy40, ISettings settings) throws PdfAsException { + TablePos pos, ISettings settings) throws PdfAsException { PdfBoxUtils.checkPDFPermissions(pdfDataSource); // get pages of currentdocument diff --git a/pdf-as-pdfbox-2/src/main/java/at/gv/egiz/pdfas/lib/impl/signing/pdfbox2/PADESPDFBOXSigner.java b/pdf-as-pdfbox-2/src/main/java/at/gv/egiz/pdfas/lib/impl/signing/pdfbox2/PADESPDFBOXSigner.java index 8a0a5e72..da8654ce 100644 --- a/pdf-as-pdfbox-2/src/main/java/at/gv/egiz/pdfas/lib/impl/signing/pdfbox2/PADESPDFBOXSigner.java +++ b/pdf-as-pdfbox-2/src/main/java/at/gv/egiz/pdfas/lib/impl/signing/pdfbox2/PADESPDFBOXSigner.java @@ -249,8 +249,9 @@ public class PADESPDFBOXSigner implements IPdfSigner, IConfigurationConstants { } } - boolean legacy32Position = signatureProfileConfiguration.getLegacy32Positioning(); - boolean legacy40Position = signatureProfileConfiguration.getLegacy40Positioning(); + //Legacy Modes not supported with pdfbox2 anymore +// boolean legacy32Position = signatureProfileConfiguration.getLegacy32Positioning(); +// boolean legacy40Position = signatureProfileConfiguration.getLegacy40Positioning(); // create Table describtion Table main = TableFactory.createSigTable(signatureProfileSettings, MAIN, pdfObject.getStatus(), @@ -267,7 +268,7 @@ public class PADESPDFBOXSigner implements IPdfSigner, IConfigurationConstants { */ PositioningInstruction positioningInstruction = Positioning.determineTablePositioning(tablePos, "", - doc, visualObject, legacy32Position, legacy40Position, pdfObject.getStatus().getSettings()); + doc, visualObject, pdfObject.getStatus().getSettings()); logger.debug("Positioning: {}", positioningInstruction.toString()); @@ -734,10 +735,10 @@ public class PADESPDFBOXSigner implements IPdfSigner, IConfigurationConstants { PositioningInstruction positioningInstruction = null; if (signaturePosString != null) { positioningInstruction = Positioning.determineTablePositioning(new TablePos(signaturePosString), "", - origDoc, visualObject, false, false, pdfObject.getStatus().getSettings()); + origDoc, visualObject, pdfObject.getStatus().getSettings()); } else { positioningInstruction = Positioning.determineTablePositioning(new TablePos(), "", origDoc, - visualObject, false, false, pdfObject.getStatus().getSettings()); + visualObject, pdfObject.getStatus().getSettings()); } origDoc.close(); |