We’re excited to announce the release of Spire.Presentation for Java 11.11.1. This version introduces new features, including reading customer data from shapes and setting audio fade-in and fade-out durations. Additionally, it addresses two known bugs. More details are below.

Here is a list of changes made in this release

Category ID Description
New feature - Added support for reading customer data from shapes.
Presentation ppt = new Presentation();
ppt.loadFromFile(inputFile);
List dataList = ppt.getSlides().get(0).getShapes().get(0).getCustomerDataList();
System.out.println(dataList.size());
for(int i = 0; i < dataList.size(); i++)
{
    String name = dataList.get(i).getName();
    String content = dataList.get(i).getXML();
}
New feature - Added support for setting audio fade-in and fade-out durations.
Presentation ppt = new Presentation();
ppt.loadFromFile(inputFile);
Rectangle2D.Double audioRect = new Rectangle2D.Double(220, 240, 80, 80);
IAudio audio=ppt.getSlides().get(0).getShapes().appendAudioMedia(inputFile_1, audioRect);
// Set the duration of the starting fade for 13s
audio.setFadeInDuration(13000f);
// Set the duration of the ending fade for 20s
audio.setFadeOutDuration(20000f);
ppt.saveToFile(outputFile, FileFormat.PPTX_2016);
ppt.dispose();
New feature - Added support for trimming audio playback range.
Presentation ppt = new Presentation();
ppt.loadFromFile(inputFile);
Rectangle2D.Double audioRect = new Rectangle2D.Double(220, 240, 80, 80);
IAudio audio=ppt.getSlides().get(0).getShapes().appendAudioMedia(inputFile_1, audioRect);
// Set the start trimming time 8 seconds
audio.setTrimFromStart(8000f);
// Set the end trimming time 13 seconds
audio.setTrimFromEnd(13000f);
ppt.saveToFile(outputFile, FileFormat.PPTX_2016);
ppt.dispose();
New feature - Added support for setting table transparency.
Presentation presentation = new Presentation();
presentation.loadFromFile("data/test.pptx");
Double[] widths = new Double[]{100d, 100d, 150d, 100d, 100d};
Double[] heights = new Double[]{15d, 15d, 15d, 15d, 15d, 15d, 15d, 15d, 15d, 15d, 15d, 15d, 15d};
// Add a table
ITable table = presentation.getSlides().get(0).getShapes().appendTable(
    (float) presentation.getSlideSize().getSize().getWidth() / 2 - 275, 90, widths, heights);
// Set overall table background transparency to 50% (0.0 = opaque, 1.0 = fully transparent)
table.getFill().setTransparency(0.5f);
// Customize the fill color of the cell at row 0, column 0 to blue
table.get(0, 0).getFillFormat().setFillType(FillFormatType.SOLID);
table.get(0, 0).getFillFormat().getSolidColor().setColor(Color.BLUE);
presentation.saveToFile("result.pptx", FileFormat.PPTX_2016);
Bug SPIREPPT-3035 Fixed the issue where adding a LaTeX formula caused the application to throw a "NullPointerException".
Bug SPIREPPT-3056 Fixed the issue where a false positive virus alert was triggered by Avira Security Suite for spire.presentation.jar.
Click the link below to download Spire.Presentation for Java 11.11.1:

We're pleased to announce the release of Spire.Doc for Python 14.1.0. This version adds new interfaces for managing and removing table styles. Additionally, it resolves an issue where enabling track changes and replacing text produced incorrect results. More details are listed below.

Here is a list of changes made in this release

Category ID Description
Optimization - Chart namespace updated:
// Old import (deprecated):
from spire.doc.charts import ChartType

// New import (use this):
from spire.doc.charts.ChartType import ChartType
New feature - The Bookmark class now includes FirstColumn and LastColumn properties to retrieve the starting and ending column indices of a bookmark within a table.
doc = Document()
doc.LoadFromFile(inputFile)
firstColumn = doc.Bookmarks["t_insert"].FirstColumn
lastColumn = doc.Bookmarks["t_insert"].LastColumn
New feature - The TableFormat class now supports Style, StyleOptions, and StyleName properties for managing table styles.
doc = Document()
tableStyle = doc.Styles.Add(StyleType.TableStyle, "TestTableStyle3")
tableStyle.LeftIndent = 55
tableStyle.Borders.Color = Color.get_Green()
tableStyle.HorizontalAlignment = RowAlignment.Right
tableStyle.Borders.BorderType = BorderStyle.Single

