summaryrefslogtreecommitdiffstats
path: root/libqpdf/QPDFObjectHandle.cc
AgeCommit message (Collapse)Author
2013-10-18Security: replace operator[] with atJay Berkenbilt
For std::string and std::vector, replace operator[] with at. This was done using an automated process. See README.hardening for details.
2013-07-07Fix errors reported by CoverityJay Berkenbilt
Thanks to Jiri Popelka from Red Hat for sending the output of a Coverity run over qpdf.
2013-06-14Add QPDFObjectHandle::getObjGen()Jay Berkenbilt
This is safer than getObjectID() and getGeneration() for many uses.
2013-04-04Add explicit int to double castJay Berkenbilt
2013-03-05Fix getTypeCode and getTypeName work for indirect objectsJay Berkenbilt
Remove const qualifier from getTypeCode and get getTypeName methods of QPDFObjectHandle, make them work properly for indirect objects, and exercise them much better in the test suite.
2013-03-05Add method to terminate content stream parsingJay Berkenbilt
2013-03-04Remove all old-style casts from C++ codeJay Berkenbilt
2013-01-25Improve qpdf --checkJay Berkenbilt
Fix exit status for case of errors without warnings, continue after errors when possible, add test case for parsing a file with content stream errors on some but not all pages.
2013-01-23Cosmetic changes to be closer to Adobe terminologyJay Berkenbilt
Change object type Keyword to Operator, and place the order of the object types in object_type_e in the same order as they are mentioned in the PDF specification. Note that this change only breaks backward compatibility with code that has not yet been released.
2013-01-22Add getTypeCode() and getTypeName()Jay Berkenbilt
Add virtual methods to QPDFObject, wrappers to QPDFObjectHandle, and implementations to all the QPDF_Object types.
2013-01-20Add QPDFObjectHandle::parseContentStream methodJay Berkenbilt
This method allows parsing of the PDF objects in a content stream or array of content streams.
2013-01-20Added new QPDFObjectHandle types Keyword and InlineImageJay Berkenbilt
These object types are to facilitate content stream parsing.
2012-07-25added QPDFObjectHandle::replaceStreamData(std::string data).Tobias Hoffmann
2012-07-21Implement QPDFObjectHandle::parseJay Berkenbilt
Move object parsing code from QPDF to QPDFObjectHandle and parameterize the parts of it that are specific to a QPDF object. Provide a version that can't handle indirect objects and that can be called on an arbitrary string. A side effect of this change is that the offset used when reporting invalid stream length has changed, but since the new value seems like a better value than the old one, the test suite has been updated rather than making the code backward compatible. This only effects the offset reported for invalid streams that lack /Length or have an invalid /Length key. Updated some test code and exmaples to use QPDFObjectHandle::parse. Supporting changes include adding a BufferInputSource constructor that takes a string.
2012-07-15qpdf: push inherited attributes to page when showing imagesJay Berkenbilt
from qpdf command-line tool
2012-07-11Support copying objects from another QPDF objectJay Berkenbilt
This includes QPDF::copyForeignObject and supporting foreign objects as arguments to addPage*.
2012-07-11Add concept of reserved objectsJay Berkenbilt
QPDFObjectHandle::{new,is,assert}Reserved, QPDF::replaceReserved provide a mechanism to add objects to a PDF file when there are circular references. This is a prerequisite to copying objects from one PDF to another.
2012-07-08Added assertNumber and assertScalar to QPDFObjectHandleTobias Hoffmann
2012-07-08Added public assert{Type} methods to QPDFObjectHandleTobias Hoffmann
2012-07-07Don't require stream data provider to know length in advanceJay Berkenbilt
Breaking API change: length parameter has disappeared from the StreamDataProvider version of QPDFObjectHandle::replaceStreamData since it is no longer necessary to compute it in advance. This breaking change is justified by the fact that removing the length parameter provides the caller an opportunity to simplify the calling code.
2012-06-27Add a few minor enhancements to recent workJay Berkenbilt
Test coverage case for new newStream method Expose decimal_places argument for double-based newReal All enhancements suggested by Tobias.
2012-06-27Add QPDFObjectHandle::newStream(QPDF *, std::string const&)Tobias Hoffmann
This makes the code simpler than having to create a buffer of a fixed size and copy the string to it.
2012-06-27Add QPDFObjectHandle::newReal(double)Tobias Hoffmann
2012-06-24Change QPDF_Integer from int to long longJay Berkenbilt
This makes it possible to store offsets that are larger than 2 GB in the trailer dictionary.
2012-06-22Switch some code to use empty newArray/newDictionaryJay Berkenbilt
2012-06-22Add factory methods for creating empty arrays and dictionaries.Jay Berkenbilt
Also updated pdf_from_scratch test driver to use the new factories, and made some cosmetic improvements and documentation updates for the emptyPDF() method.
2012-06-22Use qpdf_offset_t in place of off_t in public APIs.Jay Berkenbilt
off_t is used internally only when needed to talk to standard libraries. This requires that the "long long" type be supported by the compiler.
2012-06-21Add QPDFObjectHandle::shallowCopy()Jay Berkenbilt
2012-06-20Added additional array mutatorsTobias Hoffmann
Added methods to append to arrays, insert items into arrays, and replace array contents with a vector of items.
2012-06-20ABI change: fix use of off_t, size_t, and integer typesJay Berkenbilt
Significantly improve the code's use of off_t for file offsets, size_t for memory sizes, and integer types in cases where there has to be compatibility with external interfaces. Rework sections of the code that would have prevented qpdf from working on files larger than 2 (or maybe 4) GB in size.
2011-08-10implement methods to get dictionary and array contents as map and vectorJay Berkenbilt
2010-09-24update code to new PointerHolder, and reintroduce change that was ↵Jay Berkenbilt
accidentally backed out git-svn-id: svn+q:///qpdf/trunk@1031 71b93d88-0707-0410-a8cf-f5a4172ac649
2010-08-10getRawStreamData()Jay Berkenbilt
git-svn-id: svn+q:///qpdf/trunk@1010 71b93d88-0707-0410-a8cf-f5a4172ac649
2010-08-05addPageContentsJay Berkenbilt
git-svn-id: svn+q:///qpdf/trunk@995 71b93d88-0707-0410-a8cf-f5a4172ac649
2010-08-05newStreamJay Berkenbilt
git-svn-id: svn+q:///qpdf/trunk@991 71b93d88-0707-0410-a8cf-f5a4172ac649
2010-08-05add pipeline-based stream data replacement functionJay Berkenbilt
git-svn-id: svn+q:///qpdf/trunk@990 71b93d88-0707-0410-a8cf-f5a4172ac649
2010-08-03remove stream_data_handler; it wouldn't work as designed. replacement data ↵Jay Berkenbilt
implemented but not tested git-svn-id: svn+q:///qpdf/trunk@988 71b93d88-0707-0410-a8cf-f5a4172ac649
2010-08-03ready to implement replacement stream dataJay Berkenbilt
git-svn-id: svn+q:///qpdf/trunk@987 71b93d88-0707-0410-a8cf-f5a4172ac649
2010-06-06comment on memory leak fixJay Berkenbilt
git-svn-id: svn+q:///qpdf/trunk@979 71b93d88-0707-0410-a8cf-f5a4172ac649
2010-06-06fix memory leakJay Berkenbilt
git-svn-id: svn+q:///qpdf/trunk@976 71b93d88-0707-0410-a8cf-f5a4172ac649
2010-05-31Use a pointer holder in one place where we were previously just usingJay Berkenbilt
a pointer. git-svn-id: svn+q:///qpdf/trunk@968 71b93d88-0707-0410-a8cf-f5a4172ac649
2009-10-19deal with stream-specific crypt filtersJay Berkenbilt
git-svn-id: svn+q:///qpdf/trunk@827 71b93d88-0707-0410-a8cf-f5a4172ac649
2009-10-12do DLL_EXPORT only in header files and only at the class or top-level ↵Jay Berkenbilt
function level git-svn-id: svn+q:///qpdf/trunk@796 71b93d88-0707-0410-a8cf-f5a4172ac649
2009-09-26removed qexc; non-compatible ABI changeJay Berkenbilt
git-svn-id: svn+q:///qpdf/trunk@709 71b93d88-0707-0410-a8cf-f5a4172ac649
2009-08-06stick DLL_EXPORT in front of every public method of every public classJay Berkenbilt
git-svn-id: svn+q:///qpdf/trunk@688 71b93d88-0707-0410-a8cf-f5a4172ac649
2009-02-21fix many typos in comments and stringsJay Berkenbilt
git-svn-id: svn+q:///qpdf/trunk@651 71b93d88-0707-0410-a8cf-f5a4172ac649
2008-05-04missing header files for gcc 4.3Jay Berkenbilt
git-svn-id: svn+q:///qpdf/trunk@607 71b93d88-0707-0410-a8cf-f5a4172ac649
2008-04-29update release date to actual daterelease-qpdf-2.0Jay Berkenbilt
git-svn-id: svn+q:///qpdf/trunk@599 71b93d88-0707-0410-a8cf-f5a4172ac649