Skip to content

v3.33.0

Compare
Choose a tag to compare
@gunnsth gunnsth released this 13 Mar 19:34
· 66 commits to master since this release
110569d

Release notes - UniPDF - Version v3.33.0

UniPDF version 3.33.0 contains new features and multiple bug fixes. Notably, PDF/A-1A validation and generation has been completed and font extraction has been added.

NOTE: Ticket numbers are included for reference.

New features

  • Implement PDF/A-1A validation functions, A/B optimizer functions [UP-310, UP-309]

To try this out can use our examples for standard conversion and generation in https://github.com/unidoc/unipdf-examples/tree/master/pdfa and using the pdfa.NewProfile1A(nil) profile.

  • Add font extraction capability in extractor package [UP-73]
    Makes it easy to extract font and font data for a given range of pages or entire document.

The extractor has a new function

// ExtractFonts returns all font information from the page extractor, including// font name, font type, the raw data of the embedded font file (if embedded), font descriptor and more.  
//  
// The argument `previousPageFonts` is used when trying to build a complete font catalog for multiple pages or the entire document.  
// The entries from `previousPageFonts` are added to the returned result unless already included in the page, i.e. no duplicate entries.  
//  
// NOTE: If previousPageFonts is nil, all fonts from the page will be returned. Use it when building up a full list of fonts for a document or page range.  
func (e *Extractor) ExtractFonts(previousPageFonts *PageFonts) (*PageFonts, error) {

New Example: https://github.com/unidoc/unipdf-examples/blob/master/extract/pdf_extract_fonts.go

  • Add a flag to prevent a table from being split on a page break [UP-306 ]

Adds to creator's Table type:

// EnablePageWrap controls whether the table is wrapped across pages.
// If disabled, the table is moved in its entirety on a new page, if it
// does not fit in the available height. By default, page wrapping is enabled.
// If the height of the table is larger than an entire page, wrapping is
// enabled automatically in order to avoid unwanted behavior.
func (table *Table) EnablePageWrap(enable bool) {

Improvements and fixes

  • Outline destinations appear to be null for some types of PDFs [UP-323 ]
    Fixes problem reported in #482

  • Text extraction disorder occurs on this type of pdf [UP-322]
    Bug fix for certain case with particular CMap bfrange values.

  • Text extraction problem with mixed garbles/non-garbled text [UP-308 ]
    Bug fix for font cache name where multiple fonts could have same key, causing incorrect text mappings.

  • Problem with extracting images from CCITTDecode filter for a user provided file
    Bug fix for particular issue in CCITT encoding related to EOL handling. [UP-268]