section = doc.AddSection()
table = section.AddTable()
table.ResetCells(3, 3)
table.Rows[0].Cells[0].AddParagraph().AppendText("Aligned according to left indent")
table.PreferredWidth = PreferredWidth.FromPoints(300)
table.Format.StyleName = "TestTableStyle3"

style = doc.Styles.FindByName("TestTableStyle3")
if (style is not None) and isinstance(style, TableStyle):
tableStyle = style
tableStyle.Borders.Color = Color.get_Black()
tableStyle.Borders.BorderType = BorderStyle.Double
tableStyle.RowStripe = 3
    tableStyle.ConditionalStyles[TableConditionalStyleType.OddRowStripe].Shading.BackgroundPatternColor = Color.get_LightBlue()
           tableStyle.ConditionalStyles[TableConditionalStyleType.EvenRowStripe].Shading.BackgroundPatternColor = Color.get_LightCyan()
tableStyle.ColumnStripe = 1
            tableStyle.ConditionalStyles[TableConditionalStyleType.EvenColumnStripe].Shading.BackgroundPatternColor = Color.get_LightPink()
table.ApplyStyle(tableStyle)
table.Format.StyleOptions = table.Format.StyleOptions | TableStyleOptions.ColumnStripe

doc.SaveToFile(outputFile, FileFormat.Docx)
New feature - The Style class now includes a RemoveSelf method to remove the style from the document.
style = doc.Styles.FindByName("TestTableStyle3")
style.RemoveSelf()
New feature - Enhanced the Document class with features including page extraction (ExtractPages), first-section access (FirstSection), and support for hyphenation dictionary registration/unregistration (RegisterHyphenationDictionary, UnregisterHyphenationDictionary, IsHyphenationDictionaryRegistered).
Bug SPIREDOC-11668 Fixed an issue where enabling track changes and replacing text produced incorrect results.
Click the link to download Spire.Doc for Python 14.1.0:

We're pleased to announce the release of Spire.PDF 12.1.0. This version enhances the conversion from PDF to Word. Meanwhile, some issues that occurred when converting PDF to PDF/A-3B, converting HTML to PDF, and obtaining font properties of text box fields have also been successfully fixed. Furthermore, the efficiency of timestamp requests has been optimized. More details are listed below.

Here is a list of changes made in this release

Category ID Description
Bug SPIREPDF-7867 Fixes the issue where rendering effects were incorrect when converting PDF to Word.
Bug SPIREPDF-7097 Fixes the issue where content copied from the result document was incorrect after converting PDF to PDF/A-3B.
Bug SPIREPDF-7841 Fixes the page numbering style issue when using ChromeHtmlConverter to convert HTML to PDF for printing.
Bug SPIREPDF-7847 Fixes the issue where obtaining font properties of text box fields threw an "ArgumentOutOfRangeException".
Bug SPIREPDF-7888 Optimizes timestamp requests by reducing calls to timestamp servers and improving validation.
Click the link below to download Spire.PDF 12.1.0:

We are pleased to announce the release of Spire.Doc 14.1.3. This version fixed several issues that caused the program to hang for an extended period of time during document layout processing and Word-to-PDF conversion. In addition, issues related to list numbering retrieval and incorrect content conversion were resolved. Details are listed below.

Here is a list of changes made in this release

Category ID Description
Bug SPIREDOC-10843 Fixed the issue where the program hung for a long time when using new FixedLayoutDocument(document).
Bug SPIREDOC-11532 Fixed the issue where the program hung for a long time when converting Word documents to PDF.
Bug SPIREDOC-11758 Fixed the issue where an incorrect numbering format was returned when retrieving lists.
Bug SPIREDOC-11728 SPIREDOC-11730 SPIREDOC-11731 Fixed the issue where incorrect content was generated when converting Word documents to PDF.
Click the link below to download Spire.Doc 14.1.3:
More information of Spire.Doc new release or hotfix:

We’re pleased to announce the release of Spire.Presentation for Python 11.1.0, which improves the conversion process from PPTX to PDF. This update addresses two specific PPTX to PDF issues and resolves two additional known bugs. More details are as follows.

