Skip to content

Foxit PDF SDK v11.1

Release date: March 31, 2026

Incompatible Changes

The following changes require code updates when upgrading from v11.0. Projects that are not updated will fail to compile or may behave unexpectedly.

ActionCallback — Interface Parameter Changes and New Pure Virtual Methods

The ActionCallback class has 1 interface parameter change and 7 new pure virtual methods. All subclasses must be updated.

Parameter changeGetPageWindowRect adds document and page_index parameters:

cpp
// v11.0
virtual RectF GetPageWindowRect() = 0;

// v11.1
virtual RectF GetPageWindowRect(const foxit::pdf::PDFDoc& document, int page_index) = 0;

New pure virtual methods — If you do not need the related functionality, implement them as empty function bodies:

cpp
virtual void NotifyBeginDoJob(const pdf::PDFDoc& document,
    JavascriptModifyItemInfo::JavascriptEventType event_type) = 0;
virtual void NotifyAfterDataChange(const pdf::PDFDoc& document,
    JavascriptModifyItemInfo modify_item_info) = 0;
virtual void NotifyEndDoJob(const pdf::PDFDoc& document,
    JavascriptModifyItemInfo::JavascriptEventType event_type) = 0;
virtual bool InitModifyItem(const pdf::PDFDoc& document,
    ModifyItemType item_type, int page_index, const WString& dict_name) = 0;
virtual void ResetModifyItem(const pdf::PDFDoc& document) = 0;
virtual int GetVisiblePageCount(const pdf::PDFDoc& document) = 0;
virtual int GetVisiblePage(const pdf::PDFDoc& document, int index) = 0;

DocProviderCallback — New Pure Virtual Method (XFA)

A new pure virtual method was added. All DocProviderCallback subclasses must implement it:

cpp
virtual void NotifyWidgetChangeInfo(const XFADoc& doc, XFAWidgetModifyInfo change_info) = 0;

This affects projects that use the XFA module only. If you do not need the related functionality, implement it as an empty function body.

IconProviderCallback::GetIcon — Interface Parameter Change (Silent Failure)

The parameters of the GetIcon method have changed. Because this method is not pure virtual, compilation will not fail, but existing subclass overrides will silently stop working and will no longer be called by the SDK:

cpp
// v11.0
virtual PDFPage GetIcon(Annot::Type annot_type, const char* icon_name, ARGB color);

// v11.1
virtual PDFPage GetIcon(Annot::Type annot_type, const char* icon_name, ARGB color,
                        foxit::pdf::objects::PDFDictionary* annot_dict);

Required action: Update the parameter list of your override to include the new annot_dict parameter. Consider enabling -Woverloaded-virtual (GCC/Clang) or /W4 (MSVC) to detect such issues at compile time.

OCRCallback — New Pure Virtual Method

The existing OCRCallback class adds the pure virtual method IsImageIgnored:

cpp
// v11.0
class OCRCallback {
  virtual bool NeedToCancelNow(const wchar_t* info) = 0;
};

// v11.1
class OCRCallback {
  virtual bool NeedToCancelNow(const wchar_t* info) = 0;
  virtual bool IsImageIgnored(foxit::pdf::graphics::ImageObject* image_object) = 0; // 新增
};

Required action: All OCRCallback subclasses must implement IsImageIgnored. Returning false preserves the previous behavior (do not ignore any images).

OCRConfig Constructor and Set() — Parameter Changes

The parameterized constructor and the Set() method add 3 required parameters:

cpp
// v11.0 (5 parameters)
OCRConfig(bool is_detect_pictures, bool is_remove_noise, bool is_correct_skew,
          bool is_enable_text_extraction_mode, bool is_sequentially_process);

// v11.1 (8 parameters)
OCRConfig(bool is_detect_pictures, bool is_remove_noise, bool is_correct_skew,
          bool is_enable_text_extraction_mode, bool is_sequentially_process,
          bool is_auto_overwrite_resolution, int resolution_to_overwrite, int confidence);

Required action: Add the 3 new parameters. Using true, 300, 0 preserves the previous default behavior. You can also use the default constructor, which initializes all fields to default values automatically.

OCR::OCRPDFPage / OCRPDFDocument / OCRConvertTo / OCRPDFDocuments — New Parameter

All OCR processing methods add an OCRProgressCallback* parameter:

cpp
// v11.0
void OCRPDFPage(PDFPage pdf_page, bool is_editable);
void OCRPDFPage(PDFPage pdf_page, bool is_editable, const OCRConfig& config);
// OCRPDFDocument, OCRConvertTo, OCRPDFDocuments follow the same pattern

