aboutsummaryrefslogtreecommitdiffstats
path: root/libqpdf
AgeCommit message (Collapse)Author
2019-01-26Handle inheritable page attributesJay Berkenbilt
Add getAttribute for handling inheritable page attributes, and fix getPageImages and annotation flattening code to use it.
2019-01-21Handle fallback font size in text appearancesJay Berkenbilt
If we end up using our fallback font size when generating appearances for text fields, reflect that in the Tf operator used in the appearance stream.
2019-01-21Improve text objects used in text appearance streamsJay Berkenbilt
2019-01-21Fix omissions in text appearance generationJay Berkenbilt
When generating appearance streams for variable text annotations, properly handle the cases of there being no appearance dictionary, no appearance stream, or an appearance stream with no BMC..EMC marker.
2019-01-21When flattening, remove annotations with no appearance streamJay Berkenbilt
With the exception of form field annotations when /NeedAppearances is true, remove annotations that don't have appearance streams when flattening. There is no reason to keep these when flattening since they are invisible. This may include unchecked checkboxes, unshown popup windows, etc.
2019-01-19mingw workaround for QPDFExc destructorJay Berkenbilt
mingw doesn't like it when you don't inline empty virtual destructors.
2019-01-17Add QUtil::possible_repaired_encodingsJay Berkenbilt
2019-01-17Modernize encryption API for more granularityJay Berkenbilt
Setting encryption permissions for R >= 3 set permission bits in groups corresponding to menu options in Acrobat 5. The new API allows the bits to be set individually.
2019-01-17Add status-reporting transcoders to QUtilJay Berkenbilt
2019-01-17QUtil::analyze_encodingJay Berkenbilt
2019-01-17Bidirectional transcoding for win, mac, pdf, utf8, utf16Jay Berkenbilt
2019-01-17Move remaining existing transcoding to QUtilJay Berkenbilt
2019-01-17Additional checks for unreferenced resourcesJay Berkenbilt
Explicitly abandon removal of unreferenced resources if there are any lexical errors in the page's contents. This case always generated a warning, but it now also prevents removal of unreferenced resources, this strongly decreasing the likelihood of data loss.
2019-01-17Copy subdictionaries when removing resources (fixes #276)Jay Berkenbilt
When removing unreferenced resources, the code was copying the overall resource dictionaries but not the subdictionaries being modified. This was a "typo" in the code -- the comment clearly stated the need to do this, but the code replaced the dictionary with itself rather than with a shallow copy of itself.
2019-01-12Allow adding the same page more than once in --pages (fixes #272)Jay Berkenbilt
2019-01-11Add configure option AVOID_WINDOWS_HANDLEJay Berkenbilt
If set, we avoid using Windows I/O HANDLE, which is disallowed in some versions of the Windows SDK, such as for Windows phones. QUtil::same_file will always return false in this case. Only applies to Windows builds.
2019-01-11Add QPDF::setImmediateCopyFromJay Berkenbilt
2019-01-07Update version to 8.3.0Jay Berkenbilt
2019-01-07Fix integer overflow in large file testJay Berkenbilt
2019-01-07Exercise out of scope original pdf for copyForeignObjectJay Berkenbilt
2019-01-07Mostly don't require original QPDF for copyForeignObject (fixes #219)Jay Berkenbilt
The original QPDF is only required now when the source QPDFObjectHandle is a stream that gets its stream data from a QPDFObjectHandle::StreamDataProvider.
2019-01-07Make a static version of QPDF::pipeStreamDataJay Berkenbilt
This is in preparation of being able to pipe a stream's data without keeping a copy of its containing qpdf object.
2019-01-07Create an application-scope unique ID for each QPDF objectJay Berkenbilt
Use this instead of QPDF* as a map key for object_copiers.
2019-01-06Move encryption parameters into a classJay Berkenbilt
2019-01-06Honor other base encodings when generating appearancesJay Berkenbilt
2019-01-06Add WinAnsi and MacRoman encodingJay Berkenbilt
2019-01-06Refactor QUtil::utf8_to_asciiJay Berkenbilt
2019-01-06Move utf8_to_utf16 into QUtilJay Berkenbilt
2019-01-06Refactor string transcoding in QPDF_StringJay Berkenbilt
2019-01-05Spell checkJay Berkenbilt
2019-01-04Add QPDFWriter::getFinalVersion (fixes #266)Jay Berkenbilt
2019-01-04Don't call assert while checking linearization data (fixes #209, #231)Jay Berkenbilt
Instead of calling assert for problems found during checking linearization data, throw an exception which is later caught and issued as an error. Ideally we would handle errors more robustly, but this is still a significant improvement.
2019-01-04Fix dangling references (fixes #240)Jay Berkenbilt
On certain operations, such as iterating through all objects and adding new indirect objects, walk through the entire object structure and explicitly resolve any indirect references to non-existent objects. That prevents new objects from springing into existence and causing the previously dangling references to point to them.
2019-01-04Add basic appearance stream generationJay Berkenbilt
2019-01-04Add QUtil::utf8_to_asciiJay Berkenbilt
2019-01-04Add special case setV code for button fieldsJay Berkenbilt
2019-01-04Add form fields to json outputJay Berkenbilt
Also add some additional methods for detecting form field types to assist in the json creation and for later use.
2019-01-03Honor flags when flattening annotationsJay Berkenbilt
2019-01-03Minor fixesJay Berkenbilt
2019-01-03Fix seg fault on empty xref stream (fixes #263)Jay Berkenbilt
Thanks to @p-cher for supplying a patch.
2019-01-03Switch annotation flattening to use the form xobjectsJay Berkenbilt
Instead of directly putting the contents of the annotation appearance streams into the page's content stream, add commands to render the form xobjects directly. This is a more robust way to do it than the original solution as it works properly with patterns and avoids problems with resource name clashes between the pages and the form xobjects.
2019-01-01Annotation flattening including form fieldsJay Berkenbilt
Flatten annotations by integrating their appearance streams into the content stream of the containing page. In the case of form fields, only flatten if /NeedAppearance is false (or equivalently absent). If flattening form fields, also remove /AcroForm from the document catalog.
2019-01-01Add QPDFObjectHandle::mergeDictionary()Jay Berkenbilt
2019-01-01Add matrix and annotation appearance stream handlingJay Berkenbilt
Generate page content fragment for rendering appearance streams including all matrix calculation.
2019-01-01Add Matrix class under QPDFObjectHandleJay Berkenbilt
2019-01-01Transformation matrixJay Berkenbilt
2018-12-25JSON::serialize -> unparseJay Berkenbilt
Unparse is admittedly strange, but I'd rather be strange and consistent, and everything else in the qpdf library uses unparse to serialize. (If you're reading this, the convention of using "unparse" comes from the "clu" programming language.)
2018-12-22Move numrange code from qpdf.cc to QUtil.ccJay Berkenbilt
Also move tests to libtests.
2018-12-22Add document and object helpers for outlines (bookmarks)Jay Berkenbilt
2018-12-22Add QPDFObjectHandle::getJSON()Jay Berkenbilt