CIB pdf toolbox 2 technical documentation
4. Usecases
4.7. Writing PDF documents
Writing a document to a file
Property |
Meaning |
Type |
OutputFilename |
Filename to which the pdf should be written to. |
Set |
Writing a document to memory
Property |
Meaning |
Type |
MemoryOutputCallback |
Address of a callback function which retrieves the pdf data. The address has to be written as a string, which contains the address as normal number. The callback function needs to have the signature: int MemoryCallback(const uint8_t* output, size_t length, void* userdata, int error);
The return value needs to be 1, if the callback wan’t to return success, otherwise 0. |
Set |
MemoryOutputUserdata |
Address of a userdata object which is used inside the callback. The address has to be written as a string, which contains the address as normal number. |
|
Normally a PDF is saved with the best saving options, which the PdfVersion of the document allows. This means object stream and xref streams will be used with a PdfVersion greater or equal to 1.5. This behavior can be overridden by setting the property WritingMode:
Property |
Meaning |
Type |
DontOverwriteProducer |
Don’t write the CIB pdfModule default Producer into the Metadata. |
Set |
WritingMode |
|
Set |
IncrementalUpdate |
An incremental update to a PDF means, that the whole input document is not changed in its content, but at the end of the document all changes, which were made are written combined inside an update entry. This means e.g. that signed signatures in an existing PDF document are not getting broken, but still you can add more content or modify the PDF document. Inside a (good) PDF viewer you can see then, that the PDF consists of different versions and you can switch between them. |
Set |