// v11.1
void OCRPDFPage(PDFPage pdf_page, bool is_editable, OCRProgressCallback* callback = NULL);
void OCRPDFPage(PDFPage pdf_page, bool is_editable, const OCRConfig& config, OCRProgressCallback* callback = NULL);
  • C++: The default value is NULL, so existing calls do not need to change.
  • C# / Python / Java / Node.js / Go: The binding layer does not inherit C++ default parameter values. Existing calls must explicitly pass the new parameter (pass null / None / nil to preserve previous behavior).

PDF to Office — API Parameter Changes

The following conversion APIs have incompatible changes in this version. For a detailed migration guide and code examples, see Conversion SDK v3.1.0 Release Notes — Incompatible Changes.

  1. PDF2WordSettingData — Adds required parameter max_blank_paragraphs_per_page_bottom; default value of enable_generate_headers_and_footers changes from false to true
  2. PDF2PowerPointSettingData — Adds required parameter enable_adapt_to_largest_page
  3. PDF2ExcelSettingData — Adds required parameters enable_aggressive_table_repair and include_watermarks
  4. PDF2OfficeSettingData — Adds required parameter enable_matching_system_fonts
  5. PDF to Word now preserves internal document navigation links by default

New Features and Enhancements

Platform

  • Added Node.js v21 and v22 support (extended from v10–v20 to v10–v22)
  • Added Node.js macOS platform support
  • Added Chinese developer API documentation

Conversion

  • Added Windows WPS engine to PDF conversion: Convert::FromWord/Excel/PowerPoint(..., e_Office2PdfEngineWps)
  • Added precise system font matching switch for PDF to Word: PDF2OfficeSettingData::enable_matching_system_fonts
  • Updated PDF to Word to preserve internal document navigation links by default
  • Added page size adaptation strategy for PDF to PPT: PDF2PowerPointSettingData::enable_adapt_to_largest_page
  • Added table structure repair and watermark output controls for PDF to Excel: PDF2ExcelSettingData::enable_aggressive_table_repair / include_watermarks
  • Added Linux Office2PDF font embedding switch: Office2PDFSettingData::is_embed_font
  • Added Conversion SDK version query APIs: Office2PDF::GetVersion() / PDF2Office::GetVersion()
  • Updated Office2PDF::ConvertFromWord to support DOC (Word 97–2003) format

OCR

  • Added progress callback: OCRProgressCallback class reports progress through ProgressNotify(int current_rate)
  • Added Arabic language support: OCREngine::SetLanguages("Arabic")
  • Added configuration parameters: OCRConfig::confidence (confidence threshold) and OCRConfig::resolution_to_overwrite (resolution override)
  • Added command-line multiprocess parallel OCR tools: ocr_win64.exe / ocr_linux64
  • Added image filtering callback: OCRCallback::IsImageIgnored(ImageObject*)

Rendering

  • Added overprint rendering support: Renderer::SetOverprint(bool is_to_enable_overprint)

Signature and Security

  • Added pre-signature self-modification tracking callbacks: InitModifyItem(), ResetModifyItem(), NotifyBeginDoJob(), NotifyAfterDataChange(), and NotifyEndDoJob() in ActionCallback; added DocProviderCallback::NotifyWidgetChangeInfo() for XFA widget change tracking
  • Added CertChainResolverCallback and TrustedCertStoreCallback to support LTV enablement across CA systems (used in LTVVerifier)
  • Added Redaction::EnableFileStream() to reduce memory peaks in high-volume redaction scenarios by writing through file streams

Forms and Annotations

  • Added 29 XFA event types to XFADoc::EventType for fine-grained event handling (Click, Change, Enter, Exit, PreSign, PostSign, PreSave, PostSave, and more)
  • Updated IconProviderCallback::GetIcon with a new annot_dict parameter for access to annotation dictionaries

Document and Page

  • Updated ActionCallback::GetPageWindowRect with new document and page_index parameters for JavaScript layer (OCG) control
  • Added ActionCallback::GetVisiblePageCount() and ActionCallback::GetVisiblePage() to query visible pages in multi-page views
  • Added structured tag removal methods: PDFDoc::RemoveStructTree(), PDFStructTree::RemoveChild(), StructElement::RemoveChild()
  • Added Font::IsCharSupported(uint32 unicode, const PDFDoc& document) for character support detection
  • Added Library::AddExternalFontPath() and Library::MatchExternalFontsOnly() for external font path management