Here is a list of changes made in this release

Category ID Description
Bug SPIREPPT-2859
SPIREPPT-3052
Fixed the issue where "ffi_prep_cif_var failed" error was thrown when using Python V12+ on macOS.
Bug SPIREPPT-3028 Fixed the issue where incorrect SVG effects occurred when importing using AddFromSVGAsShapes.
Bug SPIREPPT-3046
SPIREPPT-3053
Fixed the issue where inconsistent chart content was found when converting PPTX to PDF.
Bug SPIREPPT-3054 Fixed the issue where charts were missing when converting PPTX to PDF.
Click the link below to download Spire.Presentation for Python 11.1.0:

We're pleased to announce the release of Spire.Doc for Java 14.1.0. This version optimizes methods related to list styles, supports creating/retrieving/deleting picture bullets, comparing two ListLevel objects, and creating single-level as well as multi-level lists from built-in templates. Additionally, several issues that occurred when converting Word to PDF and MHT to PDF have also been successfully fixed. More details are listed below.

Here is a list of changes made in this release

Category ID Description
Optimization - Deprecated the Document.getListStyles() property, replaced it with Document.getListReferences().
Optimization - Removed the public constructors of ListStyle. Added StyleCollection.add(ListType listType, string name) to create a ListStyle.
ListStyle listStyle = document.getStyles().add(ListType.Numbered, "levelstyle");
listStyle.isCustomStyle(true);
ListLevelCollection levels = listStyle.getListRef().getLevels();
levels.get(0).setPatternType(ListPatternType.Arabic);
levels.get(0).setStartAt(1);
levels.get(0).getCharacterFormat().setFontName("Trebuchet MS");
Optimization - Updated the method for applying a ListStyle to a paragraph.
paragraph.getListFormat().applyStyle(ListStyle listStyle);
paragraph.getListFormat().setListLevelNumber(int leverNumber)

or

paragraph.getListFormat().applyListRef(ListDefinitionReference list, int leverNumber);
Optimization - Removed the ListFormat.getCurrentListStyle() method, replaced it with ListFormat.getCurrentListRef().
New feature - Added the add(ListTemplate template) method to ListCollection to create multi-level lists from built-in templates.
Document document = new Document();
Section sec = document.addSection();
Paragraph paragraph = sec.addParagraph();

// Create default bullet list template
ListTemplate template = ListTemplate.Bullet_Default;
ListDefinitionReference listRef = document.getListReferences().add(template);

// Create default numbered list template
ListTemplate template1 = ListTemplate.Number_Default;
listRef = document.getListReferences().add(template1);
listRef.getLevels().get(2).setStartAt(4);// Set the third level to start at number 4

// Add paragraph and apply numbered list style (level 2)
paragraph = sec.addParagraph();
paragraph.appendText("List Item 1");
// Apply level 2 (index starts at 0; 1 means the second level)
paragraph.getListFormat().applyListRef(listRef, 1);

paragraph = sec.addParagraph();
paragraph.appendText("List Item 2");
// Apply level 3
paragraph.getListFormat().applyListRef(listRef, 2);

paragraph = sec.addParagraph();
paragraph.appendText("List Item 3");
// Apply level 2
paragraph.getListFormat().applyListRef(listRef, 1);

paragraph = sec.addParagraph();
paragraph.appendText("List Item 4");
// Apply level 3
paragraph.getListFormat().applyListRef(listRef, 2);

document.saveToFile(outputFile, FileFormat.Docx);
document.close();
New feature - Added the addSingleLevelList(ListTemplate listTemplate) method to ListCollection for quickly creating single-level lists.
Document document = new Document();
Section sec = document.addSection();
Paragraph paragraph = sec.addParagraph();
// Create Arabic numeral numbered list template (e.g., "1.", "2.", ...)
ListTemplate template = ListTemplate.Number_Arabic_Dot;
// Use addSingleLevelList to create a single-level list reference
ListDefinitionReference listRef = document.getListReferences().addSingleLevelList(template);
int levelcount = listRef.getLevels().getCount();//Check level count
boolean res=listRef.isMultiLevel();
// Add first list item
paragraph = sec.addParagraph();
paragraph.appendText("List Item 1");
paragraph.getListFormat().applyListRef(listRef, 0);
paragraph = sec.addParagraph();
paragraph.appendText("List Item 2");
paragraph.getListFormat().applyListRef(listRef, 0);

