From c4b5d93e6ee08a9d36df6a2452da3b7f7c772196 Mon Sep 17 00:00:00 2001 From: Andreas Fitzek Date: Wed, 18 Jun 2014 13:18:23 +0200 Subject: Parse font size as Float (issue: #24) --- .../java/at/gv/egiz/pdfas/lib/impl/stamping/pdfbox/PDFBoxFont.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pdf-as-lib/src/main') diff --git a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/stamping/pdfbox/PDFBoxFont.java b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/stamping/pdfbox/PDFBoxFont.java index b0c4b552..052106fd 100644 --- a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/stamping/pdfbox/PDFBoxFont.java +++ b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/stamping/pdfbox/PDFBoxFont.java @@ -110,10 +110,10 @@ public class PDFBoxFont { if(fontArr.length == 3) { font = generateFont(fontArr[0], fontArr[2]); - fontSize = Integer.parseInt(fontArr[1]); + fontSize = Float.parseFloat(fontArr[1]); } else if(fontArr.length == 2 && fontArr[0].startsWith("TTF:")) { font = generateFont(fontArr[0], null); - fontSize = Integer.parseInt(fontArr[1]); + fontSize = Float.parseFloat(fontArr[1]); } else { logger.warn("Using default font because: {} is not a valid font descriptor.", desc); this.font = defaultFont; -- cgit v1.2.3