aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/knowcenter/wag
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/at/knowcenter/wag')
-rw-r--r--src/main/java/at/knowcenter/wag/egov/egiz/pdf/PDFUtilities.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/main/java/at/knowcenter/wag/egov/egiz/pdf/PDFUtilities.java b/src/main/java/at/knowcenter/wag/egov/egiz/pdf/PDFUtilities.java
index 5384a8c..8c15d21 100644
--- a/src/main/java/at/knowcenter/wag/egov/egiz/pdf/PDFUtilities.java
+++ b/src/main/java/at/knowcenter/wag/egov/egiz/pdf/PDFUtilities.java
@@ -39,7 +39,7 @@ import com.lowagie.text.DocumentException;
*/
public abstract class PDFUtilities
{
- public static float calculatePageLength(final byte[] pdf,int page ,float footer_line) throws PDFDocumentException
+ public static float calculatePageLength(final byte[] pdf,int page ,float footer_line, int pagerotation) throws PDFDocumentException
{
try
{
@@ -54,7 +54,7 @@ public abstract class PDFUtilities
parser.parse();
PDDocument pdfDocument_ = parser.getPDDocument();
- float page_length = calculatePageLength(pdfDocument_,page , footer_line);
+ float page_length = calculatePageLength(pdfDocument_,page , footer_line, pagerotation);
pdfDocument_.close();
return page_length;
}
@@ -67,12 +67,12 @@ public abstract class PDFUtilities
throw new PDFDocumentException(201, e);
}
}
- public static float calculatePageLength(PDDocument document,int page ,float footer_line) throws IOException
+ public static float calculatePageLength(PDDocument document,int page ,float footer_line, int pagerotation) throws IOException
{
//int last_page_id = document.getNumberOfPages();
List allPages = document.getDocumentCatalog().getAllPages();
PDPage pdpage = (PDPage) allPages.get(page);
-
+ pdpage.setRotation(pagerotation);
return calculatePageLength(pdpage, footer_line);
}