We are delighted to announce the release of Spire.PDF for Java 10.3.4. This version adds the PdfTextReplacer class to replace PDF text and supports adding InkAnnotation to PDF. Besides, it also optimizes the PDF digital signature time to match the system local time. More details are listed below.
Here is a list of changes made in this release
Category | ID | Description |
New feature | SPIREPDF-4354 | Adds the PdfTextReplacer class to replace PDF text.
PdfDocument doc = new PdfDocument(); doc.loadFromFile("Input.pdf"); PdfPageBase page = doc.getPages().get(0); PdfTextReplacer textReplacer = new PdfTextReplacer(page); textReplacer.replaceAllText("old", "NEW"); doc.saveToFile("output.pdf"); doc.dispose(); |
New feature | SPIREPDF-6591 | Supports adding InkAnnotation to PDF.
PdfDocument doc = new PdfDocument(); PdfPageBase pdfPage = doc.getPages().add(); List<int[]> inkList = new ArrayList<>(); int[] intPoints = new int[] { 100,800, 200,800, 200,700 }; inkList.add(intPoints); PdfInkAnnotation ia = new PdfInkAnnotation(inkList); ia.setColor(new PdfRGBColor(Color.RED)); ia.getBorder().setWidth(12); ia.setText("e-iceblue"); ((PdfNewPage) pdfPage).getAnnotations().add(ia); doc.saveToFile("inkannotation.pdf"); |
Bug | SPIREPDF-6606 | Optimizes the PDF signature time to match the system local time. |
Click the link below to download Spire.PDF for Java 10.3.4: