We are pleased to announce the release of Spire.PDF for Java 9.7.8. This version adds a new interface for converting PDF to Word, a new interface for setting the "crop box" and adds a new interface for setting margins when printing documents. It also enhances the conversion from PDF to Word, PDFA, OFD. In addition, some known issues are fixed in this version, such as the issue that the application threw exception: java.lang.NullPointerException when loading a PDF. More details are listed below.
Here is a list of changes made in this release
Category | ID | Description |
New feature | SPIREPDF-5843 SPIREPDF-5854 |
Adds a new interface for converting PDF to Word.
PdfToWordConverter converter = new PdfToWordConverter(inputPath); converter.saveToDocx(OutputPath); converter.dispose(); |
New feature | SPIREPDF-6115 | Adds a new interface for setting the "crop box".
PdfDocument pdfDocument = new PdfDocument(); pdfDocument.loadFromFile("input.pdf"); PdfPageBase pdfPageBase = pdfDocument.getPages().get(0); // setting the "crop box". pdfPageBase.setCropBox(new Rectangle2D.Float(0,0,400,800)); pdfDocument.saveToFile("output.pdf", FileFormat.PDF); |
New feature | SPIREPDF-6167 | Adds a new interface for setting margins when printing documents.
PdfDocument pdf = new PdfDocument(); pdf.loadFromFile(inputFile); PrintSettings setting = pdf.getPrintSettings(); pdf.getPrintSettings().setPaperMargins(30,30, 30, 30); setting.setPrinter("Microsoft XPS Document Writer"); pdf.getPrintSettings().printToFile(outputFile); pdf.print(); pdf.close(); |
Bug | SPIREPDF-3556 | Fixes the issue that the chart axis was missing coordinates after converting PDF to Word. |
Bug | SPIREPDF-4980 | Fixes the issue that the content was incorrect after converting PDF to Word using flow layout. |
Bug | SPIREPDF-5047 | Fixes the issue that the font name with multiple suffixes after converting PDF to Word. |
Bug | SPIREPDF-5067 | Fixes the issue that the characters garbled when viewing converted PDF to Word with Office 365. |
Bug | SPIREPDF-6085 | Fixes the issue that the application threw exception: java.lang.NullPointerException when loading a PDF. |
Bug | SPIREPDF-6102 | Fixes the issue that viewing the converted PDFA document would prompt for missing fonts. |
Bug | SPIREPDF-6104 | Fixes the issue that the borders were cropped after converting PDF to SVG. |
Bug | SPIREPDF-6105 | Fixes the issue that the PdfDocument.setCustomFontsFolders() method was not effective when converting PDF to PDFA. |
Bug | SPIREPDF-6112 | Fixes the issue that the application threw excepttion:"PDF file structure is not valid" when loading a PDF. |
Bug | SPIREPDF-6147 SPIREPDF-6175 |
Fixes the issue that the bold font effect was unclear when converting PDF to OFD. |
Bug | SPIREPDF-6154 | Fixes the issue that the application threw exception: "For input string: 'e-'" when merging documents and converting to PDFA1A. |
Bug | SPIREPDF-6187 | Fixes the issue that the application threw NullPointerException when rotating a previously rotated document back to its original position. |
Click the link below to download Spire.PDF for Java 9.7.8: