Q: what does each enum value in Doc.SaveOptions signify. Could
you please elaborate on this. I load an existing pdf, add an
attachment to it and save it with anothername. What would be
the best saveOption for this?
In PDFNet documents can be saved using full
(SDF.Doc.SaveOptions.e_remove_unused/e_linearized) or incremental save
mode (SDF.Doc.SaveOptions.e_incremental). e_remove_unused/e_linearized
modes are more time consuming, but offer extra options such as unused
object removal, serialization optimizations etc. In the full save mode
(e_linearized/e_remove_unused), PDFNet will remove all objects that are
not referenced in a document resulting in a smaller output file size.
e_linearized option will also save the PDF using 'fast web view' mode
allowing for fast document preview over the Net (and other slow
Incremental save (Doc.SaveOptions.e_incremental) is usually much faster
and allows for persistent undo functionality. In this mode changes are
appended to the end of the file, leaving its original contents intact.
In order to use incremental save the specified path must match original
path and e_incremental flag bit should be set.
e_linearized flag will usually produce the most optimized output (at
the expense of speed).