document.saveToFile(outputFile, FileFormat.Docx);
document.close();
New feature - Added the ListLevel.equals(ListLevel level) method to compare whether two ListLevel objects are equal.
New feature - Added methods for creating, retrieving, and deleting picture bullets.
Document document = new Document();
Section sec = document.addSection();
Paragraph paragraph = sec.addParagraph();
// Create custom bulleted list style
ListStyle listStyle = document.getStyles().add(ListType.Bulleted, "bulletList");
// Get level configurations of this list style
ListLevelCollection Levels = listStyle.getListRef().getLevels();
// Set picture bullet for level 1
Levels.get(0).createPictureBullet();
Levels.get(0).getPictureBullet().loadImage(imag_Path_1);
// Set picture bullet for level 2
Levels.get(1).createPictureBullet();
Levels.get(1).getPictureBullet().loadImage(imag_Path_2);
// Add first list item
paragraph = sec.addParagraph();
paragraph.appendText("List Item 1");
paragraph.getListFormat().applyStyle(listStyle);
// Add second list item
paragraph = sec.addParagraph();
paragraph.appendText("List Item 1.1");
paragraph.getListFormat().applyStyle(listStyle);
paragraph.getListFormat().setListLevelNumber(1);
// Delete picture bullet for level 1
Levels.get(0).deletePictureBullet();
document.saveToFile(outputFile, FileFormat.Docx);
document.close();
Bug SPIREDOC-10843 Fixed an issue where the application hung when processing a structured document.
Bug SPIREDOC-11439 Fixed an issue where the comparison of the table of contents failed.
Bug SPIREDOC-11532 Fixed an issue where the application hung when converting Word to PDF.
Bug SPIREDOC-11605 SPIREDOC-11712 Fixed an issue where the table layout was incorrect when converting Word to PDF.
Bug SPIREDOC-11629 Fixed an issue where text positioning was incorrect when converting Word to PDF.
Bug SPIREDOC-11699 Fixed an issue where text line wrapping was incorrect when converting Word to PDF while following WPS rules.
Bug SPIREDOC-11709 Fixed an issue where the application hung when converting MHT to PDF.
Bug SPIREDOC-11741 Fixed an issue that Avira Free Security Suite falsely detected a virus in spire.doc.jar.
Click the link below to download Spire.Doc for Java 14.1.0:
Wednesday, 31 December 2025 07:29

Spire.Office 10.12.0 is released

We’re pleased to announce the release of Spire.Office 10.12.0. In this version, Spire.Doc supports the "Two Lines in One" function to enhance Word to PDF conversion; Spire.XLS supports customizing export options when converting Excel to Markdown; Spire.Presentation supports compressing images; Spire.PDF supports both horizontal and vertical text alignment. Meanwhile, a series of known issues have been fixed in this update. More details are as follows.

In this version, the most recent versions of Spire.Doc, Spire.PDF, Spire.XLS, Spire.Presentation, Spire.Barcode, Spire.DocViewer, Spire.PDFViewer, and Spire.Email are included.

DLL Versions:

  • Spire.Doc.dll v13.12.6
  • Spire.PDF.dll v11.12.7
  • Spire.XLS.dll v15.12.2
  • Spire.Presentation.dll v10.12.3
  • Spire.Barcode.dll v7.5.0
  • Spire.Email.dll v6.8.0
  • Spire.DocViewer.Forms.dll v8.9.5
  • Spire.PdfViewer.Asp.dll v8.2.9
  • Spire.PdfViewer.Forms.dll v8.2.9
  • Spire.Spreadsheet.dll v7.5.3
  • Spire.OfficeViewer.Forms.dll v8.8.1
Click the link to get the version Spire.Office 10.12.0:
More information of Spire.Office new release or hotfix:

Here is a list of changes made in this release

Spre.doc