3D

  • Added PDF3DContext::Add3DAnnot() to insert 3D annotations on specified pages (file path and ReaderCallback modes)
  • Added 3D preset view and model tree interaction: PDF3DAnnotInstance::ApplyPresetView(), GetPresetViewList(), ModelNode class, and node visibility control

Optimization

  • Added transparency optimization with low/medium/high resolution modes: OptimizerSettings::SetTransparencyMode()

Bug Fixes

Conversion

  • Fixed PDF to Word generating crop marks at page corners, causing third-party translation tools to fail opening the output
  • Improved PDF to Word cross-application rendering consistency (between Microsoft Office and WPS Office)
  • Fixed PDF to Excel placing cell text inside shapes instead of directly in cells
  • Fixed PDF to Excel rendering table borders as bitmaps overlaid on top of tables
  • Fixed PDF to Excel conversion taking too long and presenting cells as images
  • Fixed PDF to PPT producing abnormal page sizes with content shrunk to the upper-left corner
  • Fixed crash in Office2PDF::ConvertFromWord when processing specific DOCX files
  • Fixed incorrect character spacing in Word to PDF causing incorrect line breaks
  • Fixed overly bold bold text in Word to PDF
  • Fixed missing text at the end of documents in Word to PDF
  • Fixed shape misalignment and incorrect line breaks in Word to PDF
  • Fixed missing text content after converting specific OFD files to PDF

OCR

  • [Linux] Fixed OCRConvertTo failure (ERR_FREN_NO_PAGES) caused by missing Chinese fonts
  • Fixed OCRConvertTo error (ERR_IMAGE_LIBJPEG_LIBRARY_RAISED_ERROR) on specific files
  • Fixed OCRConvertTo on 44-page documents outputting only the first page

Rendering

  • Fixed incorrect CMYK to ARGB color conversion in Bitmap DIBFormat
  • [Performance] Fixed progressive render time increasing with multiple open documents (17s→24s→30s→40s)
  • Fixed OutputPreview::SetSimulationProfile() not correctly reflecting different ICC profiles
  • Fixed missing text when rendering specific PDFs in OutputPreview
  • Fixed page rendering inconsistency with Adobe for specific PDFs
  • Fixed crash when saving a Bitmap created with e_DIBRgb through Image::SaveAs
  • Fixed rendering anomalies after adding PathObject to specific document pages
  • Fixed memory not being released when calling delete() on a Bitmap constructed from a buffer

Printing

  • Fixed color deviation and uneven dot patterns in PrintManager output
  • Fixed intermittent crashes when using PrintManager in multithreaded scenarios
  • Fixed FXPM_AddPDFFromFileToJob and FXPM_SetJobDocumentName not supporting CJK paths
  • Fixed FXPM_SetJobDuplex(1) not enabling duplex printing
  • Fixed mixed-orientation page content not rotating with page orientation
  • Fixed SetRotation() causing landscape PDFs to print with portrait text orientation
  • Fixed PrintJob printing only the first file when multiple files are added through AddPDFFromFile

Forms

  • Fixed XFA ExportData/ImportData loop operations corrupting headers and digital signatures
  • Fixed XFA TextField widget proliferation causing progressively longer open times until crash
  • Fixed C# ViewDemo rendering blank pages for specific XFA documents
  • Fixed JavaScript layer (OCG) visibility control not working
  • [Regression] Fixed v11 ActionCallback regression where some callbacks no longer fired after field modifications
  • Fixed "inherit zoom" bookmark targets applying only to the first bookmark

Document and Page

  • Fixed crash when calling SaveAs (e_SaveFlagLinearized) after StartEmbedAllFonts
  • Fixed fxhtml2pdf becoming a zombie process after Html2PDF timeout
  • [Performance] Fixed StartSplitByFileSize on 25,000-page PDFs taking more than 1 hour
  • Fixed excessive Redaction memory peaks in continuous high-volume redaction scenarios
  • [Windows] Fixed ComplianceEngine::SetTempFolderPath() writing temporary files to the executable directory instead of the system temp directory
  • Fixed C# TextPage.GetTextInRect returning question marks for specific characters
  • Fixed GetEditingTextCaretPosition returning incorrect positions and offsetting IME candidate windows

Other

  • Fixed visual artifacts from multiprocess parallel Optimizer image compression
  • Fixed blank display after clicking 3D annotation areas in specific 3D PDFs
  • Improved AutoTagging recognition accuracy for Figure-type images (compared with Adobe Auto-Tag)
  • Fixed Comparison incorrectly matching content in OCR documents