Spire.Office for Java 8.3.6 is released

2023-03-24 09:43:51

We are excited to announce the release of Spire.Office for Java 8.3.6. In this version, Spire.PDF for Java supports scaling when printing PDF documents; Spire.XLS for Java supports converting Excel to standalone HTML files and replacing part of the text within a cell; Spire.Presentation for Java supports DPT and DPS file formats; Spire.Doc for Java supports modifying the time of revision. Besides, a lot of known issues are successfully fixed in this version. More details are listed below.

Click the link to download Spire.Office for Java 8.3.6:

Here is a list of changes made in this release

Spire.Doc for Java

Category ID Description
New feature SPIREDOC-8859 Supports modifying the revision time.
SimpleDateFormat formatter = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss");
String dateString = "2023/3/1 00:00:00";
Date date = formatter.parse(dateString);
revison.setDateTime(date);
Bug SPIREDOC-8645 Fixes the issue that the table content was incorrect when converting Word to PDF.
Bug SPIREDOC-8960 Fixes the issue that there is extra whitespace when converting Word to PDF.
Bug SPIREDOC-8855 Fixes the issue that the text display in SmartArt was incomplete when converting Word to PDF.
Bug SPIREDOC-8866 Fixed the issue that SmartArt was missing when converting Word to PDF
Bug SPIREDOC-8928 Fixes the issue that the table layout distorted when setting fixed column width
Bug SPIREDOC-8975 Fixes the issue that the number of document pages was incorrect.
Bug SPIREDOC-8978 Fixes the issue that the TOC style changed after updating
Bug SPIREDOC-9036 Fixes the issue that the application threw” NullPointerException” when converting Word to PDF
Bug SPIREDOC-9037 Fixes the issue that an error was reported when the result document was opened with MS Word after loading and saving as a new document.
Bug SPIREDOC-9056 Fixes the issue that the document could not be edited after repeatedly setting ProtectionType.Allow_Only_Revisions.
Bug SPIREDOC-9085 Fixes the issue that the line breaks were inconsistent when opening result document in MS Word after saving as new document
Bug SPIREDOC-9086 Fixes the issue that the line break styles lost when converting RTF to PDF.
Bug SPIREDOC-9110 Fixes the issue that the document format was inconsistent with the original document after cloning a section
Bug SPIREDOC-9138 Fixes the issue that the content was inconsistent after converting RTF to Word.

Spire.PDF for Java

Category ID Description
New feature SPIREPDF-5796 Optimizes memory consumption when printing PDF documents.
New feature SPIREPDF-5833 Supports scaling when printing PDF documents.
pdfDocument.getPrintSettings().selectSinglePageLayout
(PdfSinglePageScalingMode.Custom_Sacle, true, customScaling);
Bug SPIREPDF-5536 Fixes the issue that the application threw "java.lang.NullPointerException" when extracting table content.
Bug SPIREPDF-5558 Fixes the issue that some spaces were lost when extracting tables to CSV
Bug SPIREPDF-5750 Fixes the issue that the stamp was lost after loading the document and re-saving.
Bug SPIREPDF-5762 Fixes the issue that the application threw "NullPointerException" when saving encrypted PDF documents.
Bug SPIREPDF-5803 Fixes the issue that the checkbox positions changed after flattening PDF forms.
Bug SPIREPDF-5822 Fixes the issue that the Square annotation types could not set transparency.
Bug SPIREPDF-5827 Fixes the issue that the application threw "OutOfMemoryError" when converting PDFs to PDFA1B after applying a license.
Bug SPIREPDF-5834 Fixes the issue that the application threw "Invalid date string" error when converting PDFs to PDFA3A in Italian environment.

Spire.XLS for Java

Category ID Description
New feature SPIREXLS-3537 Support converting Excel to standalone HTML files.
Workbook wb = new Workbook();
wb.loadFromFile("data/mytest.xlsx");
HTMLOptions.Default.isStandAloneHtmlFile(true);
wb.saveToFile("result.html", FileFormat.HTML);
New feature SPIREXLS-3791 Support saving the entire Excel file to an HTML stream.
Workbook wb = new Workbook();
wb.loadFromFile("data/mytest.xlsx");
FileOutputStream fileStream = new FileOutputStream("output/saveStream_result.html");
wb.saveToStream(fileStream, FileFormat.HTML);
fileStream.close();
New feature SPIREXLS-4385 support adding conditional formatting to PivotFields and DataFields in pivot tables.
PivotTable table = (PivotTable)worksheet.getPivotTables().get(0);
PivotConditionalFormatCollection pcfs = table.getPivotConditionalFormats();
PivotConditionalFormat pc = pcfs.addPivotConditionalFormat(table.getColumnFields().get(0));
//PivotConditionalFormat pc = pcfs.addPivotConditionalFormat(table.getRowFields().get(0));
//PivotConditionalFormat pc = pcfs.addPivotConditionalFormat(table.getDataFields().get(0));
//PivotConditionalFormat pc = pcfs.addPivotConditionalFormat(table.getPageFields().get(0));
IConditionalFormat cf = pc.addCondition();
cf.setFormatType(ConditionalFormatType.ContainsBlanks);
cf.setFillPattern(ExcelPatternType.Solid);
cf.setBackColor(Color.Red);
New feature SPIREXLS-4513 Support replacing part of the text within a cell.
sheet.getCellList().get(0).textPartReplace("Office", "Spire");
Bug SPIREXLS-4489 Fixes the issue that the guide lines lost when converting charts to images.
Bug SPIREXLS-4490 Fixes the issue that some data positions were moved down when converting Excel to images.
Bug SPIREXLS-4508 Fixes the issue that the double underline became a single underline when converting Excel to images.
Bug SPIREXLS-4510 Fixes the issue that the program reported an error "java.lang.NullPointerException" when adding a footer to Excel
Bug SPIREXLS-4511 Fixes the issue that the program reported an error "Invalid sectionId of Header Footer image" when converting Excel to PDF.
Bug SPIREXLS-4514 Fixes the issue that the progress color in the progress bar was lost when converting Excel to images.
Bug SPIREXLS-4537 Fixes the issue that the X-axis data offset when converting charts to images.
Bug SPIREXLS-4547 Fixes the issue that the content was incorrect when converting Excel to PDF.

Spire.Presentation for Java

Category ID Description
New feature SPIREPPT-2203 Supports DPT and DPS file formats.
Presentation presentation = new Presentation();
presentation.loadFromFile("sample.dps", FileFormat.DPS);
presentation.saveToFile("result.dpt", FileFormat.DPT);
Bug SPIREPPT-2204 Improves the behavior of throwing exceptions when loading documents as a stream.
Bug SPIREPPT-2132 Fixed the issue that the fonts were wrong after converting HTML to PowerPoint.
Bug SPIREPPT-2171 Fixes the issue that it threw Unknown file format exception when loading PPT documents.
Bug SPIREPPT-2206 Fixes the issue that the colors in bar charts were incorrect after converting PPT to images.
Bug SPIREPPT-2207 Fixes the issue that it threw NullPointerException when executing ppt.getBytes() method.