Category ID Description
New feature SPIREDOC-5504 Supports setting the "Horizontal in Vertical" property of Paragraph text.
Document doc = new Document();
Section section = doc.AddSection();
Spire.Doc.Documents.Paragraph paragraph = section.AddParagraph();
Spire.Doc.Fields.TextRange farEastLayout = paragraph.AppendText("test");
FarEastLayout style = new FarEastLayout();
style.Vertical = true;
farEastLayout.CharacterFormat.FarEastLayout = style;
doc.SaveToFile(outputFile, FileFormat.Docx);
doc.Close();
New feature SPIREDOC-11073 Supports copying styles from template documents when converting Markdown to Docx.
//Load template documents with existing styles
           Document temple = new Document();
           temple.LoadFromFile("temple.docx");
           //Load markdown file
            Document doc = new Document();
           doc = new Document(@"Doc.md");
           //Copy styles from template documents
           doc.CopyStylesFromTemplate(temple);
           //Save
           doc.SaveToFile(@"Doc.docx", Spire.Doc.FileFormat.Docx2016);
New feature Supports the "Two Lines in One" function to enhance Word to PDF conversion.
New feature Supports retrieving style change revisions.
Document doc = new Document();
            doc.LoadFromFile(inputFile);
            RevisionInfoCollection revisionInfoCollection = doc.GetRevisionInfos();
            StringBuilder sb = new StringBuilder();
            foreach (RevisionInfo revisionInfo in revisionInfoCollection)
            {
                if (revisionInfo.RevisionType == RevisionType.FormatChange)
                {
                    if (revisionInfo.OwnerObject is Spire.Doc.Fields.TextRange)
                    {
                        TextRange range = (TextRange)revisionInfo.OwnerObject;
                        sb.AppendLine("TextRange:" + range.Text + "\r\n");
                        doc.RevisionsView = RevisionsView.Original;
                        sb.AppendLine("Original style:" + "isBold:" + range.CharacterFormat.Bold + ";" + "TextColor:" + range.CharacterFormat.TextColor + ";HighlightColor:" + range.CharacterFormat.HighlightColor + ";FontName:" + range.CharacterFormat.FontName + ";UnderlineStyle:" + range.CharacterFormat.UnderlineStyle + "\r\n");
                        doc.RevisionsView = RevisionsView.Final;
                        sb.AppendLine("Final style:" + "isBold:" + range.CharacterFormat.Bold + ";" + "TextColor:" + range.CharacterFormat.TextColor + ";HighlightColor:" + range.CharacterFormat.HighlightColor + ";FontName:" + range.CharacterFormat.FontName + ";UnderlineStyle:" + range.CharacterFormat.UnderlineStyle + "\r\n");
                    }
                }
            }
            File.WriteAllText(outputFile, sb.ToString());
            doc.Close();
New feature SPIREDOC-10448 Added a CompatibilityOptions property to the Document class for performing compatibility operations on documents.
Document doc = new Document();
      doc.CompatibilityOptions.UlTrailSpace = false;
      doc.CompatibilityOptions.AdjustLineHeightInTable = true;
      doc.CompatibilityOptions.SpaceForUL = true;
      doc.CompatibilityOptions.ApplyBreakingRules = true;
      doc.CompatibilityOptions.DoNotExpandShiftReturn = false;
      doc.CompatibilityOptions.OverrideTableStyleFontSizeAndJustification = false;
      doc.CompatibilityOptions.DoNotAutofitConstrainedTables = true;
      doc.SaveToFile("outputFile");
New feature - Added the CompatibilityOptions class, CompatibilityTypes enumeration, and WordVersion enumeration to the Spire.Doc.Settings namespace.
Document doc = new Document();
    doc.LoadFromFile("inputtFile");
    Spire.Doc.Settings.CompatibilityOptions options = doc.CompatibilityOptions;
New feature - Added the OptimizeForWordVersion() method to the CompatibilityOptions class, enabling document compatibility to be set by specifying a Word version.
Document doc = new Document();
            doc.LoadFromFile(inputFile);

            // Set properties
            doc.CompatibilityOptions.UlTrailSpace = false;
            doc.CompatibilityOptions.AdjustLineHeightInTable = true;
            doc.CompatibilityOptions.SpaceForUL = true;
            doc.CompatibilityOptions.ApplyBreakingRules = true;
            doc.CompatibilityOptions.DoNotExpandShiftReturn = false;
            doc.CompatibilityOptions.OverrideTableStyleFontSizeAndJustification = false;
            doc.CompatibilityOptions.DoNotAutofitConstrainedTables = true;
			// Set FileFormat when saving to preserve effects
            doc.SaveToFile(outputFile_after, FileFormat.Docx2016); 

            // Using version compatibility will reset previously set properties
            Spire.Doc.Settings.CompatibilityOptions options = doc.CompatibilityOptions;
            doc.CompatibilityOptions.OptimizeForWordVersion(WordVersion.Word2016);
            PrintCompatibilityOptions(options, outputFile);
            doc.Close();
