2022-09-10  Jay Berkenbilt  <ejb@ql.org>

        * 11.0.0: release

2022-09-09  Jay Berkenbilt  <ejb@ql.org>

        * Add QPDFObjectHandle::isSameObjectAs to test whether two
        QPDFObjectHandle objects point to the same underlying object.

        * Expose ability to create custom loggers and to get and set the
        logger for QPDF and QPDFJob through the C API.

2022-09-08  Jay Berkenbilt  <ejb@ql.org>

        * Added new functions to the C API to support qpdf JSON:
        qpdf_create_from_json_file, qpdf_create_from_json_data,
        qpdf_update_from_json_file, qpdf_update_from_json_data, and
        qpdf_write_json. Examples can be found in qpdf-ctest.c (in the
        source tree), tests 42 through 47.

        * Add QPDFObjectHandle::isDestroyed() to test whether an indirect
        object was from a QPDF that has been destroyed.

2022-09-07  Jay Berkenbilt  <ejb@ql.org>

        * Add QPDFObjectHandle::getQPDF(), which returns a reference, as
        an alternative to QPDFObjectHandle::getOwningQPDF().

2022-09-06  Jay Berkenbilt  <ejb@ql.org>

        * For all bounding box methods in QPDFPageObjectHelper other than
        MediaBox, add a parameter `copy_if_fallback`, and add comments
        explaining in depth exactly what copy_if_shared and
        copy_if_fallback mean. Fixes #664.

        * Add new methods getArtBox and getBleedBox to
        QPDFPageObjectHelper, completing the set of bounding box methods.

        * The --show-encryption option now works even if a correct
        password is not supplied. If you were using --show-encryption to
        test whether you have the right password, use --requires-password
        instead. Fixes #598.

2022-09-05  Jay Berkenbilt  <ejb@ql.org>

        * Add a move constructor to Buffer, making it possible to move
        rather than copy the internal buffer. Thanks to jbarlow83 for the
        contribution.

2022-09-02  Jay Berkenbilt  <ejb@ql.org>

        * Add new QPDF::create() factory method that returns
        std::shared_ptr<QPDF>.

        * Prevent copying/assigning to QPDF objects in the API. It has
        never been safe to do this, but the API wasn't preventing it.

