API changes =========== This file documents those API changes which affect existing PDFlib client programs. Although we go to some efforts in maintaining the existing API functions, it is sometimes necessary to incorporate a few non-backward compatible changes in order to streamline the API and introduce new or extended functions. PPS, PPS API, Block plugin and Acrobat versions =============================================== Acrobat Acrobat PPS PPS API Block plugin Windows OS X ------------------------------------------------------------- 5.0.0 1 1.0.0 5,6 - 5.0.1 2 1.0.1, 1.1 5,6 5,6 6.0.0 3 2.0.0, 2.0.1 5,6 5,6 6.0.1 4 2.0.2 5,6, 5,6 6.0.2 5 2.1.0 5,6,7 5,6,7 6.0.3 6 2.2 5,6,7 5,6,7 6.0.4 6 2.3 5,6,7,8 5,6,7 7.0.0 7 3.0 5,6,7,8 5,6,7 7.0.1 7 3.1 5,6,7,8 5,6,7,8 7.0.2 7 3.2 5,6,7,8 5,6,7,8 7.0.3 7 3.3 5,6,7,8 5,6,7,8 3.3p1 5,6,7,8,9 5,6,7,8,9 7.0.4 7 3.4 5,6,7,8,9 5,6,7,8,9 7.0.5 7 3.5 5,6,7,8,9 8,9 8.0.0 8 4.0 7,8,9 8,9 8.0.1 9 4.1 7,8,9 8,9 8.0.2 9 4.2 7,8,9 8,9 8.0.3 9 4.3 8,9,X 8,9,X (first build based on wxWidgets) 8.0.4 9 4.4 8,9,X 8,9,X 8.0.5 9 4.5 8,9,X,XI 8,9,X,XI 8.0.6 9 4.6 8,9,X,XI 8,9,X,XI 9.0.0 10 5.0 8,9,X,XI 8,9,X,XI (graphics Blocks for SVG) 9.0.1 10 5.1 8,9,X,XI 8,9,X,XI 9.0.2 10 5.2 8,9,X,XI 8,9,X,XI 9.0.3 10 5.3 8,9,X,XI 8,9,X,XI 9.0.4 10 5.4 8,9,X,XI 8,9,X,XI 9.0.5 10 5.5 8,9,X,XI,DC 8,9,X,XI,DC 9.0.6 10 5.6 8,9,X,XI,DC 8,9,X,XI,DC Identifying deprecated API functions ==================================== Incompatible changes will not be introduced between a particular version and its successor. Instead, features are first declared as deprecated. You can identify deprecated features in your code with the following methods: - All language bindings (runtime) PDFlib will emit a warning in the log file if the "logging" option is set to "api=2". - C binding (compile time) Visual Studio 2003 and above emit a compilation warning. - PHP binding (run time) PHP 5.3 and above emit a warning in the error log. - Java binding (compile time) The pdflib.jar module marks deprecated APIs. Depending on the JDK and compiler settings some compilers will warn about the use of deprecated APIs when compiling the application source code. For the Sun JDK you can use the compiler option "-Xlint:deprecation". - .NET binding (editing time) IntelliSense popups displayed by Visual Studio 2005 and above contain a warning for deprecated methods. PDFlib 9.0.6 ============ No changes which affect compatibility. PDFlib 9.0.5 ============ PDF_open_pdi_document() no longer reads Tagged PDF structure by default if called in object scope, i.e. if no output document is open. If the PDI document is intended for use with a Tagged PDF output document, the option usetags=true must be provided. PDFlib 9.0.4 ============ No changes which affect compatibility. PDFlib 9.0.3 ============ No changes which affect compatibility. PDFlib 9.0.2 ============ Modified Parameter Names ------------------------ The following functions used parameter names x_1, y_1 etc. instead of the documented names x1, y1 etc.: PDF_circular_arc(), PDF_curveto(), PDF_rcurveto(), PDF_shading() These have been changed to use the documented names. Objective-C: this change requires corresponding parameter name adjustments in client code. Deprecated Option ----------------- Font options: "autocidfont" is deprecated and no longer functional due to internal changes in the font engine. Deprecated Function ------------------- PDF_begin_pattern(): use PDF_begin_pattern_ext() (now for all bindings) Font handling ------------- Due to feature #1625 and bug #4559 (modified treatment of fonts for form fields) fonts may now be embedded by default. If this is not desired font embedding can be disabled with "embedding=false". Tagged PDF ---------- Artifacts are no longer allowed when the currently active element is a pseudo element or one of Span, Quote, Note, Reference, BibEntry, Code with inline=true. PDFlib 9.0.1 ============ New API function ---------------- PDF_begin_pattern_ext() (only for C and C++) New option ---------- Option "transform" for PDF_begin_template_ext() Deprecated Functions -------------------- PDF_xshow(): use PDF_fit_textline() with "xadvancelist" option (PDF_xshow() is available only in the C and C++ language bindings) XMP metadata ------------ Implemented stricter XMP namespace checks for PDF/A-2 and PDF/A-3 to follow the XMP 2005 spec and match the behavior of Acrobat Preflight: namespace URIs are now required to end in a "/" or "#" character. Otherwise the XMP will be rejected. Tagged PDF ---------- Modified the handling of H7, H8 etc. so that they are no longer treated as standard elements, but require rolemap entries. Since PDF/UA consumers are advised to ignore the rolemapping PDFlib also ignores the rolemaps of H7 etc. in PDF/UA mode (other than writing them to the PDF output). PDFlib 9.0 ========== New API functions ----------------- PDF_begin_glyph_ext() PDF_close_graphics() PDF_fill_graphicsblock() PDF_fit_graphics() PDF_get_option() PDF_get_string() PDF_info_graphics() PDF_load_asset() PDF_load_graphics() PDF_set_graphics_option() PDF_set_text_option() Modified Functionality ---------------------- PDI: The checks for PDF/A, PDF/X and PDF/UA compatibility were moved from PDF_open_pdi_document() to PDF_open_pdi_page(). This may slightly change the behavior of applications since incompatible documents can now be opened, but no pages can be imported from such documents. PDI now imports layer definitions by default. As a result the output contains layer definitions if the input contains layers. Previously all layer definitions were dropped upon import. In order to restore the previous behavior supply the option uselayers=false in PDF_open_pdi_document(). Layers for PDF/X: PDF_set_layer_dependency(): changed the default of "createorderlist" to "true" also in the PDF/X case to improve compatibility with Acrobat X. Standard Output Intents for PDF/X: The "StandardOutputIntent" resource category for UPR files is deprecated. Image clipping paths: If the "clippingpathname" of PDF_load_image() was supplied although the image does not contain any clipping path at all, the option was silently ignored. Now PDF_load_image() correctly emits an error "Couldn't find clipping path". Image orientation for JPEG images: PDF_load_image() now interprets the orientation tag in the Exif marker of JPEG images and automatically rotates the image accordingly. The image output looks different than with PDFlib <= 8 if the orientation tag is different from 1. Workaround: use the option ignoreorientation=true in PDF_load_image() or PDF_fit_image() sRGB treatment of JPEG images with Exif marker: JPEG images with an Exif marker which contains the entry "uncalibrated colorspace" are no longer treated as sRGB, but rather as DeviceRGB to match the Exif specification. Such images are very rare, though. Workaround: you can force sRGB handling by supplying the "iccprofile" option to PDF_load_image(). 16-bit image masks: Acrobat 7/8/9 do not handle 16-bit images with an alpha channel correctly. In order to work around this problem you can use the "downsamplemask" option of PDF_load_image(). By default no downsampling is applied; this differs from PDFlib 8 which always reduced 16-bit masks to 8-bit. Tagged PDF: PDF_begin_item() and the "tag" option of various functions reject the "Alt" or "ActualText" option if some ancestor in the structure hierarchy already has the same attribute. The "taborder" option of PDF_begin/end_page_ext() has the new default "structure" in Tagged PDF mode (previously: "none") in order to work around problems in Tagged PDF validators. Nesting of tags is now checked according to ISO 32000-1. This may result in exceptions for applications which apply tags in wrong nesting order. The checks can be disabled with the document option "checktags=none" to migrate legacy applications. However, it is strongly recommended to adjust the application code to work with checktags=strict to ensure accessible PDF output. Standard CJK fonts: The concept of "Standard CJK fonts" is deprecated. Use externally configured TrueType (TTF, TTC) or OpenType (TTF, OTF) fonts instead (with or without font embedding). Note that PDFlib GmbH offers free Japanese fonts for PDFlib users at www.pdflib.com. PDF 1.3 output: PDF output according to compatibility=1.3 is no longer supported although still functional. However, if encryption is requested the PDF version is automatically bumped to PDF 1.4 to avoid weak RC4 encryption with 40-bit keys. Deprecated Options ------------------ PDF_create_annotation(): options "filename" and "mimetype": use "attachment" PDF_load_font(): options "fontstyle" and "monospace": use suitable fonts instead Deprecated Keywords ------------------- PDF_info_textline(): keywords "scalex" and "scaley": use "fitscalex" and "fitscaley" Deprecated Functions -------------------- PDF_begin_glyph(): use PDF_begin_glyph_ext() PDF_set_parameter(), PDF_set_value(): use PDF_set_option(), PDF_set_text_option() and PDF_set_graphics_option() PDF_get_parameter(), PDF_get_value(): use PDF_info_option() and PDF_get_string() PDF_get_majorversion(), PDF_get_minorversion(): use PDF_get_option() PDF_setdash(), PDF_setdaspattern(), PDF_setflat(), PDF_setlinejoin(), PDF_setlinecap(), PDF_setmiterlimit(), PDF_initgraphics(): use PDF_set_graphics_option() PDF_add_thumbnail(): It is recommended to completely avoid this feature since PDF viewers create thumbnails automatically. Deprecated Parameters --------------------- The parameter/value system with PDF_get_parameter/value() is generally deprecated, and corresponding options of the same name should be used with PDF_set_option() etc. However, no corresponding global options are available for the following keywords for PDF_get/set_parameter(): honoriccprofile: use the "honoriccprofile" option of PDF_load_image() renderingintent: use the "renderingintent" option of PDF_load_image() topdown: use the "topdown" option of PDF_begin_page_ext() setcolor:iccprofilegray/rgb/cmyk: use the "iccprofilegray/rgb/cmyk" graphics appearance option C++ binding ----------- The convert_to_unicode() method incorrectly used type "string" for the "inputformat" and "options" parameters. This was wrong and has been changed to "pstring" (which maps to "wstring" in the default configuration). Java binding ------------ The name of the PDFlib native library has been changed: Windows: pdflib_java.dll Unix: libpdflib_java.so etc. OS X: libpdflib_java.jnilib Incompabitilities to PDFlib 8.1 ------------------------------- Incompatible changes between PDFlib 8.1 and 9.0: - PDF_poca_delete(): additional "optlist" parameter - PDF_poca_insert(): the default of the "index" option changed from 0 to -1. PDFlib 8.1 ========== New API functions ----------------- PDF_info_pvf() PDF_convert_to_unicode() PDF_elliptical_arc() PDF_begin_dpart() PDF_end_dpart() PDF_poca_new() PDF_poca_delete() PDF_poca_insert() PDF_poca_remove() Deprecated Functions -------------------- PDF_utf16_to_utf8(), PDF_utf8_to_utf16(), PDF_utf32_to_utf16(), PDF_utf8_to_utf32(), PDF_utf32_to_utf8(), PDF_utf16_to_utf32(): use PDF_convert_to_unicode() Deprecated Options ------------------ PDF_load_image(), option template: use createtemplate PDF_fit_textflow(), option checkwordsplitting: use avoidwordsplitting Incompatible Behavior --------------------- AES encryption Due to known weaknesses in AES-256 according to PDF 1.7ext3 (Acrobat 9) PDFlib no longer encrypts PDF documents with this algorithm, but falls back to AES-128 encryption according to PDF 1.7 instead, which doesn't support Unicode passwords. This implies an incompatible change: If you used one or more of the "userpassword", "masterpassword", or "attachmentpassword" options with characters outside PDFDocEncoding in an existing PDFlib 8 application, you must do one of the following: - switch to newer Acrobat X encryption, i.e. change your code to use compatibility=1.7ext8 - keep the PDF 1.7 encryption and refrain from using Unicode passwords, i.e. restrict the characters in passwords to PDFDocEncoding Object fitting PDF_fit_image(), PDF_add_table_cell(), PDF_fill_imageblock(), and PDF_fill_pdfblock(): the behavior of "fitmethod=auto" changed as follows: - If the object fits into the box the behavior is identical to "nofit", i.e. no scaling (previous versions upscaled small objects). - If the object is larger than the fitbox the "meet" method is applied, i.e. proportional downscaling (this behavior is identical to previous versions). In order to restore the previous behavior change "fitmethod=auto" to "fitmethod=meet". Removed from Documentation -------------------------- The following functions, parameters, and options were already deprecated in PDFlib 8. They were marked as "deprecated" in the PDFlib 8 manual and are no longer documented in the PDFlib 8.1 manual (although they still work): Functions: PDF_begin_template(): use PDF_begin_template_ext() PDF_end_template(): use PDF_end_template_ext() Options: PDF_begin_document(): compatibility=1.3, pdfx=PDF/X-1a:2001, pdfx=PDF/X-3:2002 Parameters: imagewidth imageheight image:iccprofile orientation resx resy PDFlib 8.0.4 ============ New features: - Objective-C language binding for OS X and iOS - Caching of PDI page handles (even closed ones) - Support for PostScript XObjects - object-oriented interface for Python - emit modification date for file attachments Deprecated Keywords ------------------- PDF_info_image(): targetbox, targetx1/x2/x3/x4, targety1/y2/y3/y4: the size of templates with the "reference" option will be calculated automatically. Deprecated Parameters --------------------- PDF_set_parameter(): "license", "licensefile", "nodemostamp": use "license", "licensefile", "avoiddemostamp" of PDF_set_option() Standard output intent names for PDF/X: Updated PDFlib's internal list of standard output intents to reflect the current state of the Characterization Data collection at www.color.org. - Removed the following printing conditions from the list; if you are using these you must embed the corresponding ICC profile: GRACoL2006_Coated1, SWOP2006_Coated3, SWOP2006_Coated5 - Added the following printing conditions which can now be used without embedding an ICC profile: FOGRA45, FOGRA46, FOGRA47 - Removed the following printing conditions from the documentation (but not from the list in the code) since they are no longer recommended by FOGRA: FOGRA27: use FOGRA39 instead FOGRA28: use FOGRA45 instead FOGRA29: use FOGRA47 instead - Removed old PDFlib 5 and 6 compatibility entries since they would result in non-conforming PDF/X output: "OF COM PO P1 F60", "OF COM PO P2 F60", "OF COM PO-P3 F60", "OF COM PO P4 F60", "OF COM NE P1 F60", "OF COM NE P2 F60", "OF COM NE P3 F60", "OF COM NE P4 F60", "SC GC2 CO F30", "Ifra_NP_40lcm_neg+CTP_05.00" PDFlib 8.0.3 ============ New features: - option "barcode" for PDF_create_field/group() - option "type=prc" for PDF_load_3ddata() - options "forcebox" and "expandbox" for PDF_open_pdi_page() PDFlib 8.0.2 ============ New features: - options "colwidthdefault" and "rowheightdefault" for PDF_fit_textflow() - numeric byte code references for symblic fonts with the "&.#;" syntax - automatic synchronization of marked content for Tagged PDF and layers - option "createorderlist" for PDF_set_layer_dependency() - create and import PDF 1.7 extension level 8 (Acrobat X) documents - option "rolemap" for PDF_begin_document() to support custom tags in PDF_begin_item() PDFlib 8.0.1 ============ Block Plugin 4.1 and PPS 8.0.1 ------------------------------ The Block API number has been increased because the Block Plugin and PPS support the following new features: - Support the keyword "auto" for the "position" property in property group "object fitting" for Textline Blocks (but not other Block types). - Support the keyword "_auto" for the "script" property in property group "text preparation". This means that Block PDFs created with Plugin 4.1 will be rejected by Block Plugin 4.0 and PPS 8.0.0! PDFlib 8.0.0 ============ New API functions ----------------- PDF_add_path_point() PDF_add_portfolio_file() PDF_add_portfolio_folder() PDF_align() PDF_begin_mc() PDF_circular_arc() PDF_close_font() PDF_delete_path() PDF_draw_path() PDF_ellipse() PDF_end_mc() PDF_end_template_ext() PDF_info_image() PDF_info_path() PDF_info_pdi_page() PDF_mc_point() PDF_set_option() PDF_utf8_to_utf32() PDF_utf32_to_utf8() PDF_utf16_to_utf32() Block Plugin and PPS -------------------- The "pdiusebox" Block property never worked, and is no longer available. It will silently be ignored by PDFlib 8. C binding --------- Applications which use the PDFlib binding for C must be linked with a C++ compiler since the PDFlib library includes some parts which are implemented in C++. Using a C linker may result in unresolved externals unless the application is explicitly linked against the required C++ support libraries. C++ binding ----------- The C++ binding now supports a wstring-based interface, but can be configured to use the plain C++ string type as in PDFlib 7. See the PDFlib Tutorial for details regarding full source code compatibility with PDFlib 7 applications. However, the recommended approach is to switch to the new wstring interface. Python binding -------------- The non-Unicode aware compatibility binding for Python is no longer documented (but available in the code nevertheless). RPG binding ----------- The function name prefix for the Unicode-aware version of the RPG binding changed from "RPDF_" to "PDF_" since the Unicode-aware binding is now the default. Deprecated functions -------------------- PDF_end_template(): use PDF_end_template_ext() The following functions, parameters, and options were already deprecated in PDFlib 7. They were marked as "deprecated" in the PDFlib 7 manual and are no longer documented in the PDFlib 8 manual (although they still work): Functions: PDF_open_pdi(): use PDF_open_pdi_document() PDF_close_pdi(): use PDF_close_pdi_document() PDF_get_pdi_value(): use PDF_pcos_get_number() PDF_get_pdi_parameter(): use PDF_pcos_get_string() Deprecated Parameters --------------------- imagewidth, imageheight, image:iccprofile, orientation, resx, resy: use PDF_info_image() warning, iccwarning, fontwarning, glyphwarning, imagewarning, pdiwarning: use errorpolicy ascenderfaked, capheightfaked, descenderfaked, fontencoding, fontname, fontstyle, xheightfaked: use PDF_info_font() autocidfont, autosubsetting, unicodemap: use options in PDF_load_font() fontmaxcode, capheight, ascender, descender, xheight, monospace: use PDF_info_font() subsetlimit, subsetminsize: use options in PDF_load_font() errorpolicy=legacy Deprecated Options ------------------ PDF_load_font(): fontwarning, kerning PDF_fit_textline(): locallink, weblink PDF_info_textline(): unmappedglyphs PDF_add/create_textflow(): textwarning PDF_info_textflow(): remainchars PDF_load_image(): imagewarning PDF_open_pdi_document(): pdiwarning PDF_open_pdi_page(): infomode, pdiwarning PDF_process_pdi(): pdiwarning PDF_fill_*block(): glyphwarning, fontwarning, imagewarning, pdiwarning PDF_create_action(): actionwarning PDF_create_annotation(): annotwarning PDF_create_field() and PDF_create_fieldgroup(): fieldwarning many functions: errorpolicy=legacy Fonts ----- OpenType fonts loaded with encoding "unicode" are no longer force-embedded. If embedding is desired you must supply the "embedding" option when loading the font. Text strings for use with symbol fonts (e.g. ZapfDingbats) loaded with encoding=builtin and textformat=ut8 must actually be provided in UTF-8 format. This is different from PDFlib 7 which ignored the textformat in this situation (the PDFlib 7 behavior was a bug which was leveraged by some applications). Images ------ PDFlib 8 will by default interpret an alpha channel in TIFF and PNG images. If this is not desired it can be disabled with the "ignoremask" option of PDF_load_image(). Text output =========== PDFlib 8 will apply kerning by default; in contrast, PDFlib 7 applied kerning by default only in Textflow, and only if the font had been loaded with kerning=true. In order to avoid kerning for compatibility with older versions, set readkerning=false when loading the font, or kerning=false when generating text output. Performance ----------- PDF_load_font(): unlike earlier versions, PDFlib 8 will read kerning values from all loaded fonts by default. If kerning is not required font loading can be accelerated with the "readkerning=false" option. Form fields ----------- PDF_create_field() with type=checkbox or radiobutton: glyphs from ZapfDingbats font (e.g. checkmark) are displayed with incorrect spacing in Acrobat 9 and X due to a bug in Acrobat. As a workaround the option "unicodemap=false" can be used, but this will result in the omission of the ToUnicode CMap. Stricter checks --------------- The output intent for PDF/A and PDF/X must be set before calling any of the following functions: PDF_begin_page_ext() PDF_open_pdi_page() PDF_setcolor() PDF_load_image() This was recommended in earlier versions, but up to PDFlib 7 this rule was not enforced. =============================================================================== PDFlib 7.0.5 ============ (No relevant changes) PDFlib 7.0.4p12 =============== The PHP wrapper now honors the "open_basedir" setting in the php.ini file. This can be considered an incompatible change, but on the other hand it was a bug that PDFlib ignored a PHP security control. PDFlib 7.0.4p6 ============== Setting strokewidth=0 previously used the value of "underlinewidth", but now refers to a builtin default. This may change the linewidth for applications which do not specify any value explicitly, but the new default creates much better results than the old behavior. PDFlib 7.0.4p5 ============== The long deprecated function PDF_setpolydash() is no longer available in the PHP 5.3 binding. PDFlib 7.0.4 ============ Changed the default for the suboption "inputformat" of the option "metadata" (which is supported by various API functions) from "ebcdicutf8" to "utf" on z/OS (incompatible change). iSeries is not affected. Clients must either explicitly specify the desired input format of the XMP file, or submit their XMP in UTF-8. PDFlib 7.0.3 ============ File names in option lists are now treated as hypertext strings. This can be considered downward incompatible, but fixes problems which resulted in non-working PDF output when file names (e.g. for GoToR actions) contained non-ASCII characters which couldn't be mapped to PDFDocEncoding. PDF_info_textline(): option "unmappedglyphs" is deprecated, use "unmappedchars". Modifies the behavior in non-Unicode-aware language bindings for the treatment of name strings in situation "hypertextencoding=unicode" and "usehypertextencoding=true": depending on the BOM, PDFlib now expects UTF-16BE or UTF-16LE (terminated with double null). Previously name strings were treated as host-encoded strings, and UTF-16 strings would trigger an error message. PDFlib 7.0.2 ============ Changes the behavior of repeated calls to PDF_load_font() with the same font/encoding in a slightly incompatible way: when a font is loaded with the embedding option, but already has been loaded earlier without this option, the call will fail (instead of silently ignoring the conflict in the second call). This is important for filling blocks with embedding=true if the same font has already been loaded earlier without embedding. The exact behavior of PDF_load_font() depends on the errorpolicy setting: errorpolicy=legacy: a warning will be logged errorpolicy=return: -1 will be returned errorpolicy=exception: an exception will be thrown. The new behavior is incompatible for errorpolicy=return or =exception, but usually points to a problem in the application which needs to be fixed. PDFlib 7.0.1 ============ The codepages cp932, cp936, cp949, and cp950 for CJK text no longer use Windows system codepages, but the standard CMaps. Therefore the CMaps must be configured in PDFlib when using one of these codepages on Windows (on other systems the CMaps were required in 7.0.0 already). XMP metadata for PDF/A: only the predefined PDF/A schemas are allowed, plus the four schemas required for defining extension schemas. This is incompatible with PDFlib 7.0.0 (which accepted arbitrary custom schemas), but the previous behavior can be considered a bug since it resulted in output which did not fully conform to the PDF/A standard. PDFlib 7.0.0 ============ Font subsetting: the semantics of the "subsetting", "autosubsetting", "subsetlimit", and "subsetminsize" options changed. Text output: the improved font engine in PDFlib 7 checks whether the glyphs required for creating text output are actually available in a given font. Characters in a text string for which the selected font does not contain the appropriate glyph will be replaced (for detailed control see the glyphchecking and replacementchar options), while the text strings were simply passed through by PDFlib 6 and earlier versions. Although this feature improves the accuracy of text output, it may be considered a small incompatibility (but only in situations which should be avoided anyway). Error handling: the new parameter "errorpolicy" allows for more consistent control of exceptions and error returns. The default setting is fully compatible with earlier versions, but we strongly recommend to use the new errorpolicy=return setting, and adjust your application (e.g. check the return value of PDF_load_font()). The default PDF version compatibility has been changed to PDF 1.6. If you need to create documents according to an older PDF version you must set the "compatibility" option in PDF_begin_document() appropriately. General functionality: Clipping paths in TIFF and JPEG images will now be honored, while up to PDFlib 6 they have been ignored. In order to restore the previous ("ignore path") behavior supply the option "honorclippingpath=false" to PDF_load_image(). PDF/X-1:2001 is considered deprecated, and no longer supported. PDF/X-1a:2001 and PDF/X-1a:2003 are still supported, though. PDF_info_textflow(): The values for the keywords leftlinex, leftliney, rightlinex, rightliney, minliney, maxliney are now interpreted in current user coordinates, while in PDFlib 6 they have been returned in user coordinates of PDF_fit_textflow(). The values for the keywords textendx, textendy are now interpreted in current user coordinates, while in PDFlib 6 they have been returned in user coordinates immediately after PDF_fit_textflow(). Required action if you are affected by this change: Avoid any change of the current transformation matrix (e.g. PDF_scale(), PDF_rotate(), PDF_translate()) between the calls to PDF_fit_textflow() and PDF_info_textflow(). Exception handling: The "warning" parameter is deprecated, and will be ignored. If you are interested in non-fatal problems which can be fixed by PDFlib internally enable logging with the "warning" class. Language bindings: Python: there is a new version of the Python wrapper with integrated Unicode support. An old-style Python wrapper without Unicode support is available for compatibility with existing applications. A new PDFlibException object is available in the PDFlib Python binding. Code which caught "except SystemError" (instead of the recommended "except:") must be changed to "except PDFlibException:". Deprecated functions: PDF_open_pdi() and PDF_close_pdi(): use PDF_open_pdi_document() and PDF_close_pdi_document() PDF_begin_template(): use PDF_begin_template_ext() PDF_get_pdi_value(): use PDF_pcos_get_number() PDF_get_pdi_parameter(): use PDF_pcos_get_string() (pCOS paths corresponding to the keys of the deprecated functions can be found in the PDFlib API manual). Deprecated parameters: Use PDF_info_font() instead of using the following deprecated parameters: monospace fontmaxcode ascender capheight xheight descender fontname fontencoding fontstyle ascenderfaked capheightfaked xheightfaked descenderfaked Use the PDF_load_font() option of the same name instead of the following deprecated parameters: autosubsetting autocidfont unicodemap subsetlimit subsetminsize Use the "logging" parameter instead of the following deprecated (unsupported) parameters: trace tracefile Deprecated PDF/X output intents: The following standard output intent names are deprecated, and should no longer be used: OF COM PO P1 F60, OF COM PO P2 F60, OF COM PO-P3 F60, OF COM PO P4 F60, OF COM NE P1 F60, OF COM NE P2 F60, OF COM NE P3 F60, OF COM NE P4 F60, SC GC2 CO F30, Ifra_NP_40lcm_neg+CTP_05.00 Configuration incompatibility: Using any of the predefined CMaps now requires the actual CMap file due to extended text processing features. The CMap files are available for download separately, and must be configured according to the documentation (e.g. using the SearchPath resource category). The "prefix" parameter and UPR entry is no longer supported (it had been declared deprecated in PDFlib 5). Deprecated options: PDF_fit_textline(): weblink, locallink; use the matchbox feature instead PDF_open_pdi_page(): infomode; use pCOS to query page properties without actually placing the page PDFlib Lite incompatibility: Glyph widths for standard CJK fonts with Unicode CMaps are no longer available due to the transition to external CMaps. PDF_stringwidth() will return 0 in this case. The resolution value is no longer read from JPEG images created with Photoshop. The following deprecated (as of PDFlib 6) functions have been removed from the manual: PDF_add_bookmark() PDF_add_bookmark2() PDF_add_note() PDF_add_note2() PDF_attach_file() PDF_attach_file2() PDF_add_pdflink() PDF_add_locallink() PDF_add_launchlink() PDF_add_weblink() PDF_set_border_style() PDF_set_border_color() PDF_set_border_dash() PDF_open_mem() PDF_open_file() PDF_close() PDF_begin_page() PDF_end_page() PDF_show_boxed() PDF_boot() and PDF_shutdown(): these have never been functional, and were only available in the C language binding. The following deprecated (as of PDFlib 6) parameters have been removed from the manual: compatibility pdfx flush openwarning pagewidth, pageheight (PDF_set_value()) ArtBox/*, BleedBox/*, CropBox/*, TrimBox/* userpassword masterpassword permissions defaultgray defaultrgb defaultcmyk pdiusebox openaction openmode hidetoolbar hidemenubar hidewindowui fitwindow centerwindow displaydoctitle nonfullscreenpagemode direction viewarea, viewclip printarea, printclip bookmarkdest transition duration base launchlink:parameters launchlink:operation launchlink:defaultdir The following unsupported functions have been removed (use PDF_info_font() instead): PDF_encoding_get_glyphname() PDF_encoding_get_unicode() PDF_get_glyphid() PHP binding: Parameter "imagewarning": the default has been "true" for historical reasons; in PDFlib 7 it has been changed to "false" for compatibility with all other language bindings. PDFlib 6.0.3 ============ - Textflow: if the box doesn't contain any text at all when processing is finished (e.g. because the width of the box is too small to hold any text), the return string "_boxfull" is misleading. Textflow will now return the string "_boxempty" in such situations. - New options: PDF_begin_item(): Scope attribute for TH items. PDF_begin/end_document(): moddate PDF_begin/end_document(): search - New parameters: nodemostamp xheight xheightfaked capheightfaked ascenderfaked descenderfaked - The block interface version number has been changed to 6; Block plugin 2.2 or above is required for use with PPS 6.0.3. - Deprecated options: PDF_create_action(), PDF_create_annotation(), PDF_create_bookmark(), and PDF_begin/end_document(): "name" option, "nameddest" suboption of the "type" option. PDFlib 6.0.2 ============ - New options: PDF_fit_textflow(): orientate PDF_create_annotation(): opacity, createdate, subject PDF_info_textflow(): leftlinex/y, rightlinex/y PDF_begin/end_page_ext(): metadata - In order to work around different behavior in Acrobat 5 and 6 regarding several form field options (e.g. the readonly option for radio buttons was not honored in Acrobat 6) the following restriction is now implemented: options "readonly", "unisonselect", "toggle", and "tooltip" for type= radiobutton are only allowed for PDF_create_fieldgroup(), but no longer for PDF_create_field(). Client code which used one of these options for PDF_create_field() created bad PDF output. Such code will now raise a warning unless fieldwarning=false, and thus should be changed to honor the new restrictions. - The leading handling in PDF_create_textflow()/PDF_fit_textflow() has changed. Previously the behavior for multiple leading instructions on a line was undefined, and didn't match the user expectation in certain cases. E.g. when leading was specified at the beginning of the text _and_ in the optlist parameter of PDF_create_textflow(), the leading value from the optlist parameter was used, and not the one from the inline option list. The new leading behavior is documented in the manual. In some situations it may cause different formatting results than with earlier versions, but the previous behavior is considered a bug. PDFlib 6.0.1 ============ - No changes which affect compatibility. PDFlib 6.0.0 ============ See the PDFlib manual for information about new functions and parameters which should be used instead of the deprecated ones. Deprecated functions: - PDF_show_boxed(), PDF_show_boxed2() - PDF_add_bookmark(), PDF_add_bookmark2() - PDF_attach_file(), PDF_attach_file2() - PDF_add_note(), PDF_add_note2() - PDF_add_pdflink() - PDF_add_locallink() - PDF_add_launchlink() - PDF_add_weblink() - PDF_set_border_style() - PDF_set_border_color() - PDF_set_border_dash() Deprecated options for particular functions: - reftype in PDF_load_image() Deprecated parameters: - userpassword, masterpassword, permissions, compatibility, flush, pdfx - openaction, base, launchlink:parameters, launchlink:operation, launchlink:defaultdir, transition, duration, openmode - hidetoolbar, hidemenubar, hidewindowui, fitwindow, centerwindow, displaydoctitle, nonfullscreenpagemode, direction, viewarea, viewclip, printarea, printclip - bookmarkdest - pagewidth, pageheight, artbox, bleedbox, cropbox, trimbox - pdiusebox - defaultrgb/rgb/cmyk Removed functions: The functions PDF_setgray*() and PDF_setrgbcolor*() are no longer available except in the C language. These functions have been deprecated since PDFlib 4. Workaround: use setcolor() instead. Changes in the Java binding: All float parameters have been changed to double, which may require appropriate adjustments to the data types used in client code. Deprecated in the C++ binding: - The overloaded open() calls are no longer available. - The unsupported method get_message() in the PDFlibException object has been replaced with get_errmsg(). Changes in the PHP binding: - Stricter parameter checking: detects bad data types - Optional parameters are no longer supported (all parameters dictated by the API must be provided in the PHP script). Changes related to encodings: The "host" encoding translates to "iso8859-1" on non-Windows platforms (except EBCDIC-based mainframes) instead of "winansi". It is still recommended to explicitly specify the required encoding instead of using "host". PDFlib 5.0.2 ============ - COM: - The functions PDF_setgray*() and PDF_setrgbcolor*() are no longer available in the COM wrapper. These functions have been deprecated since PDFlib 4. Workaround: use setcolor() instead. PDFlib 5.0.1 ============ - No changes which affect compatibility. PDFlib 5.0.0 ============ Deprecated functions: - PDF_findfont() - PDF_setpolydash() - PDF_open_image_file() - PDF_open_CCITT() - PDF_open_image() - PDF_place_pdi_page() - PDF_boot_dll() and PDF_shutdown_dll() Deprecated options for particular functions: - reftype option in PDF_load_image() Deprecated parameters: - prefix Other changes: - Several resource configuration mechanism are superseded by improved mechanisms. However, the previous configuration scheme is still supported. - Introduced a dedicated PDFlibException class for Java. This may require modifications to existing catch clauses. - The new C exception handling with PDF_TRY/PDF_CATCH makes old-style error handlers obsolete. However, PDF_new2() will still accept error handler callbacks. - The PDF_open_pdi_callback() has been slightly modified; this affects only PDFlib customers who used this feature in a preliminary release. - Changed the default value of the "inheritgstate" parameter to false. - By default, PDFlib generates PDF 1.4 (Acrobat 5) output. This can be modified with PDF_set_parameter(p, "compatibility", "1.3"); - The following features have been removed: PDF_set_parameter(p, "compatibility", "1.2"); Careful programming can still produce PDF 1.2 compatible documents, albeit with a PDF 1.3 header entry. - The following functions have been removed: PDF_open_pdi_mem() (only implemented in custom versions of PDFlib+PDI) Change existing calls to the following sequence: PDF_create_pvf(...); PDF_open_pdi(...); - C++ binding: Switches to new-style C++ exceptions by default (as opposed to installing an old-style client-supplied error handler callback function). - PHP binding: Those very old API functions have been removed from the wrapper which stemmed from the prehistoric era before PDFlib GmbH officially supported the PHP wrapper. These functions have never been documented in the PDFlib manual, but have been kept in the PHP wrapper for compatibility reasons. In order to facilitate maintenance we dropped these functions. The pdf_open_memory_image() API is not affected since it actually added new functionality. Although PDFlib GmbH does not support this function it still works. The virtual_dir support has also been dropped. This feature is rather confusing since it is not supported on all platforms and configurations. In addition, it conflicts with the new SearchPatch facility in PDFlib. Finally, it didn't work when generating PDF files with PDF_open_file().