Bug SPIREDOC-10859 Fixed issue with incorrect header appearance when converting Word to PDF.
Bug SPIREDOC-11005 Fixed issue with loss of image transparency when converting Word to PDF/A-3B.
Bug SPIREDOC-11579 Fixed issue with incorrect rendering when converting Word to PDF.
Bug SPIREDOC-11623 Fixed issue where converting Word to PDF threw a "System.NullReferenceException".
Bug SPIREDOC-11644 Fixed issue with incorrect fonts when converting Word to images.
Bug SPIREDOC-11659 Fixed issue where copying headers threw an "Object reference not set to an instance of an object" error.
Bug SPIREDOC-11680 Fixed issue where loading a signed document threw a "System.FormatException" error.
Bug SPIREDOC-11696 Fixed issue where the doc.HtmlUrlLoadEvent could not be used in the latest version.
Bug SPIREDOC-11700 Fixed issue with incorrect page number updates in the table of contents.
Bug SPIREDOC-11708 Fixed the issue where page numbers were incorrect when converting Word documents to PDF.

Spre.XLS

Category ID Description
New Feature SPIREXLS-5938, SPIREXLS-5975 Supports customizing export options when converting Excel to Markdown.
Workbook wb = new Workbook();
wb.loadFromFile("input.xlsx");

// Create export options
MarkdownOptions options = new MarkdownOptions();

// Set whether to save images using relative paths
options.setSavePicInRelativePath(true);

// Set whether to format hyperlinks as Markdown reference-style links
options.setSaveHyperlinkAsRef(true);

wb.saveToMarkdown("output.md", options);
Bug SPIREXLS-6023 Fixes the issue where adding EMF images to headers caused an exception.
Bug SPIREXLS-6036 Fixes the issue where the KeepDataType setting failed to preserve original data types.
Bug SPIREXLS-6038 Fixes the issue where image quality was degraded when converting Excel to PDF.
Bug SPIREXLS-6043 Fixes the issue where date formulas were calculated incorrectly in French locale.
Bug SPIREXLS-6046 Fixes the issue where converting HTML to Excel threw an IOException.

Spire.Presentation

Category ID Description
New feature SPIREPPT-2994 Added support for compressing images.
Presentation presentation = new Presentation();
presentation.LoadFromFile(inputFile);

foreach (ISlide slide in presentation.Slides)
{
    foreach (Spire.Presentation.IShape shape in slide.Shapes)
    {
        if (shape is SlidePicture)
        {
            SlidePicture ps = shape as SlidePicture;
            // Compress the image: remove cropped areas (true) and set target resolution to 150 DPI (commonly used for web display)
            ps.PictureFill.CompressImage(true, 150f);
        }
    }
}
presentation.SaveToFile(outputFile, FileFormat.Pptx2013);
New feature SPIREPPT-3004 Added support for configuring output image DPI when converting slides to images.
presentation.SaveToImage(int pageIndex, int dpiX, int dpiY);
Bug SPIREPPT-3016 Fixed an issue where bullet points were rendered incorrectly after converting PPTX to PDF.
Bug SPIREPPT-3019 Fixed an issue where content was clipped after converting PPTX to PDF.
Bug SPIREPPT-3031 Fixed an issue where slide backgrounds were displayed incorrectly after converting PPTX to PDF.
Bug SPIREPPT-3048 Fixed an issue that loading a PPTX document threw a “Object reference not set to an instance of an object.” exception.

Spire.PDF