2022-09-01  Jay Berkenbilt  <ejb@ql.org>

        * Remove QPDFObject.hh from include/qpdf. The only reason to
        include was to get QPDFObject::object_type_e. Instead, include
        qpdf/Constants.h, and change `QPDFObject::ot_` to `::ot_`.

        * More optimizations and cleanup from m-holger (#726, #730)
        including major refactor of QPDF's internal representations of
        objects. In addition to a large performance improvement, this also
        made it possible for QPDFObjectHandle::getOwningQPDF() to return a
        null pointer if the owning QPDF had been destroyed. (A more
        complete solution to this problem will be introduced for qpdf 12.)
        This work also paves the way for a future alternative to
        QPDFObjectHandle that is more idiomatic C++ and has greater type
        safety.

2022-08-31  Jay Berkenbilt  <ejb@ql.org>

        * From m-holger (#729): refactor QPDF's parser into a new
        QPDFParser class, cleaning the code, significantly improving
        performance.

2022-08-27  Jay Berkenbilt  <ejb@ql.org>

        * From m-holger: major refactoring of QPDFTokenizer to improve
        readability and to optimize performance. This also included some
        optimizations to some InputSource classes. Thanks for this
        excellent contribution. Fixes #749, #442.

2022-08-07  Jay Berkenbilt  <ejb@ql.org>

        * Add new build configuration option ENABLE_QTC, which is off by
        default when not running in MAINTAINER_MODE. When this is off,
        QTC coverage calls sprinkled throughout the qpdf source code are
        compiled out for increased performance. See "Build Options" in the
        manual for a discussion. Fixes #714.

2022-08-06  Jay Berkenbilt  <ejb@ql.org>

        * Added by m-holger: QPDF::getObject() method as a simpler form of
        getObjectByID or getObjectByObjGen. The older methods are being
        retained for compatibility and are not deprecated.

2022-07-24  Jay Berkenbilt  <ejb@ql.org>

        * include/qpdf/JSON.hh: Schema validation: allow a single item to
        appear anywhere that the schema has an array of a single item.
        This makes it possible to change an element of the schema from an
        item to an array to allow the data to accept an array where a
        single value was previously required. This change is needed to
        allow QPDFJob JSON to start accepting multiple items where a
        single item used to be expected without breaking backward
        compatibility. Without this change, the earlier fix to
        removeAttachment would be a breaking change. Also allow the schema
        to contain a multi-element array, which means that the output has
        to have an array of the same length in the corresponding location,
        and each element is validated against the corresponding schema
        element.

        * QPDFObjectHandle: for the methods insertItem, appendItem,
        eraseItem, replaceKey, and removeKey, add a corresponding
        "AndGetNew" and/or "AndGetOld" methods. The ones that end with
        "AndGetNew" return the newly added item. The ones that end with
        "AndGetOld" return the old value. The AndGetNew methods make it
        possible to create a new object, add it to an array or dictionary,
        and get a handle to it all in one line. The AndGetOld methods make
        it easier to retrieve an old value when removing or replacing it.

        * Thanks to m-holger for doing significant cleanup of private APIs
        and internals around QPDFObjGen and for significantly improving
        the performance of QPDFObjGen -- See #731. This includes a few
        user-visible changes:
        - Addition of QPDFObjectHandle::StreamDataProvider::provideStreamData
          overloads that take QPDFObjGen
        - Addition of an optional argument to QPDFObjGen::unparse allowing
          specification of a separator character, with the default
          resulting in the old behavior
        Examples have been updated to use improved APIs. The old
        provideStreamData overloads will continue to be supported, so
        updating older code to use the new interfaces is entirely at the
        programmer's discretion.

2022-06-25  Jay Berkenbilt  <ejb@ql.org>

        * Add tracking methods QPDF::everCalledGetAllPages() and
        QPDF::everPushedInheritedAttributesToPages(). Since those methods
        may have the side effect of creating new objects and replace
        objects in various places in the pages tree, it's useful to be
        able to find out whether they've ever been called.

2022-06-18  Jay Berkenbilt  <ejb@ql.org>

        * Add QPDFJob::registerProgressReporter, making it possible to
        override the progress reporter that is used when --progress (or
        the equivalent) is configured with QPDFJob. This is
        qpdfjob_register_progress_reporter in the C API.

        * Add examples that show how to capture QPDFJob's output by
        configuring the default logger (qpdfjob-save-attachment.cc,
        qpdfjob-c-save-attachment.c). Fixes #691.

        * Add C API for QPDFLogger -- see qpdflogger-c.h

        * Add additional qpdfjob C API functions take a handle.

        * Add qpdf_exit_code_e to Constants.h so that exit codes from
        QPDFJob are accessible to the C API.

        * When --progress or --verbose is combined with writing to
        standard output, progress reporting and verbose messages go to
        standard error. Previously it was disabled in this case.

2022-06-05  Jay Berkenbilt  <ejb@ql.org>

        * QPDFJob: API breaking change: QPDFJob::doIfVerbose passes a
        Pipeline& rather than a std::ostream& to the the callback
        function.

        * Add integer types to pipeline's operator<<: short, int, long,
        long long, unsigned short, unsigned int, unsigned long, unsigned
        long long.

2022-05-30  Jay Berkenbilt  <ejb@ql.org>

        * qpdf JSON is now at version 2. New command-line arguments:
        --json-output, --json-input, --update-from-json. New methods
        QPDF::writeJSON, QPDF::createFromJSON, QPDF::updateFromJSON. For
        details, see the "qpdf JSON" chapter of the manual.

        * When showing encryption data in json output, when the user
        password was recovered with by the owner password and the
        specified password does not match the user password, reveal the
        user password. This is not possible with 256-bit keys.

        * Include additional information in --list-attachments --verbose
        and in --json --json-key=attachments.

        * Add QUtil::qpdf_time_to_iso8601 and QUtil::pdf_time_to_iso8601
        for converting PDF/qpdf timestamps to ISO-8601 date format.

2022-05-18  Jay Berkenbilt  <ejb@ql.org>

        * Add QUtil::FileCloser to the public API. This is a simple inline
        class to help with automatic file closing.

2022-05-17  Jay Berkenbilt  <ejb@ql.org>

        * Allow passing *uninitialized* (not null) objects to
        replaceStreamData as filter and/or decode_parms to leave any
        existing values for /Filter and /DecodeParms untouched.

2022-05-15  Jay Berkenbilt  <ejb@ql.org>

        * Add QUtil::is_long_long to test whether a string can be
        converted to a long long and back without loss of information.

2022-05-04  Jay Berkenbilt  <ejb@ql.org>

        * JSON: add a new "blob" type that takes a function to write data
        into. The blob is serialized as a base64-encoded representation of
        whatever is written to the function.

        * FileInputSource has new constructors that eliminate the need to
        call setFilename or setFile in most cases.

        * Enhance JSON by adding a write method that takes a Pipeline* and
        depth, and add several helper methods to make it easier to write
        large amounts of JSON incrementally without having to have the
        whole thing in memory.

        * json v1 output: make "pages" and "objects" consistent.
        Previously, "objects" always reflected the objects exactly as they
        appeared in the original file, while "pages" reflected objects
        after repair of the pages tree. This could be misleading. Now, if
        "pages" is specified, "objects" shows the effects of repairing the
        page tree, and if not, it doesn't. This makes no difference for
        correct PDF files that don't have problems in the pages tree. JSON
        v2 will behave in a similar way.

2022-05-03  Jay Berkenbilt  <ejb@ql.org>

        * Add new Pipeline class Pl_String which appends to a std::string&
        passed to it at construction.

        * Add new Pipeline class Pl_OStream, similar to Pl_StdioFile but
        takes a std::ostream instead of a FILE*.

        * Add new convenience methods to Pipeline: writeCStr and
        writeString. Also add a limit << operator that takes C strings and
        std::strings. Also add an overloaded version of write that takes
        "char const*".

        * API change: Pipeline::write now takes "unsigned char const *"
        instead of "unsigned char*". Callers shouldn't have to change
        anything, though can stop using writable strings or
        QUtil::unsigned_char_pointer. If you have implemented your own
        pipelines, you should change your write method to take a const
        pointer.

2022-05-01  Jay Berkenbilt  <ejb@ql.org>

        * JSON: add reactors to the JSON parser, making it possible to
        react to JSON parsing events as they occur and to block the
        results from being stored. This makes it possible to incrementally
        parse arbitrarily large JSON inputs.

2022-04-30  Jay Berkenbilt  <ejb@ql.org>

        * QPDFWriter: change encryption API calls
          - Remove deprecated versions of setR*EncryptionParameters
            methods from before qpdf 8.4.0
          - Replace setR2EncryptionParameters with
            setR2EncryptionParametersInsecure
          - Replace setR3EncryptionParameters with
            setR3EncryptionParametersInsecure
          - Replace setR4EncryptionParameters with
            setR4EncryptionParametersInsecure

        * C API: change encryption API calls to match C++ interface
          - Remove pre-8.4.0 functions:
            - qpdf_set_r3_encryption_parameters
            - qpdf_set_r4_encryption_parameters
            - qpdf_set_r5_encryption_parameters
            - qpdf_set_r6_encryption_parameters
          - Add "_insecure" to insecure encryption triggers:
            - Replace void qpdf_set_r2_encryption_parameters
              with qpdf_set_r2_encryption_parameters_insecure
            - Replace void qpdf_set_r3_encryption_parameters2
              with qpdf_set_r3_encryption_parameters_insecure
            - Replace void qpdf_set_r4_encryption_parameters2
              with qpdf_set_r4_encryption_parameters_insecure

        * Make attempting to write encrypted files that use RC4 (40-bit or
        128-bit without AES) an error rather than a warning when
        --allow-weak-crypto is not specified. Fixes #576.

2022-04-24  Jay Berkenbilt  <ejb@ql.org>

        * Bug fix: "removeAttachment" in the job JSON now takes an array
        of strings instead of a string. It should have taken an array of
        strings since the corresponding command-line argument,
        --remove-attachment, is repeatable. Fixes #693.

        * Deprecate QPDFObjectHandle::replaceOrRemoveKey -- it does and
        always has done the same thing as replaceKey.

2022-04-23  Jay Berkenbilt  <ejb@ql.org>

        * Add a new QPDF::warn method that takes the parameters of
        QPDFExc's constructor except for the filename, which is taken from
        the QPDF object. This is a shorter way to issue warnings on behalf
        of a QPDF object.

	* Add new method QUtil::is_explicit_utf8 that tests whether a
	string is explicitly marked as being UTF-8 encoded, as allowed by
	the PDF 2.0 spec. Such a string starts with the bytes 0xEF 0xBB
	0xBF, which is the UTF-8 encoding of U+FEFF.

	* Add new method QUtil::get_next_utf8_codepoint as a low-level
	helper for iterating through the UTF-8 characters in a byte
	string.

2022-04-16  Jay Berkenbilt  <ejb@ql.org>

	* Breaking CLI change: the default value for --json is now
	"latest" rather than "1". At this moment, "1" is the latest
	version, but version "2" will be added before the release of
	qpdf 11.

	* Perform code cleanup including some source-compatible but not
	binary compatible changes to function signatures, use of anonymous
	namespaces, and use of "= default" and "= delete" in declarations.

2022-04-09  Jay Berkenbilt  <ejb@ql.org>

	* Replace PointerHolder with std::shared_ptr through the QPDF API.
	A backward-compatible interface is provided and enabled by default
	with a warning that can be turned off. See "Smart Pointers" in the
	"Design and Library Notes" section of the manual for information
	including a detailed migration process to assist with migrating
	code that uses the qpdf library.

2022-04-03  Jay Berkenbilt  <ejb@ql.org>

	* Add automatic code formatting with clang-format. See "Code
	Formatting" in the "Contributing to qpdf" chapter of the manual.

2022-03-19  Jay Berkenbilt  <ejb@ql.org>

	* 10.6.3.0cmake1: unofficial release

	* Conversion of build system to cmake. This change doesn't include
	any user-visible functional changes to the library API or CLI but
	completely replaces the build system. Details can be found in the
	manual in the "Building and Installing QPDF" and "Notes for
	Packagers" sections, especially "Converting From autoconf to
	cmake" in "Building and Installing QPDF". Highlights of the
	changes can be found in the release notes.

2022-03-08  Jay Berkenbilt  <ejb@ql.org>

	* 10.6.3: release

	* Use Windows 2022 github runners and therefore Visual Studio 2022
	to create Windows distributions

	* Fix DLL export issue with mingw (Windows)

2022-03-07  Jay Berkenbilt  <ejb@ql.org>

	* Minor internal changes to assist with building in other
	environments: rename internal bits.icc to qpdf/bits_functions.hh
	(not part of public API), enforce reordering of header files to
	prevent jpeglib.h from interfering with other headers, remove an
	unused header that was accidentally added in 10.6.0 but never
	referenced by any code.

	* Make build work and tests work when NDEBUG is defined. This
	involved a few changes to some test files but no changes to any
	library code.

2022-02-25  Jay Berkenbilt  <ejb@ql.org>

	* Bug fix in JSON parser: accept \/ in a string as valid input per
	JSON spec even though we don't translate / to \/ on output.

2022-02-22  Jay Berkenbilt  <ejb@ql.org>

	* Recognize PDF strings explicitly marked as UTF-8 as allowed by
	the PDF 2.0 spec. Fixes #654.

2022-02-18  Jay Berkenbilt  <ejb@ql.org>

	* Bug fix: when generating appearance streams, the font size was
	substituted incorrectly from /DA if Tf was absent or the number
	preceding Tf was out of range. Fixes #655.

2022-02-16  Jay Berkenbilt  <ejb@ql.org>

	* 10.6.2: release

2022-02-15  Jay Berkenbilt  <ejb@ql.org>

	* Fix asymmetrical logic between
	QPDFObjectHandle::newUnicodeString() and
	QPDFObjectHandle::getUTF8Val(). The asymmetrical logic didn't
	matter before fixing the PDF Doc transcoding bugs.

	* When analyzing PDF strings, recognize UTF-16LE as UTF-16. The
	PDF spec only allows UTF-16BE, but most readers seem to allow
	both. Fixes #649.

	* Bug fix: 10.6.0 inadvertently removed an unknown/undocumented
	CLI parsing feature, which has been restored in 10.6.2. Fixes #652.

	* Don't map 0x18 through 0x1f, 0x7f, 0x9f, or 0xad as fixed points
	when transcoding UTF-8 to PDFDoc. These code points have different
	meanings in those two encoding systems. Fixes #650.

2022-02-11  Jay Berkenbilt  <ejb@ql.org>

	* 10.6.1: release

	* Fix some compilation issues from use of abs without including
	proper headers.

2022-02-09  Jay Berkenbilt  <ejb@ql.org>

	* 10.6.0: release

	* Fix one more PDF doc encoding omission: 0xAD is also undefined.
	Fixes #637.

2022-02-08  Jay Berkenbilt  <ejb@ql.org>

	* Bug fix: when splitting pages with --split-pages or selecting
	pages with --pages, set the output PDF version to the maximum of
	all the input PDF versions. This is a fix to QPDFJob. If you are
	creating output PDF files yourself from multiple inputs, you will
	need to code the same thing. The new PDFVersion object, its
	updateIfGreater() method, and the new QPDF and QPDFWriter methods
	described below make this very easy to do. Fixes #610.

	* Add new class PDFVersion for more convenient comparison of PDF
	version numbers from the %!PDF header.

	* Add QPDF::getVersionAsPDFVersion() to return the PDF version and
	extension together as a PDFVersion object instead of a string.

	* Add a QPDFWriter::setMinimumPDFVersion() that takes a PDFVersion
	object.

2022-02-06  Jay Berkenbilt  <ejb@ql.org>

	* Pl_Buffer and QPDFWriter: add getBufferSharedPointer(), which
	turns a PointerHolder<Buffer> but will return a
	std::shared_ptr<Buffer> in qpdf 11.

	* From m-holger: add getKeyIfDict(), which calls getKey for
	dictionaries and returns null if called on null. This is for
	easier access to optional, lower-level dictionaries.

2022-02-05  Jay Berkenbilt  <ejb@ql.org>

	* Add several new accessors to QPDFObjectHandle: the bool
	getValueAsX(X&) accessors allow an alternative way to retrieve
	values from QPDFObjectHandle objects and can result in more
	concise code in many situations. Thanks to m-holger for the
	contribution.

	* Add qpdf_oh_new_binary_unicode_string and
	qpdf_oh_get_binary_utf8_value to the C API. This makes it possible
	to handle UTF-8-encoded strings with embedded NUL characters. Thanks
	to m-holger for the contribution.

	* Add a global user-defined string literal "_qpdf" as a shorthand
	for QPDFObjectHandle::parse, allowing you to create
	QPDFObjectHandle objects with

	QPDFObjectHandle oh = "<</Some (PDF)>>"_qpdf;

	* Expose QPDF::emptyPDF to the C API as qpdf_empty_pdf()

	* Add comments letting people know that the version string
	returned by QPDF::QPDFVersion and qpdf_get_qpdf_version is static.

	* Add QUtil::make_unique_cstr to return a std::unique_ptr<char[]>
	as an alternative to QUtil::copy_string and
	QUtil::make_shared_cstr.

2022-02-04  Jay Berkenbilt  <ejb@ql.org>

	* New preprocessor symbols QPDF_MAJOR_VERSION, QPDF_MINOR_VERSION,
	QPDF_PATCH_VERSION as numbers and QPDF_VERSION as a string. These
	can be used for feature testing in code. These are in qpdf/DLL.h,
	which is included by every header that adds to the public API.
	Since these constants are introduced in version 10.6, it's
	important for them to be in a header that everyone already
	includes so you don't have to try to include a header that won't
	be there.

	* PointerHolder: add a get() method and a use_count() method for
	compatibility with std::shared_ptr. In qpdf 11, qpdf's APIs will
	switch to using std::shared_ptr instead of PointerHolder, though
	there will be a PointerHolder class with a backward-compatible
	API. To ease the transition, we are adding get() now with the same
	semantics as std::shared_ptr's get. Note that there is a
	difference in behavior: const PointerHolder has always behaved
	incorrectly. const PointerHolder objects only returned const
	pointers. This is wrong. If you want a const pointer, use
	PointerHolder<T const>. A const PointerHolder just shouldn't allow
	its pointer to be reassigned. The new get() method behaves
	correctly in that calling get() on a const PointerHolder to a
	non-const pointer returns a non-const pointer. This is the way
	regular pointers behave.

2022-02-01  Jay Berkenbilt  <ejb@ql.org>

	* Major refactor: all functionality from the qpdf CLI is now
	available for library users using the QPDFJob class. See comments
	in include/qpdf/QPDFJob.hh and a new chapter about QPDFJob in the
	manual. QPDFJob provides fluent interfaces for setting options
	that exactly map to command-line arguments. There are also methods
	for initializing QPDFJob from an argv array and from a JSON
	object.

	* A light C API around basic QPDFJob functionality is in
	include/qpdf/qpdfjob-c.h.p

	* Add new functions version of QUtil::call_main_from_wmain that
	takes a constant argv array.

2022-01-31  Jay Berkenbilt  <ejb@ql.org>

	* Have --json-help just output the JSON object, leaving a
	description to --help and the manual.

	* The --json flag now takes a version number as an optional
	parameter. The default will remain version 1 for compatibility
	until the release of qpdf 11, after which it will become "latest".
	At this time, there's only version 1, but a version 2 may appear
	in a future qpdf.

2022-01-28  Jay Berkenbilt  <ejb@ql.org>

	* Add QPDFUsage exception, which is thrown by QPDFJob to indicate
	command-line usage or job configuration errors.

2022-01-22  Jay Berkenbilt  <ejb@ql.org>

	* Add QUtil::make_shared_cstr to return a std::shared_ptr<char>
	instead of a char* like QUtil::copy_string

	* JSON: for (qpdf-specific, not official) "schema" checking, add
	the ability to treat missing fields as optional. Also ensure that
	values in the schema are dictionary, array, or string.

	* Add convenience methods isNameAndEquals and isDictionaryOfType
	to QPDFObjectHandle with corresponding functions added to the C
	API. Thanks to m-holger for the contribution.

2022-01-17  Jay Berkenbilt  <ejb@ql.org>

	* Add JSON::parse. Now qpdf's JSON class implements a
	general-purpose JSON parser and serializer, but there are better
	options for general use. This is really designed for qpdf's
	internal use and is set up to be compatible with qpdf's existing
	API and to hook into a planned JSON-based API to the QPDFJob
	class.

	* Add isDictionary and isArray to JSON

2022-01-11  Jay Berkenbilt  <ejb@ql.org>

	* Major overhaul of documentation and help for the qpdf
	command-line tool. qpdf --help is now broken into topics rather
	than being one great wall of text, and the command-line arguments
	are indexed in the manual. The entire text of the "Running qpdf"
	chapter has been reviewed thoroughly. Many thanks once again to
	M. Holger for a detailed review and editorial assistance with the
	manual.

	* Bug fix: add missing characters from PDF doc encoding.
	Fixes #606.

2021-12-29  Jay Berkenbilt  <ejb@ql.org>

	* Add method QUtil::file_can_be_opened

2021-12-21  Jay Berkenbilt  <ejb@ql.org>

	* 10.5.0: release

	* Add documentation link to top-level README

	* Discontinue inclusion of the pre-built documentation in the
	source distribution. Consult the packaging documentation in the
	manual for details. The file README-doc.txt is installed in the
	doc directory by default and contains information that users will
	need to know to find the documentation.

2021-12-19  Jay Berkenbilt  <ejb@ql.org>

	* C API: clarify documentation around string lengths. Add two new
	methods: qpdf_oh_get_binary_string_value and
	qpdf_oh_new_binary_string to make the need to handle the length
	and data separate in more explicit in cases in which the string
	data may contain embedded null characters.

2021-12-17  Jay Berkenbilt  <ejb@ql.org>

	* C API: simplify error handling for uncaught errors (never in a
	released version) and clarify documentation in qpdf-c.h around
	error handling. See qpdf-c.h for details, including how to check
	for errors and the new function qpdf_silence_errors.

	* C API: expose getTypeCode and getTypeName from QPDFObjectHandle.
	Fixes #597.

	* C API: add functions for working with stream data. Search for
	"STREAM FUNCTIONS" in qpdf-c.h. Fixes #596.

	* QPDFObjectHandle object types have been moved from
	QPDFObject::object_type_e to qpdf_object_type_e (defined in
	Constants.h). Old values are available for backward compatibility.

	* Add Pl_Buffer::getMallocBuffer() to initialize a buffer with
	malloc in support of the C API

2021-12-16  Jay Berkenbilt  <ejb@ql.org>

	* Add several functions to the C API for working with pages. C
	wrappers around several of the "Legacy" page operations from
	QPDFObjectHandle.hh have been added. See "PAGE FUNCTIONS" in
	qpdf-c.h for details. Fixes #594.

2021-12-12  Jay Berkenbilt  <ejb@ql.org>

	* Convert documentation from docbook to reStructuredText/Sphinx.

2021-12-10  Jay Berkenbilt  <ejb@ql.org>

	* Handle bitstream overflow errors more gracefully. Fixes #581.

	* C API: add qpdf_get_object_by_id, qpdf_make_indirect_object, and
	qpdf_replace_object, exposing the corresponding methods in QPDF
	and QPDFObjectHandle. Fixes #588.

	* Add missing QPDF_DLL to QPDFObjectHandle::addTokenFilter so that
	it is actually accessible as part of the public interface as
	intended. Fixes #580.

	* C API: Overhaul how errors are handle the C API's object handle
	interfaces. Clarify documentation regarding object accessors and
	how type errors and warnings are handled. Many cases that used to
	crash code that used the C API can now be trapped and will be
	written stderr if not trapped. See qpdf-c.h for details.

	* C API: Add qpdf_oh_new_uninitialized to explicitly create
	uninitialized object handles.

	* Add new error code qpdf_e_object that is used for exceptions
	(including warnings) that are caused by using QPDFObjectHandle
	methods on object handles of the wrong type.

2021-12-02  Jay Berkenbilt  <ejb@ql.org>

	* C API: Add qpdf_oh_is_initialized.

	* C API: Add qpdf_get_last_string_length to return the length of
	the last string returned. This is necessary in order to fully
	retrieve values of strings that may contain embedded null characters.

	* C API: Add qpdf_oh_new_object to clone an object handle. Change
	implemented by m-holger in #587.

2021-11-16  Jay Berkenbilt  <ejb@ql.org>

	* 10.4.0: release

2021-11-10  Jay Berkenbilt  <ejb@ql.org>

	* Add --allow-weak-crypto option to suppress warnings about use of
	weak cryptographic algorithms. Update documentation around this
	issue. Fixes #358.

2021-11-07  Jay Berkenbilt  <ejb@ql.org>

	* Relax xref recovery logic a bit so that files whose objects are
	either missing endobj or have endobj at other than the beginning
	of a line can still be recovered. Fixes #573.

2021-11-04  Jay Berkenbilt  <ejb@ql.org>

	* Add support for OpenSSL 3. Fixes #568.

	The OpenSSL version is detected at compile-time. If you want to
	build with OpenSSL 3 on a system that has OpenSSL 1 installed, you
	can run configure like this (or similar to this depending on how
	you installed openssl3):

	pc_openssl_CFLAGS=-I/path/to/openssl3/include \
	pc_openssl_LIBS='-L/path/to/openssl3/lib64 -lssl -lcrypto' \
	./configure

	where /path/to/openssl3 is wherever your OpenSSL 3 distribution is
	installed. You may also need to set the LD_LIBRARY_PATH
	environment variable if it's not installed in a standard location.

	* Add range check in QPDFNumberTreeObjectHelper (fuzz issue 37740).

	* Add QIntC::range_check_subtract to do range checking on
	subtraction, which has different boundary conditions from
	addition.

	* Bug fix: fix crash that could occur under certain conditions
	when using --pages with files that had form fields. Fixes #548.

	* Add an extra check to the library to detect when foreign objects
	are inserted directly (instead of using
	<function>QPDF::copyForeignObject</function>) at the time of
	insertion rather than when the file is written. Catching the error
	sooner makes it much easier to locate the incorrect code.

2021-11-03  Jay Berkenbilt  <ejb@ql.org>

	* Bug fix: make overlay/underlay work on a page with no resource
	dictionary. Fixes #527.

2021-11-02  Jay Berkenbilt  <ejb@ql.org>

	* Add QPDF::findPage to the public API. This is primarily to help
	improve the efficiency of code that wraps the qpdf library, such
	as pikepdf. Fixes #516.

	* zlib-flate: warn and exit with code 3 when there is corrupted
	input data even when decompression is possible. We do this in the
	zlib-flate CLI so that it can be more reliably used to test the
	validity of zlib streams, but we don't warn by default in qpdf
	itself because PDF files in the wild exist with this problem and
	other readers appear to tolerate it. There is a PDF in the qpdf
	test suite (form-filled-by-acrobat.pdf) that was written by a
	version of Adobe Acrobat that exhibits this problem. Fixes #562.

	* Add Pl_Flate::setWarnCallback to make it possible to be notified
	of data errors that are recoverable but still indicate invalid
	data.

	* Improve error reporting when someone forgets the -- after
	--pages. Fixes #555.

2021-05-12  Jay Berkenbilt  <ejb@ql.org>

	* Bug fix: ensure we don't overflow any string bounds while
	handling completion, even when we are given bogus input values.
	Fixes #441.

2021-05-09  Jay Berkenbilt  <ejb@ql.org>

	* Improve performance of preservation of object streams by
	avoiding unnecessary traversal of objects when there are no object
	streams.

2021-05-08  Jay Berkenbilt  <ejb@ql.org>

	* 10.3.2: release

	* Fix problem that caused the generated manual from being included
	in the Windows distributions. Fixes #521.

	* Fix 11-year-old bug of leaving unreferenced objects in preserved
	object streams. Fixes #520.

2021-04-17  Jay Berkenbilt  <ejb@ql.org>

	* Portability fix: use tm_gmtoff rather than global timezone
	variable if available to get timezone offset. This fixes
	compilation on BSD and also results in a daylight saving
	time-aware offset for Linux or other GNU systems. Fixes #515.

2021-04-05  Jay Berkenbilt  <ejb@ql.org>

	* When adding a page, if the page already exists, make a shallow
	copy of the page instead of throwing an exception. This makes the
	behavior of adding a page from the library consistent with what
	the CLI does and also with what the library does if it starts with
	a file that already has a duplicated page. Note that this means
	that, in some cases, the page you pass to addPage or addPageAt
	(either in QPDF or QPDFPageDocumentHelper) will not be the same
	object that actually gets added. (This has actually always been
	the case.) That means that, if you are going to do subsequent
	modification on the page, you should retrieve it again.

2021-03-11  Jay Berkenbilt  <ejb@ql.org>

	* 10.3.1: release

	* Bug fix: allow /DR to be direct in /AcroForm

2021-03-04  Jay Berkenbilt  <ejb@ql.org>

	* 10.3.0: release

	* The last several changes are in support of fixing more complex
	cases of keeping form fields working properly through page copying
	operations. Fixes #509.

	* Deprecated QPDFAcroFormDocumentHelper::copyFieldsFromForeignPage
	-- use QPDFAcroFormDocumentHelper::fixCopiedAnnotations instead.
	The API for dealing with annotations and form fields around
	copying pages is extremely complex and very hard to get right. It
	is planned for a future version of qpdf to have a higher level
	interface for dealing with copying pages around and preserving
	document-level constructs.

	* Add QPDFAcroFormDocumentHelper::getFieldsWithQualifiedName for
	returning a list of fields by name.

	* Add QPDFAcroFormDocumentHelper::addAndRenameFormFields to add a
	collection of fields while ensuring that, within the collection,
	fields with the same name continue to have the same name, but that
	they don't conflict with exiting fields in the document.

	* Add QPDFAcroFormDocumentHelper::setFormFieldName for changing
	the name of a form field in a manner that preserves
	QPDFAcroFormDocumentHelper's cache.

2021-03-03  Jay Berkenbilt  <ejb@ql.org>

	* Handle /DR properly when copying form fields. This is a
	significant rework of the form field copying from 10.2.0. It
	ensures that when copy fields from different files, we resolve any
	conflicting names in resources.

	* Add QPDFMatrix::operator==

	* Add QPDFObjectHandle::makeResourcesIndirect

2021-03-02  Jay Berkenbilt  <ejb@ql.org>

	* Add an optional resource_names argument to getUniqueResourceName
	for added efficiency.

	* Add conflict detection QPDFObjectHandle::mergeResources.

2021-03-01  Jay Berkenbilt  <ejb@ql.org>

	* Improve code that finds unreferenced resources to ignore names
	in the content stream that are not fonts or XObjects. This should
	reduce the number of cases when qpdf needlessly decides not to
	remove unreferenced resources. Hopefully it doesn't create any new
	bugs where it removes unreferenced resources that it isn't
	supposed to.

	* Add QPDF::numWarnings() -- useful to tell whether any warnings
	were issued by a specific bit of code.

2021-02-26  Jay Berkenbilt  <ejb@ql.org>

	* Bug fix: QPDFFormFieldObjectHelper was mis-handling /DA, /Q, and
	/DR in ways that usually didn't matter but were still wrong. /DA
	and /Q were being found in the field hierarchy, but if not found,
	the default values in the /AcroForm dictionary were not being
	used. /DR was being treated as an inherited field in the field
	dictionary, which is wrong. It is actually supposed to come from
	the /AcroForm dictionary. We were getting away with this since
	many popular form writers seem to copy it to the field as well,
	even though the spec makes no mention of doing this. To support
	this, QPDFFormFieldObjectHelper::getDefaultResources was added.

2021-02-25  Jay Berkenbilt  <ejb@ql.org>

	* Update StreamDataProvider examples to use copyStream() when they
	want to get to the original stream data from the provider. Prior
	to 10.2.0, we had to copy the stream to another QPDF, but now we
	can just use copyStream().

	* Bug fix/behavior change: when QPDF::replaceObject or
	QPDF::swapObjects is called, existing QPDFObjectHandle instances
	will now notice the change. This removes a long-standing source of
	bugs and confusing behavior.

2021-02-23  Jay Berkenbilt  <ejb@ql.org>

	* 10.2.0: release

	* The test for the input and output files being the same wasn't
	implemented correctly for --split-pages since the specified output
	file is really a pattern, not the actual output file.

2021-02-22  Jay Berkenbilt  <ejb@ql.org>

	* From qpdf CLI, --pages and --split-pages will properly preserve
	interactive form functionality. Fixes #340.

	* Add QPDFAcroFormDocumentHelper::copyFieldsFromForeignPage to
	copy form fields from a foreign page into the current file. (This
	method didn't work and was deprecated in 10.3.0.)

	* Add QPDFFormFieldObjectHelper::getTopLevelField to get the
	top-level field for a given form field.

	* Update pdf-overlay-page example to include copying of
	annotations.

	* Add a new version of QPDFPageObjectHelper::placeFormXObject that
	initializes the transformation matrix that was used so you don't
	have to call both placeFormXObject and
	getMatrixForFormXObjectPlacement.

2021-02-21  Jay Berkenbilt  <ejb@ql.org>

	* From qpdf CLI, --overlay and --underlay will copy annotations
	and form fields from overlay/underlay file. Fixes #395.

	* Add QPDFPageObjectHelper::copyAnnotations, which copies
	annotations and, if applicable, associated form fields, from one
	page to another, possibly transforming the rectangles.

	* Bug fix: --flatten-rotation now applies the required
	transformation to annotations on the page.

	* Add QPDFAcroFormDocumentHelper::transformAnnotations to apply a
	transformation to a group of annotations.

	* Add QPDFObjGen::unparse()

	* Add QPDFObjectHandle::copyStream() for making a copy of a stream
	within the same QPDF instance.

	* Allow QPDFObjectHandle::newArray and
	QPDFObjectHandle::newFromMatrix take QPDFMatrix as well as
	QPDFObjectHandle::Matrix

	* Make member variables a--f of QPDFMatrix public

2021-02-20  Jay Berkenbilt  <ejb@ql.org>

	* Allow --rotate=0 to clear rotation from a page.

2021-02-18  Jay Berkenbilt  <ejb@ql.org>

	* Add QPDFAcroFormDocumentHelper::addFormField, which adds a new
	form field, initializing the AcroForm dictionary if needed.

	* Add QPDFPageObjectHelper::getMatrixForFormXObjectPlacement,
	which returns the transformation matrix required to map from a
	form field's coordinate system into a specific rectangle within
	the page.

	* Add QUtil::path_basename to get last element of a path.

	* Add examples/pdf-attach-file.cc to illustrate new file
	attachment method and also new parse that takes indirect objects.

2021-02-17  Jay Berkenbilt  <ejb@ql.org>

	* Allow optional numeric argument to --collate. If --collate=n is
	given, pull n pages from the first file, n pages from the second
	file, etc., until we run out of pages.

2021-02-15  Jay Berkenbilt  <ejb@ql.org>

	* Add a version of QPDFObjectHandle::parse that takes a QPDF* as
	context so that it can parse strings containing indirect object
	references.

2021-02-14  Jay Berkenbilt  <ejb@ql.org>

	* Add new versions of QPDFObjectHandle::replaceStreamData that
	take std::function objects for cases when you need something
	between a static string and a full-fledged StreamDataProvider.
	Using this with QUtil::file_provider is a very easy way to create
	a stream from the contents of a file.

2021-02-12  Jay Berkenbilt  <ejb@ql.org>

	* Move formerly internal QPDFMatrix class to the public API. This
	class provides convenience methods for working with transformation
	matrices.

	* QUtil::double_to_string: trim trailing zeroes by default, and
	add option to not trim trailing zeroes. This causes a syntactic
	but semantically preserving change in output when doubles are
	converted to strings. The library uses double_to_string in only a
	few places. In practice, output will be different (trailing zeroes
	removed) in code that creates form XObjects (mostly generation of
	appearance streams for form fields as well as overlay and
	underlay) and in the flatten rotation code that was added in qpdf
	10.1.

2021-02-10  Jay Berkenbilt  <ejb@ql.org>

	* Require a C++-14 compiler.

	* Detect loops when adding when reading outlines dictionary upon
	initialization of QPDFOutlineDocumentHelper (fuzz issue 30507).

	* Add "attachments" as an additional json key, and add some
	information about attachments to the json output.

	* Add new command-line arguments for operating on attachments:
	--list-attachments, --add-attachment, --remove-attachment,
