SignDoc SDK (C)  5.0.0
Migrating from SignDoc SDK 4.3.1 to SignDoc SDK 5.0.0

SignDoc SDK is no longer available for 32-bit iOS.

SIGNDOC_DocumentLoader_getInstallationCode() and SIGNDOC_DocumentLoader_initLicenseManager() have been removed as license files are no longer supported.

All classes now share the same return code constants (names and values), the class name has been removed from the return code constant names. For instance, SIGNDOC_DOCUMENT_RETURNCODE_OK has been renamed SIGNDOC_RETURNCODE_OK.

The following constants have been renamed:

  • SIGNDOC_FIELD_CERTSEEDVALUEFLAG_* (now SIGNDOC_FIELD_CERTSEEDVALUEFLAGS_*)
  • SIGNDOC_FIELD_FLAG_* (now SIGNDOC_FIELD_FLAGS_*)
  • SIGNDOC_FIELD_WIDGETFLAG_* (now SIGNDOC_FIELD_WIDGETFLAGS_*)

SIGNDOC_DocumentLoader_pingMemory(), SIGNDOC_DocumentLoader_loadFontConfigBlob(), SIGNDOC_DocumentLoader_loadPdfFontConfigBlob(), and SIGNDOC_DocumentLoader_loadTrustedCertificatesFromMemory() have been added. SIGNDOC_DocumentLoader_createPDF(), SIGNDOC_DocumentLoader_createPDFA(), SIGNDOC_DocumentLoader_loadFromFile(), SIGNDOC_DocumentLoader_loadFromMemory() now return a return code and give back the document via an output parameter.

Document coordinates for PDF documents now always use 72 units per inch (that is, SignDoc SDK takes UserUnit into account). Function SIGNDOC_Document_getConversionFactors() is no longer needed.

SIGNDOC_SignPKCS7_sign(), SIGNDOC_SignRSA_sign(), and SIGNDOC_SignECDSA_sign() now use strings rather than integers for identifying the hash algorithm. SIGNDOC_SignRSA_sign() now uses a string rather than an integer for identifying the signature scheme, the salt length is passed as separate parameter. SIGNDOC_TimeStamper_getHashAlgorithm() has been renamed SIGNDOC_TimeStamper_getHashAlgorithmOID(), SIGNDOC_TimeStamper_getFallbackHashAlgorithm() has been renamed SIGNDOC_TimeStamper_getFallbackHashAlgorithmOID().

Integer parameters "CertificateSigningAlgorithm", "DetachedHashAlgorithm", "RSASignatureScheme", and "TimeStampHashAlgorithm" of SIGNDOC_SignatureParameters have been replaced with string parameters of the same names.

SIGNDOC_SignatureParameters_addTextItem(), SIGNDOC_SignatureParameters_addTextItem2(), and SIGNDOC_SignatureParameters_setTextItemDirection() now use strings for identifying the text item.

Integer parameter "Optimize" can now be set to SIGNDOC_SIGNATUREPARAMETERS_OPTIMIZE_OPTIMIZE without setting string parameter "OutputPath". There is a new value, SIGNDOC_SIGNATUREPARAMETERS_OPTIMIZE_IF_POSSIBLE, which is now the default value for integer parameter "Optimize".

SignDoc SDK now adds text in logical order and uses ActualText where necessary.

Flags SIGNDOC_DOCUMENT_FINDTEXTFLAGS_IGNORE_HSPACE and SIGNDOC_DOCUMENT_FINDTEXTFLAGS_IGNORE_HYPHENATION for SIGNDOC_Document_findText() are now implemented and ActualText is used. (ReversedChars is still ignored.)

SIGNDOC_FindTextPosition has been renamed SIGNDOC_FindTextOccurrence and now contains information about all glyphs making up the found text rather than information about the first and the last glyph. Bounding boxes are now available in most cases. You can extract the text of a PDF document with SIGNDOC_Document_createTextIterator(), e.g., to implement your own text search.

The functions of the SIGNDOC_*Parameters classes no longer return SIGNDOC_*_RETURNCODE_NOT_SUPPORTED, SIGNDOC_*_RETURNCODE_UNKNOWN has been replaced by SIGNDOC_RETURNCODE_UNKNOWN_PARAMETER.

SIGNDOC_RenderParameters now has named parameters (see SIGNDOC_RenderParameters_setInteger() etc.), the old functions like SIGNDOC_RenderParameters_setZoom() have been removed:

OldNew
SIGNDOC_RenderParameters_setPage() "Page" (integer)
SIGNDOC_RenderParameters_setPages() "FirstPage" (integer), "LastPage" (integer)
SIGNDOC_RenderParameters_setResolution() "ResolutionX" (floating-opint number), "ResolutionY" (floating-point number)
SIGNDOC_RenderParameters_setZoom() "Scale" (floating-point number)
SIGNDOC_RenderParameters_fitRect() "Height" (integer), "Width" (integer)
SIGNDOC_RenderParameters_fitHeight() "Height" (integer)
SIGNDOC_RenderParameters_fitWidth() "Width" (integer)
SIGNDOC_RenderParameters_setFormat() "Format" (string)
SIGNDOC_RenderParameters_setInterlacing() "Interlaced" (boolean)
SIGNDOC_RenderParameters_setQuality() "HighQualityScaling" (boolean)
SIGNDOC_RenderParameters_setPixelFormat() "BlackAndWhite" (boolean)
SIGNDOC_RenderParameters_setCompression() "Compression" (string)
SIGNDOC_RenderParameters_setDecorations() "AddDecorations" (boolean)
SIGNDOC_RenderParameters_setDecorationState() "DecorationState" (string, two parameter names)
SIGNDOC_RenderParameters_setPrint() "ForPrinting" (boolean)
SIGNDOC_RenderParameters_setModificationState()"UseModificationState" (boolean)

SIGNDOC_Document_getIntegerProperty() and SIGNDOC_Document_setIntegerProperty() now use a 32-bit integer type for the value of the property on all operating systems.

SIGNDOC_Document_addImageFromBlob has been renamed SIGNDOC_Document_addImageFromMemory, SIGNDOC_Document_addImageFromBlob2 has been renamed SIGNDOC_Document_addImageFromMemory2.

SIGNDOC_Document_copyToMemory(), SIGNDOC_Document_copyAsSignedToMemory(), SIGNDOC_Document_saveToMemory(), SIGNDOC_Document_exportFieldsToMemory(), and SIGNDOC_Document_exportPropertiesToMemory() have been added. They are easier to use than SIGNDOC_Document_copyToStream(), SIGNDOC_Document_copyAsSignedToStream(), and SIGNDOC_Document_saveToStream(), SIGNDOC_Document_exportFields(), and SIGNDOC_Document_exportProperties().

SIGNDOC_Document_convImageRectToPageRect(), SIGNDOC_Document_convPageRectToImageRect(), and SIGNDOC_Document_renderPageAsSignDocImage() have been added.

SIGNDOC_SignatureParameters_getState() has been removed, SIGNDOC_SignatureParameters_getType() has been added.

SIGNDOC_Signature_getMethod() has been added.

Flag SIGNDOC_DOCUMENT_FLAGS_PREVENT_BREAKING_TAGGED_PDF has been replaced by SIGNDOC_DOCUMENT_SHOOTINFOOTFLAGS_ALLOW_BREAKING_TAGGED_PDF which has the opposite meaning, that is, SignDoc SDK by default prevents breaking Tagged PDF.

Some SignWare classes have been reimplemented in SignDoc SDK, see