Category ID Description
Adjustment Enhanced the underlying rendering logic for converting PDFs to images on the WPF platform, resulting in significantly improved output image quality.
Optimization SPIREPDF-7855 Optimized slow web printing requests in the .NET Standard DLL.
New feature SPIREPDF-7826 Deprecated the PdfFreeTextAnnotation.TextAlignment property and added the new PdfFreeTextAnnotation.StringFormat property to support horizontal and vertical text alignment.
PdfDocument newPdf = new PdfDocument();
PdfPageBase page = newPdf.Pages.Add();
Spire.Pdf.Graphics.PdfFont font = new PdfFont(PdfFontFamily.Helvetica, 10f);
SizeF textSize = font.MeasureString("sample");

RectangleF rect = new RectangleF(50,50, textSize.Width, textSize.Height);
Spire.Pdf.Annotations.PdfFreeTextAnnotation textAnnotation = new Spire.Pdf.Annotations.PdfFreeTextAnnotation(rect);

textAnnotation.Text = "sample";
textAnnotation.Subject = "subject";
textAnnotation.Font = font;
Spire.Pdf.Annotations.PdfAnnotationBorder border = new Spire.Pdf.Annotations.PdfAnnotationBorder(8);
textAnnotation.Border = border;
textAnnotation.LineEndingStyle = Spire.Pdf.Annotations.PdfLineEndingStyle.None;
textAnnotation.Size = new SizeF(textSize.Width * 1.5F, textSize.Height * 1.5F);
textAnnotation.StringFormat.Alignment = PdfTextAlignment.Center;
textAnnotation.StringFormat.LineAlignment = PdfVerticalAlignment.Middle;
page.Annotations.Add(textAnnotation);
newPdf.SaveToFile(result);
Bug SPIREPDF-2261 Fixed the issue where Arabic characters entered into form fields were displayed with incorrect text direction.
Bug SPIREPDF-4834 Fixed the issue where content became inconsistent when converting XPS to PDF.
Bug SPIREPDF-6712, SPIREPDF-6873 Fixed the issue where Arabic and Hebrew text rendered incorrectly when converting PDF to PDF/A-3a.
Bug SPIREPDF-7526 Fixed the issue where text blocks were unnecessarily split into multiple lines during PDF-to-PPTX conversion.
Bug SPIREPDF-7816 Fixed the issue where removing annotation borders had no effect.
Bug SPIREPDF-7828 Fixed the issue where a System.Exception was thrown during OFD-to-PDF conversion.
Bug SPIREPDF-7810 Fixed the issue where converting PDF files with annotations to images threw an “ArgumentException”.
Bug SPIREPDF-7856 Fixed the issue where converting OFD files to PDF threw a “NullReferenceException”.
Bug SPIREPDF-7858 Fixed the issue where the .NET Standard DLL printed PDF documents to an incorrect output path when using a virtual printer.
Bug SPIREPDF-7872 Fixed the issue where converting PDF files to PPTX threw a “Parameter is not valid.” exception.

We're glad to announce the release of Spire.PDF for Android via Java 10.7.9. This version adds support for converting PDF to Markdown. Details are listed below.

Here is a list of changes made in this release

Category ID Description
New feature - Adds support for converting PDF to Markdown.
PdfDocument pdf = new PdfDocument(inputFile);
 pdf.saveToFile(OutputFile, FileFormat.Markdown);

PdfDocument pdf = new PdfDocument();
        pdf.loadFromFile(inputFile);
        ByteArrayOutputStream ms = new ByteArrayOutputStream();
        pdf.saveToStream(ms, FileFormat.Markdown);
        FileOutputStream outputStream = new FileOutputStream(new File(OutputFile));
        outputStream.write(ms.toByteArray());
        outputStream.close();
        pdf.dispose();
Click the link below to download Spire.PDF for Android via Java 10.7.9:
Tuesday, 30 December 2025 08:00

Spire.Office for Java 10.12.0 is released

We are pleased to announce the release of Spire.Office for Java 10.12.0. In this version, Spire.Doc for Java supports verifying whether the write-protection password is correct; Spire.PDF for Java reduces the file size of split PDF documents; Spire.XLS for Java optimizes the logic for handling long text in headers. This version also addresses a number of known issues and minor fixes across other components. Details are provided below.

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

Below is a summary of the changes included in this release.

Spire.Doc for Java

Category ID Description
New feature - Added a new method to support verifying whether the write-protection password is correct.
Boolean protectionPassword = document.checkWriteProtectionPassword("password");
Bug SPIREDOC-10684 SPIREDOC-11670 Fixed an issue where text line breaks were inconsistent when converting Word to PDF.
Bug SPIREDOC-11340 Fixed an issue where paragraph indentation was inconsistent when converting HTML to Word.
Bug SPIREDOC-11617 Fixed an issue where retrieving bookmarkEnd failed.
Bug SPIREDOC-11618 Fixed an issue where a “NullPointerException” was thrown when replacing bookmarks.
Bug SPIREDOC-11619 Fixed an issue where bookmark tags were altered after bookmark replacement.
Bug SPIREDOC-11624 Fixed an issue where a “NullPointerException” was thrown during Word-to-PDF conversion.
Bug SPIREDOC-11636 Fixed an issue where equation parentheses were missing when converting Word to PDF.
Bug SPIREDOC-11637 Fixed an issue where an exception was thrown when retrieving bookmark content inside form content control.
Bug SPIREDOC-11642 Fixed an issue where detection of document write-protection passwords was inaccurate.
Bug SPIREDOC-11646 Fixed an issue where a “Text shaper failed” exception was thrown during Word-to-PDF conversion when text shaping was enabled.
Bug SPIREDOC-11649 Fixed an issue where content overlapped when converting Word to PDF.
Bug SPIREDOC-11669 Fixed an issue where a “ClassCastException” was thrown when converting HTML to Word.
Bug SPIREDOC-11677 Fixed an issue where text replacement was incorrect when setReplaceFirst was set to true.
Bug SPIREDOC-11689 Fixed an issue where tables were misaligned when converting Word to PDF.
Bug SPIREDOC-11697 Fixed an issue where images were incompletely rendered when converting Word to PDF.

Spire.XLS for Java

Category ID Description
Adjustment SPIREXLS-5909 Optimized the logic for handling text exceeding 253 characters in headers. When the limit is exceeded, an error message is now displayed: "The text string for header is too long.
Bug SPIREXLS-6033 Fixed the issue where loading an Excel document caused a StringIndexOutOfBoundsException.
Bug SPIREXLS-6039 SPIREXLS-6040 Fixed the issue where copying a worksheet containing curves threw a NullPointerException.
Bug SPIREXLS-6041 Fixed the issue where Excel-to-PDF conversion resulted in an error: "Error in Cell: AH125-null"70S シルバー&サイズ=-".
Bug SPIREXLS-6042 SPIREXLS-6052 Fixed the issue where false positive virus detections occurred by Huorong and Avira antivirus software when scanning the JAR file.

Spire.PDF for Java

Category ID Description
Bug SPIREPDF-7837 Fixed an issue where the size of individual PDF files generated after splitting a PDF was larger than that of the original PDF.
Bug SPIREPDF-7844 Fixed an issue where the retrieved value of combo boxes was incorrect.
Bug SPIREPDF-7857 Fixed an issue where retrieving the checked state of checkboxes threw an ArrayIndexOutOfBoundsException.
Bug SPIREPDF-7859 Fixed an issue where accessing a PDF page threw a NullPointerException.
Bug SPIREPDF-7865 Fixed an issue where converting OFD to PDF threw an exception “ofd.xml not found!”.

Spire.Presentation for Java

Category ID Description
Bug SPIREPPT-3025 Fixed the issue where the formula "\square" in PowerPoint was displayed incorrectly on Mac.

We’re pleased to announce the release of Spire.PDF for Java 11.12.16. This version reduced the file size of spilt PDF documents, and fixed several known bugs related to form fields and OFD to PDF conversion. More details are as follows.

Here is a list of changes made in this release

Category ID Description
Bug SPIREPDF-7837 Fixed an issue where the size of individual PDF files generated after splitting a PDF was larger than that of the original PDF.
Bug SPIREPDF-7844 Fixed an issue where the retrieved value of combo boxes was incorrect.
Bug SPIREPDF-7857 Fixed an issue where retrieving the checked state of checkboxes threw an ArrayIndexOutOfBoundsException.
Bug SPIREPDF-7859 Fixed an issue where accessing a PDF page threw a NullPointerException.
Bug SPIREPDF-7865 Fixed an issue where converting OFD to PDF threw an exception “ofd.xml not found!”.
Click the link below to download Spire.PDF for Java 11.12.16:
Page 1 of 12