PDF Toolbox
Loading...
Searching...
No Matches
Macros | Functions
PdfToolbox_PtxPdf.h File Reference
#include "PdfToolbox_Types.h"
#include "PdfToolbox_PtxSys.h"

Go to the source code of this file.

Macros

#define PDFTOOLBOX_CALL
 
#define PtxPdf_Encryption_New   PtxPdf_Encryption_NewA
 
#define PtxPdf_Encryption_GetUserPassword   PtxPdf_Encryption_GetUserPasswordA
 
#define PtxPdf_Encryption_SetUserPassword   PtxPdf_Encryption_SetUserPasswordA
 
#define PtxPdf_Encryption_GetOwnerPassword   PtxPdf_Encryption_GetOwnerPasswordA
 
#define PtxPdf_Encryption_SetOwnerPassword   PtxPdf_Encryption_SetOwnerPasswordA
 
#define PtxPdf_Document_Open   PtxPdf_Document_OpenA
 
#define PtxPdf_Document_OpenWithFdf   PtxPdf_Document_OpenWithFdfA
 
#define PtxPdf_Page_GetPageLabel   PtxPdf_Page_GetPageLabelA
 
#define PtxPdf_Metadata_GetTitle   PtxPdf_Metadata_GetTitleA
 
#define PtxPdf_Metadata_SetTitle   PtxPdf_Metadata_SetTitleA
 
#define PtxPdf_Metadata_GetAuthor   PtxPdf_Metadata_GetAuthorA
 
#define PtxPdf_Metadata_SetAuthor   PtxPdf_Metadata_SetAuthorA
 
#define PtxPdf_Metadata_GetSubject   PtxPdf_Metadata_GetSubjectA
 
#define PtxPdf_Metadata_SetSubject   PtxPdf_Metadata_SetSubjectA
 
#define PtxPdf_Metadata_GetKeywords   PtxPdf_Metadata_GetKeywordsA
 
#define PtxPdf_Metadata_SetKeywords   PtxPdf_Metadata_SetKeywordsA
 
#define PtxPdf_Metadata_GetCreator   PtxPdf_Metadata_GetCreatorA
 
#define PtxPdf_Metadata_SetCreator   PtxPdf_Metadata_SetCreatorA
 
#define PtxPdf_Metadata_GetProducer   PtxPdf_Metadata_GetProducerA
 
#define PtxPdf_FileReference_Create   PtxPdf_FileReference_CreateA
 
#define PtxPdf_FileReference_GetAssociationRelationship   PtxPdf_FileReference_GetAssociationRelationshipA
 
#define PtxPdf_FileReference_SetAssociationRelationship   PtxPdf_FileReference_SetAssociationRelationshipA
 
#define PtxPdf_FileReference_GetDescription   PtxPdf_FileReference_GetDescriptionA
 
#define PtxPdf_FileReference_GetMediaType   PtxPdf_FileReference_GetMediaTypeA
 
#define PtxPdf_FileReference_GetName   PtxPdf_FileReference_GetNameA
 

Functions

PDFTOOLBOX_EXPORT TPtxPdf_PageCopyOptions *PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_New (void)
 
PDFTOOLBOX_EXPORT TPtxPdf_CopyStrategy PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetLinks (TPtxPdf_PageCopyOptions *pPageCopyOptions)
 Copy strategy for links.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetLinks (TPtxPdf_PageCopyOptions *pPageCopyOptions, TPtxPdf_CopyStrategy iLinks)
 Copy strategy for links.
 
PDFTOOLBOX_EXPORT TPtxPdfForms_FormFieldCopyStrategy PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetFormFields (TPtxPdf_PageCopyOptions *pPageCopyOptions)
 Copy strategy for form fields and widgets.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetFormFields (TPtxPdf_PageCopyOptions *pPageCopyOptions, TPtxPdfForms_FormFieldCopyStrategy iFormFields)
 Copy strategy for form fields and widgets.
 
PDFTOOLBOX_EXPORT TPtxPdf_RemovalStrategy PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetSignedSignatures (TPtxPdf_PageCopyOptions *pPageCopyOptions)
 Removal strategy for signed signature fields.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetSignedSignatures (TPtxPdf_PageCopyOptions *pPageCopyOptions, TPtxPdf_RemovalStrategy iSignedSignatures)
 Removal strategy for signed signature fields.
 
PDFTOOLBOX_EXPORT TPtxPdf_CopyStrategy PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetUnsignedSignatures (TPtxPdf_PageCopyOptions *pPageCopyOptions)
 Copy strategy for unsigned signature fields.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetUnsignedSignatures (TPtxPdf_PageCopyOptions *pPageCopyOptions, TPtxPdf_CopyStrategy iUnsignedSignatures)
 Copy strategy for unsigned signature fields.
 
PDFTOOLBOX_EXPORT TPtxPdf_CopyStrategy PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetAnnotations (TPtxPdf_PageCopyOptions *pPageCopyOptions)
 Copy strategy for annotations.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetAnnotations (TPtxPdf_PageCopyOptions *pPageCopyOptions, TPtxPdf_CopyStrategy iAnnotations)
 Copy strategy for annotations.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetCopyOutlineItems (TPtxPdf_PageCopyOptions *pPageCopyOptions)
 Copy outline items (bookmarks).
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetCopyOutlineItems (TPtxPdf_PageCopyOptions *pPageCopyOptions, BOOL bCopyOutlineItems)
 Copy outline items (bookmarks).
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetCopyAssociatedFiles (TPtxPdf_PageCopyOptions *pPageCopyOptions)
 Copy associated files.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetCopyAssociatedFiles (TPtxPdf_PageCopyOptions *pPageCopyOptions, BOOL bCopyAssociatedFiles)
 Copy associated files.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetCopyLogicalStructure (TPtxPdf_PageCopyOptions *pPageCopyOptions)
 Copy the logical structure and tagging information.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetCopyLogicalStructure (TPtxPdf_PageCopyOptions *pPageCopyOptions, BOOL bCopyLogicalStructure)
 Copy the logical structure and tagging information.
 
PDFTOOLBOX_EXPORT TPtxPdf_NameConflictResolution PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetFormFieldConflictResolution (TPtxPdf_PageCopyOptions *pPageCopyOptions)
 Resolution of conflicting form field names.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetFormFieldConflictResolution (TPtxPdf_PageCopyOptions *pPageCopyOptions, TPtxPdf_NameConflictResolution iFormFieldConflictResolution)
 Resolution of conflicting form field names.
 
PDFTOOLBOX_EXPORT TPtxPdf_NameConflictResolution PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetOcgConflictResolution (TPtxPdf_PageCopyOptions *pPageCopyOptions)
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetOcgConflictResolution (TPtxPdf_PageCopyOptions *pPageCopyOptions, TPtxPdf_NameConflictResolution iOcgConflictResolution)
 
PDFTOOLBOX_EXPORT TPtxPdfNav_NamedDestinationCopyStrategy PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetNamedDestinations (TPtxPdf_PageCopyOptions *pPageCopyOptions)
 Copy strategy for named destinations.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetNamedDestinations (TPtxPdf_PageCopyOptions *pPageCopyOptions, TPtxPdfNav_NamedDestinationCopyStrategy iNamedDestinations)
 Copy strategy for named destinations.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetOptimizeResources (TPtxPdf_PageCopyOptions *pPageCopyOptions)
 Find and merge redundant resources.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetOptimizeResources (TPtxPdf_PageCopyOptions *pPageCopyOptions, BOOL bOptimizeResources)
 Find and merge redundant resources.
 
PDFTOOLBOX_EXPORT TPtxPdf_Encryption *PDFTOOLBOX_CALL PtxPdf_Encryption_NewA (const char *szUserPassword, const char *szOwnerPassword, TPtxPdf_Permission iPermissions)
 
PDFTOOLBOX_EXPORT TPtxPdf_Encryption *PDFTOOLBOX_CALL PtxPdf_Encryption_NewW (const WCHAR *szUserPassword, const WCHAR *szOwnerPassword, TPtxPdf_Permission iPermissions)
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Encryption_GetUserPasswordA (TPtxPdf_Encryption *pEncryption, char *pBuffer, size_t nBufferSize)
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Encryption_GetUserPasswordW (TPtxPdf_Encryption *pEncryption, WCHAR *pBuffer, size_t nBufferSize)
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Encryption_SetUserPasswordA (TPtxPdf_Encryption *pEncryption, const char *szUserPassword)
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Encryption_SetUserPasswordW (TPtxPdf_Encryption *pEncryption, const WCHAR *szUserPassword)
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Encryption_GetOwnerPasswordA (TPtxPdf_Encryption *pEncryption, char *pBuffer, size_t nBufferSize)
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Encryption_GetOwnerPasswordW (TPtxPdf_Encryption *pEncryption, WCHAR *pBuffer, size_t nBufferSize)
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Encryption_SetOwnerPasswordA (TPtxPdf_Encryption *pEncryption, const char *szOwnerPassword)
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Encryption_SetOwnerPasswordW (TPtxPdf_Encryption *pEncryption, const WCHAR *szOwnerPassword)
 
PDFTOOLBOX_EXPORT TPtxPdf_Permission PDFTOOLBOX_CALL PtxPdf_Encryption_GetPermissions (TPtxPdf_Encryption *pEncryption)
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Encryption_SetPermissions (TPtxPdf_Encryption *pEncryption, TPtxPdf_Permission iPermissions)
 
PDFTOOLBOX_EXPORT TPtxPdf_PageList *PDFTOOLBOX_CALL PtxPdf_PageList_Copy (TPtxPdf_Document *pTargetDocument, TPtxPdf_PageList *pPageList, TPtxPdf_PageCopyOptions *pOptions)
 Copy a page list Copy pages from an input document to the given pTargetDocument. The returned list is associated with the given target document but not yet part of it. It can be appended to the document's page list.
 
PDFTOOLBOX_EXPORT int PDFTOOLBOX_CALL PtxPdf_PageList_GetCount (TPtxPdf_PageList *pPageList)
 Get the number of elements in the list.
 
PDFTOOLBOX_EXPORT TPtxPdf_Page *PDFTOOLBOX_CALL PtxPdf_PageList_Get (TPtxPdf_PageList *pPageList, int iIndex)
 Returns the element at the specified position in the given list.
 
PDFTOOLBOX_EXPORT TPtxPdf_PageList *PDFTOOLBOX_CALL PtxPdf_PageList_GetRange (TPtxPdf_PageList *pPageList, int iIndex, int iCount)
 Get range of elements.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageList_Add (TPtxPdf_PageList *pPageList, TPtxPdf_Page *pPage)
 Add an element to the end of the list.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageList_AddRange (TPtxPdf_PageList *pPageList, TPtxPdf_PageList *pInput)
 Add range of elements to th end of the list.
 
PDFTOOLBOX_EXPORT int PDFTOOLBOX_CALL PtxPdf_FileReferenceList_GetCount (TPtxPdf_FileReferenceList *pFileReferenceList)
 Get the number of elements in the list.
 
PDFTOOLBOX_EXPORT TPtxPdf_FileReference *PDFTOOLBOX_CALL PtxPdf_FileReferenceList_Get (TPtxPdf_FileReferenceList *pFileReferenceList, int iIndex)
 Returns the element at the specified position in the given list.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_FileReferenceList_Add (TPtxPdf_FileReferenceList *pFileReferenceList, TPtxPdf_FileReference *pFileReference)
 Add an element to the end of the list.
 
PDFTOOLBOX_EXPORT TPtxPdf_Document *PDFTOOLBOX_CALL PtxPdf_Document_OpenA (const TPtxSys_StreamDescriptor *pStreamDesc, const char *szPassword)
 Open a PDF document. Documents opened with this method are read-only and cannot be modified.
 
PDFTOOLBOX_EXPORT TPtxPdf_Document *PDFTOOLBOX_CALL PtxPdf_Document_OpenW (const TPtxSys_StreamDescriptor *pStreamDesc, const WCHAR *szPassword)
 Open a PDF document. Documents opened with this method are read-only and cannot be modified.
 
PDFTOOLBOX_EXPORT TPtxPdf_Document *PDFTOOLBOX_CALL PtxPdf_Document_OpenWithFdfA (const TPtxSys_StreamDescriptor *pPdfStreamDesc, const TPtxSys_StreamDescriptor *pFdfStreamDesc, const char *szPassword)
 Open a PDF document together with an FDF file. Documents opened with this method are read-only and cannot be modified.
 
PDFTOOLBOX_EXPORT TPtxPdf_Document *PDFTOOLBOX_CALL PtxPdf_Document_OpenWithFdfW (const TPtxSys_StreamDescriptor *pPdfStreamDesc, const TPtxSys_StreamDescriptor *pFdfStreamDesc, const WCHAR *szPassword)
 Open a PDF document together with an FDF file. Documents opened with this method are read-only and cannot be modified.
 
PDFTOOLBOX_EXPORT TPtxPdf_Document *PDFTOOLBOX_CALL PtxPdf_Document_Create (const TPtxSys_StreamDescriptor *pStreamDesc, const TPtxPdf_Conformance *pConformance, TPtxPdf_Encryption *pEncryption)
 Create a new PDF document. Documents with created with this method are writable and can be modified.
 
PDFTOOLBOX_EXPORT TPtxPdf_Document *PDFTOOLBOX_CALL PtxPdf_Document_CreateWithFdf (const TPtxSys_StreamDescriptor *pPdfStreamDesc, const TPtxSys_StreamDescriptor *pFdfStreamDesc, const TPtxPdf_Conformance *pConformance, TPtxPdf_Encryption *pEncryption)
 Create a new PDF document and an associated FDF. Documents with created with this method are writable and can be modified. When creating a document with this method, all TPtxPdfAnnots_MarkupAnnotations - created or copied - are stored as an FDF file to the pFdfStreamDesc. In the output PDF (pPdfStreamDesc), only annotations that are not TPtxPdfAnnots_MarkupAnnotations are stored.
 
PDFTOOLBOX_EXPORT TPtxPdf_Conformance PDFTOOLBOX_CALL PtxPdf_Document_GetConformance (TPtxPdf_Document *pDocument)
 the claimed conformance of the document. This method only returns the claimed conformance level, the document is not validated.
 
PDFTOOLBOX_EXPORT TPtxPdf_Metadata *PDFTOOLBOX_CALL PtxPdf_Document_GetMetadata (TPtxPdf_Document *pDocument)
 the metadata of the document. If the document is writable, the metadata object will be writable too and all changes to the metadata object are reflected in the document.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_SetMetadata (TPtxPdf_Document *pDocument, TPtxPdf_Metadata *pMetadata)
 the metadata of the document. If the document is writable, the metadata object will be writable too and all changes to the metadata object are reflected in the document.
 
PDFTOOLBOX_EXPORT TPtxPdf_PageList *PDFTOOLBOX_CALL PtxPdf_Document_GetPages (TPtxPdf_Document *pDocument)
 the pages of the document. If the document is writable, it is possible to append new pages to the end of the list.
 
PDFTOOLBOX_EXPORT TPtxPdfContent_IccBasedColorSpace *PDFTOOLBOX_CALL PtxPdf_Document_GetOutputIntent (TPtxPdf_Document *pDocument)
 the output intent of the document. The output intent specifies a color profile that characterizes the intended output device. It is used to render device colors on devices other than the intended output device.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_SetOutputIntent (TPtxPdf_Document *pDocument, TPtxPdfContent_IccBasedColorSpace *pOutputIntent)
 the output intent of the document. The output intent specifies a color profile that characterizes the intended output device. It is used to render device colors on devices other than the intended output device.
 
PDFTOOLBOX_EXPORT TPtxPdfForms_FieldNodeMap *PDFTOOLBOX_CALL PtxPdf_Document_GetFormFields (TPtxPdf_Document *pDocument)
 The form fields of the document This list contains all AcroForm form fields that belong to this document. Adding to this list results in an error:
 
PDFTOOLBOX_EXPORT TPtxPdfForms_SignatureFieldList *PDFTOOLBOX_CALL PtxPdf_Document_GetSignatureFields (TPtxPdf_Document *pDocument)
 The signature fields of the document Signature fields are a special kind of form fields, that can contain digital signatures.
 
PDFTOOLBOX_EXPORT TPtxPdf_FileReferenceList *PDFTOOLBOX_CALL PtxPdf_Document_GetPlainEmbeddedFiles (TPtxPdf_Document *pDocument)
 plain embedded files
 
PDFTOOLBOX_EXPORT TPtxPdf_FileReferenceList *PDFTOOLBOX_CALL PtxPdf_Document_GetAssociatedFiles (TPtxPdf_Document *pDocument)
 document-associated files
 
PDFTOOLBOX_EXPORT TPtxPdf_FileReferenceList *PDFTOOLBOX_CALL PtxPdf_Document_GetAllEmbeddedFiles (TPtxPdf_Document *pDocument)
 plain embedded, associated, and attached files
 
PDFTOOLBOX_EXPORT TPtxPdfNav_OutlineItemList *PDFTOOLBOX_CALL PtxPdf_Document_GetOutline (TPtxPdf_Document *pDocument)
 
PDFTOOLBOX_EXPORT TPtxPdfNav_Destination *PDFTOOLBOX_CALL PtxPdf_Document_GetOpenDestination (TPtxPdf_Document *pDocument)
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_SetOpenDestination (TPtxPdf_Document *pDocument, TPtxPdfNav_Destination *pOpenDestination)
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_GetPermissions (TPtxPdf_Document *pDocument, TPtxPdf_Permission *pPermissions)
 
PDFTOOLBOX_EXPORT TPtxPdfNav_ViewerSettings *PDFTOOLBOX_CALL PtxPdf_Document_GetViewerSettings (TPtxPdf_Document *pDocument)
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_SetViewerSettings (TPtxPdf_Document *pDocument, TPtxPdfNav_ViewerSettings *pViewerSettings)
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_IsLinearized (TPtxPdf_Document *pDocument)
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_Close (TPtxPdf_Document *pObject)
 Close object.
 
PDFTOOLBOX_EXPORT TPtxPdf_Page *PDFTOOLBOX_CALL PtxPdf_Page_Create (TPtxPdf_Document *pTargetDocument, const TPtxGeomReal_Size *pSize)
 Create an empty page The page is associated with the given target document but not yet part of it. It can be appended to the document's page list.
 
PDFTOOLBOX_EXPORT TPtxPdf_Page *PDFTOOLBOX_CALL PtxPdf_Page_Copy (TPtxPdf_Document *pTargetDocument, TPtxPdf_Page *pPage, TPtxPdf_PageCopyOptions *pOptions)
 Copy a page Copy a page object from an input document to the given pTargetDocument. The returned object is associated with the given target document but not yet part of it. It can be appended to the document's page list.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_UpdateSize (TPtxPdf_Page *pPage, const TPtxGeomReal_Rectangle *pRectangle)
 Update the page size to a specified rectangle. Note that all page-related coordinates are normalized to the crop box of the page. Updating the page size thus changes the coordinate system, rendering all previously extracted coordinates invalid.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_Rotate (TPtxPdf_Page *pPage, TPtxGeom_Rotation iRotate)
 Rotate the page by a multiple of 90 degrees.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_GetSize (TPtxPdf_Page *pPage, TPtxGeomReal_Size *pSize)
 the visible size of the page (crop box).
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_GetMediaBox (TPtxPdf_Page *pPage, TPtxGeomReal_Rectangle *pMediaBox)
 The media box of the page.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_GetBleedBox (TPtxPdf_Page *pPage, TPtxGeomReal_Rectangle *pBleedBox)
 The bleed box of the page.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_GetTrimBox (TPtxPdf_Page *pPage, TPtxGeomReal_Rectangle *pTrimBox)
 The trim box of the page.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_GetArtBox (TPtxPdf_Page *pPage, TPtxGeomReal_Rectangle *pArtBox)
 The art box of the page.
 
PDFTOOLBOX_EXPORT TPtxPdfContent_Content *PDFTOOLBOX_CALL PtxPdf_Page_GetContent (TPtxPdf_Page *pPage)
 the page content. If the page is writable, the content object can be used to apply new content on the page, for example overlays or underlays.
 
PDFTOOLBOX_EXPORT TPtxPdfAnnots_AnnotationList *PDFTOOLBOX_CALL PtxPdf_Page_GetAnnotations (TPtxPdf_Page *pPage)
 the list of this page's annotations. Adding to this list results in an error:
 
PDFTOOLBOX_EXPORT TPtxPdfNav_LinkList *PDFTOOLBOX_CALL PtxPdf_Page_GetLinks (TPtxPdf_Page *pPage)
 the list of this page's links. Adding to this list results in an error:
 
PDFTOOLBOX_EXPORT TPtxPdfForms_WidgetList *PDFTOOLBOX_CALL PtxPdf_Page_GetWidgets (TPtxPdf_Page *pPage)
 the list of this page's form field widgets. Adding to this list results in an error:
 
PDFTOOLBOX_EXPORT TPtxPdf_Metadata *PDFTOOLBOX_CALL PtxPdf_Page_GetMetadata (TPtxPdf_Page *pPage)
 the metadata of the page.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_SetMetadata (TPtxPdf_Page *pPage, TPtxPdf_Metadata *pMetadata)
 the metadata of the page.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Page_GetPageLabelA (TPtxPdf_Page *pPage, char *pBuffer, size_t nBufferSize)
 Page label.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Page_GetPageLabelW (TPtxPdf_Page *pPage, WCHAR *pBuffer, size_t nBufferSize)
 Page label.
 
PDFTOOLBOX_EXPORT TPtxPdf_Metadata *PDFTOOLBOX_CALL PtxPdf_Metadata_Create (TPtxPdf_Document *pTargetDocument, const TPtxSys_StreamDescriptor *pXmp)
 Create a new metadata object The newly created metadata object is associated with the target document but not (yet) used as the document metadata. The object can be used either as document metadata using PtxPdf_Document_SetMetadata or as page metadata using PtxPdf_Page_SetMetadata.
 
PDFTOOLBOX_EXPORT TPtxPdf_Metadata *PDFTOOLBOX_CALL PtxPdf_Metadata_Copy (TPtxPdf_Document *pTargetDocument, TPtxPdf_Metadata *pMetadata)
 Copy a metadata object Copy a metadata object from an input document to the given pTargetDocument. The returned object is associated with the target document but not (yet) used as the document metadata. The object can be used either as document metadata using PtxPdf_Document_SetMetadata or as page metadata using PtxPdf_Page_SetMetadata.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetTitleA (TPtxPdf_Metadata *pMetadata, char *pBuffer, size_t nBufferSize)
 The title of the document or resource. This property corresponds to the "dc:title" entry in the XMP metadata and to the "Title" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetTitleW (TPtxPdf_Metadata *pMetadata, WCHAR *pBuffer, size_t nBufferSize)
 The title of the document or resource. This property corresponds to the "dc:title" entry in the XMP metadata and to the "Title" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetTitleA (TPtxPdf_Metadata *pMetadata, const char *szTitle)
 The title of the document or resource. This property corresponds to the "dc:title" entry in the XMP metadata and to the "Title" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetTitleW (TPtxPdf_Metadata *pMetadata, const WCHAR *szTitle)
 The title of the document or resource. This property corresponds to the "dc:title" entry in the XMP metadata and to the "Title" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetAuthorA (TPtxPdf_Metadata *pMetadata, char *pBuffer, size_t nBufferSize)
 The name of the person who created the document or resource. This property corresponds to the "dc:creator" entry in the XMP metadata and to the "Author" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetAuthorW (TPtxPdf_Metadata *pMetadata, WCHAR *pBuffer, size_t nBufferSize)
 The name of the person who created the document or resource. This property corresponds to the "dc:creator" entry in the XMP metadata and to the "Author" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetAuthorA (TPtxPdf_Metadata *pMetadata, const char *szAuthor)
 The name of the person who created the document or resource. This property corresponds to the "dc:creator" entry in the XMP metadata and to the "Author" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetAuthorW (TPtxPdf_Metadata *pMetadata, const WCHAR *szAuthor)
 The name of the person who created the document or resource. This property corresponds to the "dc:creator" entry in the XMP metadata and to the "Author" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetSubjectA (TPtxPdf_Metadata *pMetadata, char *pBuffer, size_t nBufferSize)
 The subject of the document or resource. This property corresponds to the "dc:description" entry in the XMP metadata and to the "Subject" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetSubjectW (TPtxPdf_Metadata *pMetadata, WCHAR *pBuffer, size_t nBufferSize)
 The subject of the document or resource. This property corresponds to the "dc:description" entry in the XMP metadata and to the "Subject" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetSubjectA (TPtxPdf_Metadata *pMetadata, const char *szSubject)
 The subject of the document or resource. This property corresponds to the "dc:description" entry in the XMP metadata and to the "Subject" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetSubjectW (TPtxPdf_Metadata *pMetadata, const WCHAR *szSubject)
 The subject of the document or resource. This property corresponds to the "dc:description" entry in the XMP metadata and to the "Subject" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetKeywordsA (TPtxPdf_Metadata *pMetadata, char *pBuffer, size_t nBufferSize)
 Keywords associated with the document or resource.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetKeywordsW (TPtxPdf_Metadata *pMetadata, WCHAR *pBuffer, size_t nBufferSize)
 Keywords associated with the document or resource.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetKeywordsA (TPtxPdf_Metadata *pMetadata, const char *szKeywords)
 Keywords associated with the document or resource.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetKeywordsW (TPtxPdf_Metadata *pMetadata, const WCHAR *szKeywords)
 Keywords associated with the document or resource.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetCreatorA (TPtxPdf_Metadata *pMetadata, char *pBuffer, size_t nBufferSize)
 The original application that created the document.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetCreatorW (TPtxPdf_Metadata *pMetadata, WCHAR *pBuffer, size_t nBufferSize)
 The original application that created the document.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetCreatorA (TPtxPdf_Metadata *pMetadata, const char *szCreator)
 The original application that created the document.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetCreatorW (TPtxPdf_Metadata *pMetadata, const WCHAR *szCreator)
 The original application that created the document.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetProducerA (TPtxPdf_Metadata *pMetadata, char *pBuffer, size_t nBufferSize)
 The application that created the PDF.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetProducerW (TPtxPdf_Metadata *pMetadata, WCHAR *pBuffer, size_t nBufferSize)
 The application that created the PDF.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_GetCreationDate (TPtxPdf_Metadata *pMetadata, TPtxSys_Date *pCreationDate)
 The date and time the document or resource was originally created. This property corresponds to the "xmp:CreateDate" entry in the XMP metadata and to the "CreationDate" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetCreationDate (TPtxPdf_Metadata *pMetadata, const TPtxSys_Date *pCreationDate)
 The date and time the document or resource was originally created. This property corresponds to the "xmp:CreateDate" entry in the XMP metadata and to the "CreationDate" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_GetModificationDate (TPtxPdf_Metadata *pMetadata, TPtxSys_Date *pModificationDate)
 The date and time the document or resource was most recently modified. This property corresponds to the "xmp:ModifyDate" entry in the XMP metadata and to the "ModDate" entry in the document information dictionary.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_GetXmp (TPtxPdf_Metadata *pMetadata, TPtxSys_StreamDescriptor *pOutStreamDesc)
 The XMP metadata.
 
PDFTOOLBOX_EXPORT TPtx_StringMap *PDFTOOLBOX_CALL PtxPdf_Metadata_GetCustomEntries (TPtxPdf_Metadata *pMetadata)
 The custom entries in the document information dictionary.
 
PDFTOOLBOX_EXPORT TPtxPdf_FileReference *PDFTOOLBOX_CALL PtxPdf_FileReference_CreateA (TPtxPdf_Document *pTargetDocument, const TPtxSys_StreamDescriptor *pData, const char *szName, const char *szMediaType, const char *szDescription, const TPtxSys_Date *pModificationDate)
 Create a new file reference object The newly created file reference object belongs to the document but is not (yet) used as an embedded file. The object can be added to the list of embedded files or to the list of associated files.
 
PDFTOOLBOX_EXPORT TPtxPdf_FileReference *PDFTOOLBOX_CALL PtxPdf_FileReference_CreateW (TPtxPdf_Document *pTargetDocument, const TPtxSys_StreamDescriptor *pData, const WCHAR *szName, const WCHAR *szMediaType, const WCHAR *szDescription, const TPtxSys_Date *pModificationDate)
 Create a new file reference object The newly created file reference object belongs to the document but is not (yet) used as an embedded file. The object can be added to the list of embedded files or to the list of associated files.
 
PDFTOOLBOX_EXPORT TPtxPdf_FileReference *PDFTOOLBOX_CALL PtxPdf_FileReference_Copy (TPtxPdf_Document *pTargetDocument, TPtxPdf_FileReference *pFileReference)
 Copy a file reference object Copy a file reference object from an input document to the given pTargetDocument. The returned object is associated with the given target document but not yet part of it.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetAssociationRelationshipA (TPtxPdf_FileReference *pFileReference, char *pBuffer, size_t nBufferSize)
 The file's association relationship This property is NULL if the file is not associated with any object. When associating a file reference with an object such as the document or a page, then this property defines the relationship between the file and the object. Typical values are:
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetAssociationRelationshipW (TPtxPdf_FileReference *pFileReference, WCHAR *pBuffer, size_t nBufferSize)
 The file's association relationship This property is NULL if the file is not associated with any object. When associating a file reference with an object such as the document or a page, then this property defines the relationship between the file and the object. Typical values are:
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_FileReference_SetAssociationRelationshipA (TPtxPdf_FileReference *pFileReference, const char *szAssociationRelationship)
 The file's association relationship This property is NULL if the file is not associated with any object. When associating a file reference with an object such as the document or a page, then this property defines the relationship between the file and the object. Typical values are:
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_FileReference_SetAssociationRelationshipW (TPtxPdf_FileReference *pFileReference, const WCHAR *szAssociationRelationship)
 The file's association relationship This property is NULL if the file is not associated with any object. When associating a file reference with an object such as the document or a page, then this property defines the relationship between the file and the object. Typical values are:
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetDescriptionA (TPtxPdf_FileReference *pFileReference, char *pBuffer, size_t nBufferSize)
 The file's description For embedded files, this is the description of the file presented to the user in the list of embedded files.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetDescriptionW (TPtxPdf_FileReference *pFileReference, WCHAR *pBuffer, size_t nBufferSize)
 The file's description For embedded files, this is the description of the file presented to the user in the list of embedded files.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetMediaTypeA (TPtxPdf_FileReference *pFileReference, char *pBuffer, size_t nBufferSize)
 The file's MIME type.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetMediaTypeW (TPtxPdf_FileReference *pFileReference, WCHAR *pBuffer, size_t nBufferSize)
 The file's MIME type.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_FileReference_GetModificationDate (TPtxPdf_FileReference *pFileReference, TPtxSys_Date *pModificationDate)
 The file's date of last modification.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetNameA (TPtxPdf_FileReference *pFileReference, char *pBuffer, size_t nBufferSize)
 The file name For embedded files, this is the name presented to the user in a the list of embedded files.
 
PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetNameW (TPtxPdf_FileReference *pFileReference, WCHAR *pBuffer, size_t nBufferSize)
 The file name For embedded files, this is the name presented to the user in a the list of embedded files.
 
PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_FileReference_GetData (TPtxPdf_FileReference *pFileReference, TPtxSys_StreamDescriptor *pOutStreamDesc)
 The file's stream.
 

Macro Definition Documentation

◆ PDFTOOLBOX_CALL

#define PDFTOOLBOX_CALL

◆ PtxPdf_Document_Open

#define PtxPdf_Document_Open   PtxPdf_Document_OpenA

◆ PtxPdf_Document_OpenWithFdf

#define PtxPdf_Document_OpenWithFdf   PtxPdf_Document_OpenWithFdfA

◆ PtxPdf_Encryption_GetOwnerPassword

#define PtxPdf_Encryption_GetOwnerPassword   PtxPdf_Encryption_GetOwnerPasswordA

◆ PtxPdf_Encryption_GetUserPassword

#define PtxPdf_Encryption_GetUserPassword   PtxPdf_Encryption_GetUserPasswordA

◆ PtxPdf_Encryption_New

#define PtxPdf_Encryption_New   PtxPdf_Encryption_NewA

◆ PtxPdf_Encryption_SetOwnerPassword

#define PtxPdf_Encryption_SetOwnerPassword   PtxPdf_Encryption_SetOwnerPasswordA

◆ PtxPdf_Encryption_SetUserPassword

#define PtxPdf_Encryption_SetUserPassword   PtxPdf_Encryption_SetUserPasswordA

◆ PtxPdf_FileReference_Create

#define PtxPdf_FileReference_Create   PtxPdf_FileReference_CreateA

◆ PtxPdf_FileReference_GetAssociationRelationship

#define PtxPdf_FileReference_GetAssociationRelationship   PtxPdf_FileReference_GetAssociationRelationshipA

◆ PtxPdf_FileReference_GetDescription

#define PtxPdf_FileReference_GetDescription   PtxPdf_FileReference_GetDescriptionA

◆ PtxPdf_FileReference_GetMediaType

#define PtxPdf_FileReference_GetMediaType   PtxPdf_FileReference_GetMediaTypeA

◆ PtxPdf_FileReference_GetName

#define PtxPdf_FileReference_GetName   PtxPdf_FileReference_GetNameA

◆ PtxPdf_FileReference_SetAssociationRelationship

#define PtxPdf_FileReference_SetAssociationRelationship   PtxPdf_FileReference_SetAssociationRelationshipA

◆ PtxPdf_Metadata_GetAuthor

#define PtxPdf_Metadata_GetAuthor   PtxPdf_Metadata_GetAuthorA

◆ PtxPdf_Metadata_GetCreator

#define PtxPdf_Metadata_GetCreator   PtxPdf_Metadata_GetCreatorA

◆ PtxPdf_Metadata_GetKeywords

#define PtxPdf_Metadata_GetKeywords   PtxPdf_Metadata_GetKeywordsA

◆ PtxPdf_Metadata_GetProducer

#define PtxPdf_Metadata_GetProducer   PtxPdf_Metadata_GetProducerA

◆ PtxPdf_Metadata_GetSubject

#define PtxPdf_Metadata_GetSubject   PtxPdf_Metadata_GetSubjectA

◆ PtxPdf_Metadata_GetTitle

#define PtxPdf_Metadata_GetTitle   PtxPdf_Metadata_GetTitleA

◆ PtxPdf_Metadata_SetAuthor

#define PtxPdf_Metadata_SetAuthor   PtxPdf_Metadata_SetAuthorA

◆ PtxPdf_Metadata_SetCreator

#define PtxPdf_Metadata_SetCreator   PtxPdf_Metadata_SetCreatorA

◆ PtxPdf_Metadata_SetKeywords

#define PtxPdf_Metadata_SetKeywords   PtxPdf_Metadata_SetKeywordsA

◆ PtxPdf_Metadata_SetSubject

#define PtxPdf_Metadata_SetSubject   PtxPdf_Metadata_SetSubjectA

◆ PtxPdf_Metadata_SetTitle

#define PtxPdf_Metadata_SetTitle   PtxPdf_Metadata_SetTitleA

◆ PtxPdf_Page_GetPageLabel

#define PtxPdf_Page_GetPageLabel   PtxPdf_Page_GetPageLabelA

Function Documentation

◆ PtxPdf_Document_Close()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_Close ( TPtxPdf_Document * pObject)

Close object.

Close disposable objects by invoking this function.

Parameters
[in]pObjectDisposable object.
Returns
TRUE if the object was closed successfully; FALSE if an error occured while closing the object. Retrieve the error code by calling Ptx_GetLastError .

◆ PtxPdf_Document_Create()

PDFTOOLBOX_EXPORT TPtxPdf_Document *PDFTOOLBOX_CALL PtxPdf_Document_Create ( const TPtxSys_StreamDescriptor * pStreamDesc,
const TPtxPdf_Conformance * pConformance,
TPtxPdf_Encryption * pEncryption )

Create a new PDF document. Documents with created with this method are writable and can be modified.

Parameters
[in,out]pStreamDescThe stream where the PDF document is stored. Both, read and write access is required.
[in]pConformanceThe required conformance level of the PDF document. Adding pages or content from incompatible documents or using incompatible features will lead to a conformance error. When using NULL, the conformance is determined automatically, based on the conformance of the input documents and the requirements of the used features. Note that for PDF/A document it is highly recommended to set an output intent using PtxPdf_Document_SetOutputIntent.
[in,out]pEncryptionthe optional encryption parameters
Returns
the newly created document instance

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:
  • ePtx_Error_IO Error writing to the stream.
  • ePtx_Error_Conformance If the conformance level is lower than 1.7 and Unicode passwords are specified. In this context "a Unicode password" is essentially one containing characters that are not in the Windows ANSI encoding (Windows Code Page 1252).

◆ PtxPdf_Document_CreateWithFdf()

PDFTOOLBOX_EXPORT TPtxPdf_Document *PDFTOOLBOX_CALL PtxPdf_Document_CreateWithFdf ( const TPtxSys_StreamDescriptor * pPdfStreamDesc,
const TPtxSys_StreamDescriptor * pFdfStreamDesc,
const TPtxPdf_Conformance * pConformance,
TPtxPdf_Encryption * pEncryption )

Create a new PDF document and an associated FDF. Documents with created with this method are writable and can be modified. When creating a document with this method, all TPtxPdfAnnots_MarkupAnnotations - created or copied - are stored as an FDF file to the pFdfStreamDesc. In the output PDF (pPdfStreamDesc), only annotations that are not TPtxPdfAnnots_MarkupAnnotations are stored.

Parameters
[in,out]pPdfStreamDescThe stream where the PDF document is stored. Both, read and write access is required. The resulting PDF document contains no TPtxPdfAnnots_MarkupAnnotations.
[in,out]pFdfStreamDescThe stream where the document's TPtxPdfAnnots_MarkupAnnotations are stored in the FDF format. Both, read and write access is required.
[in]pConformanceThe required conformance level of the PDF document. Adding pages or content from incompatible documents or using incompatible features will lead to a conformance error. When using NULL, the conformance is determined automatically, based on the conformance of the input documents and the requirements of the used features. Note that for PDF/A document it is highly recommended to set an output intent using PtxPdf_Document_SetOutputIntent.
[in,out]pEncryptionthe optional encryption parameters
Returns
the newly created document instance

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:
  • ePtx_Error_IO Error writing to the pPdfStreamDesc
  • ePtx_Error_Conformance If the conformance level is lower than 1.7 and Unicode passwords are specified. In this context "a Unicode password" is essentially one containing characters that are not in the Windows ANSI encoding (Windows Code Page 1252).

◆ PtxPdf_Document_GetAllEmbeddedFiles()

PDFTOOLBOX_EXPORT TPtxPdf_FileReferenceList *PDFTOOLBOX_CALL PtxPdf_Document_GetAllEmbeddedFiles ( TPtxPdf_Document * pDocument)

plain embedded, associated, and attached files

This read-only list contains the union of all plain embedded files, associated files, and files contained in file attachment annotations. This is the list of files contained in a PDF as presented in a PDF viewer.

This list does not support appending.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_GetAssociatedFiles()

PDFTOOLBOX_EXPORT TPtxPdf_FileReferenceList *PDFTOOLBOX_CALL PtxPdf_Document_GetAssociatedFiles ( TPtxPdf_Document * pDocument)

document-associated files

This list contains associated files, whose associated object is the document.

If the document is writable, then it is possible to append new file references to the list. Every file reference object can occur at most once in this list.

Appending to this list results in a Conformance error if the document's conformance is neither PDF/A-3 nor can be upgraded to PDF 2.0.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_GetConformance()

PDFTOOLBOX_EXPORT TPtxPdf_Conformance PDFTOOLBOX_CALL PtxPdf_Document_GetConformance ( TPtxPdf_Document * pDocument)

the claimed conformance of the document. This method only returns the claimed conformance level, the document is not validated.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_GetFormFields()

PDFTOOLBOX_EXPORT TPtxPdfForms_FieldNodeMap *PDFTOOLBOX_CALL PtxPdf_Document_GetFormFields ( TPtxPdf_Document * pDocument)

The form fields of the document This list contains all AcroForm form fields that belong to this document. Adding to this list results in an error:

  • IllegalState if the list has already been closed
  • UnsupportedOperation if the document is read-only
  • IllegalArgument
    • if the given form field node is NULL
    • if the given form field node has already been closed
    • if the given form field node does not belong to the same document as the list
    • if the given form field node has already been added to a form field node list
    • if the given form field node's identifier equals an identifier of one of the form field nodes in this list This list does not support removing elements or setting elements or clearing.
Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_GetMetadata()

PDFTOOLBOX_EXPORT TPtxPdf_Metadata *PDFTOOLBOX_CALL PtxPdf_Document_GetMetadata ( TPtxPdf_Document * pDocument)

the metadata of the document. If the document is writable, the metadata object will be writable too and all changes to the metadata object are reflected in the document.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_GetOpenDestination()

PDFTOOLBOX_EXPORT TPtxPdfNav_Destination *PDFTOOLBOX_CALL PtxPdf_Document_GetOpenDestination ( TPtxPdf_Document * pDocument)

The destination that is displayed when the document is opened.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
Returns
Retrieved value.

NULL if either an error occurred or the returned object is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.

Note
An error occurred when NULL was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_GetOutline()

The document outline, also known as "Bookmarks".

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_GetOutputIntent()

the output intent of the document. The output intent specifies a color profile that characterizes the intended output device. It is used to render device colors on devices other than the intended output device.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
Returns
Retrieved value.

NULL if either an error occurred or the returned object is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.

Note
An error occurred when NULL was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_GetPages()

PDFTOOLBOX_EXPORT TPtxPdf_PageList *PDFTOOLBOX_CALL PtxPdf_Document_GetPages ( TPtxPdf_Document * pDocument)

the pages of the document. If the document is writable, it is possible to append new pages to the end of the list.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_GetPermissions()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_GetPermissions ( TPtxPdf_Document * pDocument,
TPtxPdf_Permission * pPermissions )

The permissions in force for this document. This property is NULL if the document is not encrypted.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
[out]pPermissionsRetrieved value.
Returns
FALSE if either an error occurred or the [out] argument returns NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_GetPlainEmbeddedFiles()

PDFTOOLBOX_EXPORT TPtxPdf_FileReferenceList *PDFTOOLBOX_CALL PtxPdf_Document_GetPlainEmbeddedFiles ( TPtxPdf_Document * pDocument)

plain embedded files

This list contains plain embedded files, i.e., files that are embedded in this document without having a specific association (PtxPdf_Document_GetAssociatedFiles), and without being contained in any TPtxPdfAnnots_FileAttachment.

If the document is writable, then it is possible to append new file references to the list. Every file reference object can occur at most once in this list.

For PDF/A-3 documents, appending to this list results in a Conformance error.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_GetSignatureFields()

PDFTOOLBOX_EXPORT TPtxPdfForms_SignatureFieldList *PDFTOOLBOX_CALL PtxPdf_Document_GetSignatureFields ( TPtxPdf_Document * pDocument)

The signature fields of the document Signature fields are a special kind of form fields, that can contain digital signatures.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_GetViewerSettings()

PDFTOOLBOX_EXPORT TPtxPdfNav_ViewerSettings *PDFTOOLBOX_CALL PtxPdf_Document_GetViewerSettings ( TPtxPdf_Document * pDocument)

The settings to use when opening the document in a viewer.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_IsLinearized()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_IsLinearized ( TPtxPdf_Document * pDocument)

Whether the document is linearized.

Linearization is also known as "Fast Web View" and is a way of optimizing PDFs so they can be streamed into a client application. This helps online documents open almost instantly, without having to wait for a large document to completely download.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_OpenA()

PDFTOOLBOX_EXPORT TPtxPdf_Document *PDFTOOLBOX_CALL PtxPdf_Document_OpenA ( const TPtxSys_StreamDescriptor * pStreamDesc,
const char * szPassword )

Open a PDF document. Documents opened with this method are read-only and cannot be modified.

Parameters
[in]pStreamDescThe stream where the PDF document is stored. Read access is required.
[in]szPasswordthe password to open the PDF document
Returns
the newly created document instance

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_OpenW()

PDFTOOLBOX_EXPORT TPtxPdf_Document *PDFTOOLBOX_CALL PtxPdf_Document_OpenW ( const TPtxSys_StreamDescriptor * pStreamDesc,
const WCHAR * szPassword )

Open a PDF document. Documents opened with this method are read-only and cannot be modified.

Parameters
[in]pStreamDescThe stream where the PDF document is stored. Read access is required.
[in]szPasswordthe password to open the PDF document
Returns
the newly created document instance

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_OpenWithFdfA()

PDFTOOLBOX_EXPORT TPtxPdf_Document *PDFTOOLBOX_CALL PtxPdf_Document_OpenWithFdfA ( const TPtxSys_StreamDescriptor * pPdfStreamDesc,
const TPtxSys_StreamDescriptor * pFdfStreamDesc,
const char * szPassword )

Open a PDF document together with an FDF file. Documents opened with this method are read-only and cannot be modified.

Parameters
[in]pPdfStreamDescThe stream where the PDF document is stored. Read access is required.
[in]pFdfStreamDescThe stream where the FDF file is stored. Read access is required.
[in]szPasswordthe password to open the PDF document
Returns
the newly created document instance

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_OpenWithFdfW()

PDFTOOLBOX_EXPORT TPtxPdf_Document *PDFTOOLBOX_CALL PtxPdf_Document_OpenWithFdfW ( const TPtxSys_StreamDescriptor * pPdfStreamDesc,
const TPtxSys_StreamDescriptor * pFdfStreamDesc,
const WCHAR * szPassword )

Open a PDF document together with an FDF file. Documents opened with this method are read-only and cannot be modified.

Parameters
[in]pPdfStreamDescThe stream where the PDF document is stored. Read access is required.
[in]pFdfStreamDescThe stream where the FDF file is stored. Read access is required.
[in]szPasswordthe password to open the PDF document
Returns
the newly created document instance

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_SetMetadata()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_SetMetadata ( TPtxPdf_Document * pDocument,
TPtxPdf_Metadata * pMetadata )

the metadata of the document. If the document is writable, the metadata object will be writable too and all changes to the metadata object are reflected in the document.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
[in,out]pMetadataSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_SetOpenDestination()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_SetOpenDestination ( TPtxPdf_Document * pDocument,
TPtxPdfNav_Destination * pOpenDestination )

The destination that is displayed when the document is opened.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
[in,out]pOpenDestinationSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_SetOutputIntent()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_SetOutputIntent ( TPtxPdf_Document * pDocument,
TPtxPdfContent_IccBasedColorSpace * pOutputIntent )

the output intent of the document. The output intent specifies a color profile that characterizes the intended output device. It is used to render device colors on devices other than the intended output device.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
[in,out]pOutputIntentSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Document_SetViewerSettings()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Document_SetViewerSettings ( TPtxPdf_Document * pDocument,
TPtxPdfNav_ViewerSettings * pViewerSettings )

The settings to use when opening the document in a viewer.

Parameters
[in,out]pDocumentActs as a handle to the native object of type TPtxPdf_Document.
[in,out]pViewerSettingsSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Encryption_GetOwnerPasswordA()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Encryption_GetOwnerPasswordA ( TPtxPdf_Encryption * pEncryption,
char * pBuffer,
size_t nBufferSize )
Parameters
[in,out]pEncryptionActs as a handle to the native object of type TPtxPdf_Encryption.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_Encryption_GetOwnerPasswordW()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Encryption_GetOwnerPasswordW ( TPtxPdf_Encryption * pEncryption,
WCHAR * pBuffer,
size_t nBufferSize )
Parameters
[in,out]pEncryptionActs as a handle to the native object of type TPtxPdf_Encryption.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_Encryption_GetPermissions()

PDFTOOLBOX_EXPORT TPtxPdf_Permission PDFTOOLBOX_CALL PtxPdf_Encryption_GetPermissions ( TPtxPdf_Encryption * pEncryption)
Parameters
[in,out]pEncryptionActs as a handle to the native object of type TPtxPdf_Encryption.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_Encryption_GetUserPasswordA()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Encryption_GetUserPasswordA ( TPtxPdf_Encryption * pEncryption,
char * pBuffer,
size_t nBufferSize )
Parameters
[in,out]pEncryptionActs as a handle to the native object of type TPtxPdf_Encryption.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_Encryption_GetUserPasswordW()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Encryption_GetUserPasswordW ( TPtxPdf_Encryption * pEncryption,
WCHAR * pBuffer,
size_t nBufferSize )
Parameters
[in,out]pEncryptionActs as a handle to the native object of type TPtxPdf_Encryption.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_Encryption_NewA()

PDFTOOLBOX_EXPORT TPtxPdf_Encryption *PDFTOOLBOX_CALL PtxPdf_Encryption_NewA ( const char * szUserPassword,
const char * szOwnerPassword,
TPtxPdf_Permission iPermissions )
Parameters
[in]szUserPassword
[in]szOwnerPassword
[in]iPermissions
Returns
Handle to the newly created native object.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_Encryption_NewW()

PDFTOOLBOX_EXPORT TPtxPdf_Encryption *PDFTOOLBOX_CALL PtxPdf_Encryption_NewW ( const WCHAR * szUserPassword,
const WCHAR * szOwnerPassword,
TPtxPdf_Permission iPermissions )
Parameters
[in]szUserPassword
[in]szOwnerPassword
[in]iPermissions
Returns
Handle to the newly created native object.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_Encryption_SetOwnerPasswordA()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Encryption_SetOwnerPasswordA ( TPtxPdf_Encryption * pEncryption,
const char * szOwnerPassword )
Parameters
[in,out]pEncryptionActs as a handle to the native object of type TPtxPdf_Encryption.
[in]szOwnerPasswordSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_Encryption_SetOwnerPasswordW()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Encryption_SetOwnerPasswordW ( TPtxPdf_Encryption * pEncryption,
const WCHAR * szOwnerPassword )
Parameters
[in,out]pEncryptionActs as a handle to the native object of type TPtxPdf_Encryption.
[in]szOwnerPasswordSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_Encryption_SetPermissions()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Encryption_SetPermissions ( TPtxPdf_Encryption * pEncryption,
TPtxPdf_Permission iPermissions )
Parameters
[in,out]pEncryptionActs as a handle to the native object of type TPtxPdf_Encryption.
[in]iPermissionsSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_Encryption_SetUserPasswordA()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Encryption_SetUserPasswordA ( TPtxPdf_Encryption * pEncryption,
const char * szUserPassword )
Parameters
[in,out]pEncryptionActs as a handle to the native object of type TPtxPdf_Encryption.
[in]szUserPasswordSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_Encryption_SetUserPasswordW()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Encryption_SetUserPasswordW ( TPtxPdf_Encryption * pEncryption,
const WCHAR * szUserPassword )
Parameters
[in,out]pEncryptionActs as a handle to the native object of type TPtxPdf_Encryption.
[in]szUserPasswordSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_FileReference_Copy()

PDFTOOLBOX_EXPORT TPtxPdf_FileReference *PDFTOOLBOX_CALL PtxPdf_FileReference_Copy ( TPtxPdf_Document * pTargetDocument,
TPtxPdf_FileReference * pFileReference )

Copy a file reference object Copy a file reference object from an input document to the given pTargetDocument. The returned object is associated with the given target document but not yet part of it.

Parameters
[in,out]pTargetDocumentthe output document with which the returned object is associated
[in,out]pFileReferencea file reference object of a different document
Returns
the copied file reference, associated with the current document

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_CreateA()

PDFTOOLBOX_EXPORT TPtxPdf_FileReference *PDFTOOLBOX_CALL PtxPdf_FileReference_CreateA ( TPtxPdf_Document * pTargetDocument,
const TPtxSys_StreamDescriptor * pData,
const char * szName,
const char * szMediaType,
const char * szDescription,
const TPtxSys_Date * pModificationDate )

Create a new file reference object The newly created file reference object belongs to the document but is not (yet) used as an embedded file. The object can be added to the list of embedded files or to the list of associated files.

Parameters
[in,out]pTargetDocumentthe output document with which the returned object is associated
[in]pDataA stream of the file to be added. Read access is required.
[in]szNameThe name to be used for the embedded file. This name is presented to the user when viewing the list of embedded files.
[in]szMediaTypeThe mime type of the embedded file. Default: "application/octet-stream". Common values other than the default are "application/pdf", "application/xml", or "application/msword".
[in]szDescriptionThe description of the embedded file. This is presented to the user when viewing the list of embedded files.
[in]pModificationDateThe modify date of the file. Default: current time.
Returns
the newly created file reference object

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_CreateW()

PDFTOOLBOX_EXPORT TPtxPdf_FileReference *PDFTOOLBOX_CALL PtxPdf_FileReference_CreateW ( TPtxPdf_Document * pTargetDocument,
const TPtxSys_StreamDescriptor * pData,
const WCHAR * szName,
const WCHAR * szMediaType,
const WCHAR * szDescription,
const TPtxSys_Date * pModificationDate )

Create a new file reference object The newly created file reference object belongs to the document but is not (yet) used as an embedded file. The object can be added to the list of embedded files or to the list of associated files.

Parameters
[in,out]pTargetDocumentthe output document with which the returned object is associated
[in]pDataA stream of the file to be added. Read access is required.
[in]szNameThe name to be used for the embedded file. This name is presented to the user when viewing the list of embedded files.
[in]szMediaTypeThe mime type of the embedded file. Default: "application/octet-stream". Common values other than the default are "application/pdf", "application/xml", or "application/msword".
[in]szDescriptionThe description of the embedded file. This is presented to the user when viewing the list of embedded files.
[in]pModificationDateThe modify date of the file. Default: current time.
Returns
the newly created file reference object

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_GetAssociationRelationshipA()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetAssociationRelationshipA ( TPtxPdf_FileReference * pFileReference,
char * pBuffer,
size_t nBufferSize )

The file's association relationship This property is NULL if the file is not associated with any object. When associating a file reference with an object such as the document or a page, then this property defines the relationship between the file and the object. Typical values are:

  • "Source": used if this file is the original source material for the associated content.
  • "Data": used if this file represents information used to derive a visual presentation such as for a table or a graph.
  • "Alternative": used if this file is an alternative representation of content, for example audio.
  • "Supplement": used if this file represents a supplemental representation of the original source or data that may be more easily consumable (e.g., a MathML version of an equation).
  • "EncryptedPayload": used if this file is an encrypted payload document that should be displayed to the user if the PDF processor has the cryptographic filter needed to decrypt the document.
  • "FormData": used if this file is the data associated with form fields of this PDF.
  • "Schema": used if this file is a schema definition for the associated object.
  • "Unspecified": used when the relationship is not known.
Parameters
[in,out]pFileReferenceActs as a handle to the native object of type TPtxPdf_FileReference.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_GetAssociationRelationshipW()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetAssociationRelationshipW ( TPtxPdf_FileReference * pFileReference,
WCHAR * pBuffer,
size_t nBufferSize )

The file's association relationship This property is NULL if the file is not associated with any object. When associating a file reference with an object such as the document or a page, then this property defines the relationship between the file and the object. Typical values are:

  • "Source": used if this file is the original source material for the associated content.
  • "Data": used if this file represents information used to derive a visual presentation such as for a table or a graph.
  • "Alternative": used if this file is an alternative representation of content, for example audio.
  • "Supplement": used if this file represents a supplemental representation of the original source or data that may be more easily consumable (e.g., a MathML version of an equation).
  • "EncryptedPayload": used if this file is an encrypted payload document that should be displayed to the user if the PDF processor has the cryptographic filter needed to decrypt the document.
  • "FormData": used if this file is the data associated with form fields of this PDF.
  • "Schema": used if this file is a schema definition for the associated object.
  • "Unspecified": used when the relationship is not known.
Parameters
[in,out]pFileReferenceActs as a handle to the native object of type TPtxPdf_FileReference.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_GetData()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_FileReference_GetData ( TPtxPdf_FileReference * pFileReference,
TPtxSys_StreamDescriptor * pOutStreamDesc )

The file's stream.

Parameters
[in,out]pFileReferenceActs as a handle to the native object of type TPtxPdf_FileReference.
[out]pOutStreamDescRetrieved value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_GetDescriptionA()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetDescriptionA ( TPtxPdf_FileReference * pFileReference,
char * pBuffer,
size_t nBufferSize )

The file's description For embedded files, this is the description of the file presented to the user in the list of embedded files.

Parameters
[in,out]pFileReferenceActs as a handle to the native object of type TPtxPdf_FileReference.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_GetDescriptionW()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetDescriptionW ( TPtxPdf_FileReference * pFileReference,
WCHAR * pBuffer,
size_t nBufferSize )

The file's description For embedded files, this is the description of the file presented to the user in the list of embedded files.

Parameters
[in,out]pFileReferenceActs as a handle to the native object of type TPtxPdf_FileReference.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_GetMediaTypeA()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetMediaTypeA ( TPtxPdf_FileReference * pFileReference,
char * pBuffer,
size_t nBufferSize )

The file's MIME type.

Parameters
[in,out]pFileReferenceActs as a handle to the native object of type TPtxPdf_FileReference.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_GetMediaTypeW()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetMediaTypeW ( TPtxPdf_FileReference * pFileReference,
WCHAR * pBuffer,
size_t nBufferSize )

The file's MIME type.

Parameters
[in,out]pFileReferenceActs as a handle to the native object of type TPtxPdf_FileReference.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_GetModificationDate()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_FileReference_GetModificationDate ( TPtxPdf_FileReference * pFileReference,
TPtxSys_Date * pModificationDate )

The file's date of last modification.

Parameters
[in,out]pFileReferenceActs as a handle to the native object of type TPtxPdf_FileReference.
[out]pModificationDateRetrieved value.
Returns
FALSE if either an error occurred or the [out] argument returns NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_GetNameA()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetNameA ( TPtxPdf_FileReference * pFileReference,
char * pBuffer,
size_t nBufferSize )

The file name For embedded files, this is the name presented to the user in a the list of embedded files.

Parameters
[in,out]pFileReferenceActs as a handle to the native object of type TPtxPdf_FileReference.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if there is an error.
Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_GetNameW()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_FileReference_GetNameW ( TPtxPdf_FileReference * pFileReference,
WCHAR * pBuffer,
size_t nBufferSize )

The file name For embedded files, this is the name presented to the user in a the list of embedded files.

Parameters
[in,out]pFileReferenceActs as a handle to the native object of type TPtxPdf_FileReference.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if there is an error.
Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_SetAssociationRelationshipA()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_FileReference_SetAssociationRelationshipA ( TPtxPdf_FileReference * pFileReference,
const char * szAssociationRelationship )

The file's association relationship This property is NULL if the file is not associated with any object. When associating a file reference with an object such as the document or a page, then this property defines the relationship between the file and the object. Typical values are:

  • "Source": used if this file is the original source material for the associated content.
  • "Data": used if this file represents information used to derive a visual presentation such as for a table or a graph.
  • "Alternative": used if this file is an alternative representation of content, for example audio.
  • "Supplement": used if this file represents a supplemental representation of the original source or data that may be more easily consumable (e.g., a MathML version of an equation).
  • "EncryptedPayload": used if this file is an encrypted payload document that should be displayed to the user if the PDF processor has the cryptographic filter needed to decrypt the document.
  • "FormData": used if this file is the data associated with form fields of this PDF.
  • "Schema": used if this file is a schema definition for the associated object.
  • "Unspecified": used when the relationship is not known.
Parameters
[in,out]pFileReferenceActs as a handle to the native object of type TPtxPdf_FileReference.
[in]szAssociationRelationshipSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReference_SetAssociationRelationshipW()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_FileReference_SetAssociationRelationshipW ( TPtxPdf_FileReference * pFileReference,
const WCHAR * szAssociationRelationship )

The file's association relationship This property is NULL if the file is not associated with any object. When associating a file reference with an object such as the document or a page, then this property defines the relationship between the file and the object. Typical values are:

  • "Source": used if this file is the original source material for the associated content.
  • "Data": used if this file represents information used to derive a visual presentation such as for a table or a graph.
  • "Alternative": used if this file is an alternative representation of content, for example audio.
  • "Supplement": used if this file represents a supplemental representation of the original source or data that may be more easily consumable (e.g., a MathML version of an equation).
  • "EncryptedPayload": used if this file is an encrypted payload document that should be displayed to the user if the PDF processor has the cryptographic filter needed to decrypt the document.
  • "FormData": used if this file is the data associated with form fields of this PDF.
  • "Schema": used if this file is a schema definition for the associated object.
  • "Unspecified": used when the relationship is not known.
Parameters
[in,out]pFileReferenceActs as a handle to the native object of type TPtxPdf_FileReference.
[in]szAssociationRelationshipSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReferenceList_Add()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_FileReferenceList_Add ( TPtxPdf_FileReferenceList * pFileReferenceList,
TPtxPdf_FileReference * pFileReference )

Add an element to the end of the list.

Parameters
[in,out]pFileReferenceListActs as a handle to the native object of type TPtxPdf_FileReferenceList.
[in,out]pFileReference
Returns
May indicate an error in certain scenarios. For further information see the note section below.
Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReferenceList_Get()

PDFTOOLBOX_EXPORT TPtxPdf_FileReference *PDFTOOLBOX_CALL PtxPdf_FileReferenceList_Get ( TPtxPdf_FileReferenceList * pFileReferenceList,
int iIndex )

Returns the element at the specified position in the given list.

Parameters
[in,out]pFileReferenceListActs as a handle to the native object of type TPtxPdf_FileReferenceList.
[in]iIndex
Returns
NULL if there is an error.
Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_FileReferenceList_GetCount()

PDFTOOLBOX_EXPORT int PDFTOOLBOX_CALL PtxPdf_FileReferenceList_GetCount ( TPtxPdf_FileReferenceList * pFileReferenceList)

Get the number of elements in the list.

Parameters
[in,out]pFileReferenceListActs as a handle to the native object of type TPtxPdf_FileReferenceList.
Returns
May indicate an error in certain scenarios. For further information see the note section below.
Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_Copy()

PDFTOOLBOX_EXPORT TPtxPdf_Metadata *PDFTOOLBOX_CALL PtxPdf_Metadata_Copy ( TPtxPdf_Document * pTargetDocument,
TPtxPdf_Metadata * pMetadata )

Copy a metadata object Copy a metadata object from an input document to the given pTargetDocument. The returned object is associated with the target document but not (yet) used as the document metadata. The object can be used either as document metadata using PtxPdf_Document_SetMetadata or as page metadata using PtxPdf_Page_SetMetadata.

Parameters
[in,out]pTargetDocumentthe output document with which the returned object is associated
[in,out]pMetadatathe metadata of a different document
Returns
a metadata object with the same content, but associated with the current document.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_Create()

PDFTOOLBOX_EXPORT TPtxPdf_Metadata *PDFTOOLBOX_CALL PtxPdf_Metadata_Create ( TPtxPdf_Document * pTargetDocument,
const TPtxSys_StreamDescriptor * pXmp )

Create a new metadata object The newly created metadata object is associated with the target document but not (yet) used as the document metadata. The object can be used either as document metadata using PtxPdf_Document_SetMetadata or as page metadata using PtxPdf_Page_SetMetadata.

Parameters
[in,out]pTargetDocumentthe output document with which the returned object is associated
[in]pXmpA stream containing an XMP file or NULL to create an empty metadata object.
Returns
the newly created metadata object

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetAuthorA()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetAuthorA ( TPtxPdf_Metadata * pMetadata,
char * pBuffer,
size_t nBufferSize )

The name of the person who created the document or resource. This property corresponds to the "dc:creator" entry in the XMP metadata and to the "Author" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetAuthorW()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetAuthorW ( TPtxPdf_Metadata * pMetadata,
WCHAR * pBuffer,
size_t nBufferSize )

The name of the person who created the document or resource. This property corresponds to the "dc:creator" entry in the XMP metadata and to the "Author" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetCreationDate()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_GetCreationDate ( TPtxPdf_Metadata * pMetadata,
TPtxSys_Date * pCreationDate )

The date and time the document or resource was originally created. This property corresponds to the "xmp:CreateDate" entry in the XMP metadata and to the "CreationDate" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pCreationDateRetrieved value.
Returns
FALSE if either an error occurred or the [out] argument returns NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetCreatorA()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetCreatorA ( TPtxPdf_Metadata * pMetadata,
char * pBuffer,
size_t nBufferSize )

The original application that created the document.

The name of the first known tool used to create the document or resource.

This property corresponds to the "xmp:CreatorTool" entry in the XMP metadata and to the "Creator" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetCreatorW()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetCreatorW ( TPtxPdf_Metadata * pMetadata,
WCHAR * pBuffer,
size_t nBufferSize )

The original application that created the document.

The name of the first known tool used to create the document or resource.

This property corresponds to the "xmp:CreatorTool" entry in the XMP metadata and to the "Creator" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetCustomEntries()

PDFTOOLBOX_EXPORT TPtx_StringMap *PDFTOOLBOX_CALL PtxPdf_Metadata_GetCustomEntries ( TPtxPdf_Metadata * pMetadata)

The custom entries in the document information dictionary.

The standard entries "Title", "Author", "Subject", "Keywords", "CreationDate", "ModDate", "Creator", "Producer" and "Trapped" are not included in the map. Any attempt to set a standard entry through this map will result in an error. To get or set standard entries use the corresponding properties instead.

Note: The document information dictionary has been superseded by XMP metadata and is deprecated in PDF 2.0.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetKeywordsA()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetKeywordsA ( TPtxPdf_Metadata * pMetadata,
char * pBuffer,
size_t nBufferSize )

Keywords associated with the document or resource.

Keywords can be separated by:

  • carriage return / line feed
  • comma
  • semicolon
  • tab
  • double space

This property corresponds to the "pdf:Keywords" entry in the XMP metadata and to the "Keywords" entry in the document information dictionary.

Setting this property also sets the XMP property dc:subject accordingly.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetKeywordsW()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetKeywordsW ( TPtxPdf_Metadata * pMetadata,
WCHAR * pBuffer,
size_t nBufferSize )

Keywords associated with the document or resource.

Keywords can be separated by:

  • carriage return / line feed
  • comma
  • semicolon
  • tab
  • double space

This property corresponds to the "pdf:Keywords" entry in the XMP metadata and to the "Keywords" entry in the document information dictionary.

Setting this property also sets the XMP property dc:subject accordingly.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetModificationDate()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_GetModificationDate ( TPtxPdf_Metadata * pMetadata,
TPtxSys_Date * pModificationDate )

The date and time the document or resource was most recently modified. This property corresponds to the "xmp:ModifyDate" entry in the XMP metadata and to the "ModDate" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pModificationDateRetrieved value.
Returns
FALSE if either an error occurred or the [out] argument returns NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetProducerA()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetProducerA ( TPtxPdf_Metadata * pMetadata,
char * pBuffer,
size_t nBufferSize )

The application that created the PDF.

If the document was converted to PDF from another format, the name of the PDF processor that converted it to PDF.

This property corresponds to the "pdf:Producer" entry in the XMP metadata and to the "Producer" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetProducerW()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetProducerW ( TPtxPdf_Metadata * pMetadata,
WCHAR * pBuffer,
size_t nBufferSize )

The application that created the PDF.

If the document was converted to PDF from another format, the name of the PDF processor that converted it to PDF.

This property corresponds to the "pdf:Producer" entry in the XMP metadata and to the "Producer" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetSubjectA()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetSubjectA ( TPtxPdf_Metadata * pMetadata,
char * pBuffer,
size_t nBufferSize )

The subject of the document or resource. This property corresponds to the "dc:description" entry in the XMP metadata and to the "Subject" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetSubjectW()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetSubjectW ( TPtxPdf_Metadata * pMetadata,
WCHAR * pBuffer,
size_t nBufferSize )

The subject of the document or resource. This property corresponds to the "dc:description" entry in the XMP metadata and to the "Subject" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetTitleA()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetTitleA ( TPtxPdf_Metadata * pMetadata,
char * pBuffer,
size_t nBufferSize )

The title of the document or resource. This property corresponds to the "dc:title" entry in the XMP metadata and to the "Title" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetTitleW()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Metadata_GetTitleW ( TPtxPdf_Metadata * pMetadata,
WCHAR * pBuffer,
size_t nBufferSize )

The title of the document or resource. This property corresponds to the "dc:title" entry in the XMP metadata and to the "Title" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if either an error occurred or the returned buffer is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when 0 was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_GetXmp()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_GetXmp ( TPtxPdf_Metadata * pMetadata,
TPtxSys_StreamDescriptor * pOutStreamDesc )

The XMP metadata.

The XMP metadata stream or NULL if there is none.

The stream is read-only. To set the XMP stream of a metadata object use the method Document.CreateMetadata instead.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[out]pOutStreamDescRetrieved value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_SetAuthorA()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetAuthorA ( TPtxPdf_Metadata * pMetadata,
const char * szAuthor )

The name of the person who created the document or resource. This property corresponds to the "dc:creator" entry in the XMP metadata and to the "Author" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[in]szAuthorSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_SetAuthorW()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetAuthorW ( TPtxPdf_Metadata * pMetadata,
const WCHAR * szAuthor )

The name of the person who created the document or resource. This property corresponds to the "dc:creator" entry in the XMP metadata and to the "Author" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[in]szAuthorSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_SetCreationDate()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetCreationDate ( TPtxPdf_Metadata * pMetadata,
const TPtxSys_Date * pCreationDate )

The date and time the document or resource was originally created. This property corresponds to the "xmp:CreateDate" entry in the XMP metadata and to the "CreationDate" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[in]pCreationDateSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_SetCreatorA()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetCreatorA ( TPtxPdf_Metadata * pMetadata,
const char * szCreator )

The original application that created the document.

The name of the first known tool used to create the document or resource.

This property corresponds to the "xmp:CreatorTool" entry in the XMP metadata and to the "Creator" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[in]szCreatorSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_SetCreatorW()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetCreatorW ( TPtxPdf_Metadata * pMetadata,
const WCHAR * szCreator )

The original application that created the document.

The name of the first known tool used to create the document or resource.

This property corresponds to the "xmp:CreatorTool" entry in the XMP metadata and to the "Creator" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[in]szCreatorSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_SetKeywordsA()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetKeywordsA ( TPtxPdf_Metadata * pMetadata,
const char * szKeywords )

Keywords associated with the document or resource.

Keywords can be separated by:

  • carriage return / line feed
  • comma
  • semicolon
  • tab
  • double space

This property corresponds to the "pdf:Keywords" entry in the XMP metadata and to the "Keywords" entry in the document information dictionary.

Setting this property also sets the XMP property dc:subject accordingly.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[in]szKeywordsSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_SetKeywordsW()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetKeywordsW ( TPtxPdf_Metadata * pMetadata,
const WCHAR * szKeywords )

Keywords associated with the document or resource.

Keywords can be separated by:

  • carriage return / line feed
  • comma
  • semicolon
  • tab
  • double space

This property corresponds to the "pdf:Keywords" entry in the XMP metadata and to the "Keywords" entry in the document information dictionary.

Setting this property also sets the XMP property dc:subject accordingly.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[in]szKeywordsSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_SetSubjectA()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetSubjectA ( TPtxPdf_Metadata * pMetadata,
const char * szSubject )

The subject of the document or resource. This property corresponds to the "dc:description" entry in the XMP metadata and to the "Subject" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[in]szSubjectSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_SetSubjectW()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetSubjectW ( TPtxPdf_Metadata * pMetadata,
const WCHAR * szSubject )

The subject of the document or resource. This property corresponds to the "dc:description" entry in the XMP metadata and to the "Subject" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[in]szSubjectSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_SetTitleA()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetTitleA ( TPtxPdf_Metadata * pMetadata,
const char * szTitle )

The title of the document or resource. This property corresponds to the "dc:title" entry in the XMP metadata and to the "Title" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[in]szTitleSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Metadata_SetTitleW()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Metadata_SetTitleW ( TPtxPdf_Metadata * pMetadata,
const WCHAR * szTitle )

The title of the document or resource. This property corresponds to the "dc:title" entry in the XMP metadata and to the "Title" entry in the document information dictionary.

Parameters
[in,out]pMetadataActs as a handle to the native object of type TPtxPdf_Metadata.
[in]szTitleSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_Copy()

PDFTOOLBOX_EXPORT TPtxPdf_Page *PDFTOOLBOX_CALL PtxPdf_Page_Copy ( TPtxPdf_Document * pTargetDocument,
TPtxPdf_Page * pPage,
TPtxPdf_PageCopyOptions * pOptions )

Copy a page Copy a page object from an input document to the given pTargetDocument. The returned object is associated with the given target document but not yet part of it. It can be appended to the document's page list.

Parameters
[in,out]pTargetDocumentthe output document with which the returned object is associated
[in,out]pPagea page of a different document
[in,out]pOptionsthe copy options
Returns
the copied page, associated with the current document.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_Create()

PDFTOOLBOX_EXPORT TPtxPdf_Page *PDFTOOLBOX_CALL PtxPdf_Page_Create ( TPtxPdf_Document * pTargetDocument,
const TPtxGeomReal_Size * pSize )

Create an empty page The page is associated with the given target document but not yet part of it. It can be appended to the document's page list.

Parameters
[in,out]pTargetDocumentthe output document with which the returned object is associated
[in]pSizethe page size
Returns
the newly created page object

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_GetAnnotations()

the list of this page's annotations. Adding to this list results in an error:

  • IllegalState if the list has already been closed
  • UnsupportedOperation if the document is read-only
  • IllegalArgument
    • if the given annotation is NULL
    • if the given annotation object has already been closed
    • if the given annotation does not belong to the same document as the list
    • if the given annotation is already associated with a page This list does not support removing or setting elements or clearing.
Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_GetArtBox()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_GetArtBox ( TPtxPdf_Page * pPage,
TPtxGeomReal_Rectangle * pArtBox )

The art box of the page.

The art box (PDF 1.3) defines the extent of the page's meaningful content (including potential white-space) as intended by the page’s creator. The default value is the page's crop box.

This property is NULL if the page contains no explicit art box.

Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
[out]pArtBoxRetrieved value.
Returns
FALSE if either an error occurred or the [out] argument returns NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_GetBleedBox()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_GetBleedBox ( TPtxPdf_Page * pPage,
TPtxGeomReal_Rectangle * pBleedBox )

The bleed box of the page.

The bleed box (PDF 1.3) defines the region to which the contents of the page shall be clipped when output in a production environment. This may include any extra bleed area needed to accommodate the physical limitations of cutting, folding, and trimming equipment. The actual printed page may include printing marks that fall outside the bleed box. The default value is the page's crop box.

This property is NULL if the page contains no explicit bleed box.

Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
[out]pBleedBoxRetrieved value.
Returns
FALSE if either an error occurred or the [out] argument returns NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_GetContent()

the page content. If the page is writable, the content object can be used to apply new content on the page, for example overlays or underlays.

Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_GetLinks()

the list of this page's links. Adding to this list results in an error:

  • IllegalState if the list has already been closed
  • UnsupportedOperation if the document is read-only
  • IllegalArgument
    • if the given link is NULL
    • if the given link object has already been closed
    • if the given link does not belong to the same document as the list
    • if the given link is already associated with a page This list does not support removing or setting elements or clearing.
Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_GetMediaBox()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_GetMediaBox ( TPtxPdf_Page * pPage,
TPtxGeomReal_Rectangle * pMediaBox )

The media box of the page.

The media box defines the boundaries of the physical medium on which the page is to be printed. It may include any extended area surrounding the finished page for bleed, printing marks, or other such purposes. It may also include areas close to the edges of the medium that cannot be marked because of physical limitations of the output device. Content falling outside this boundary may safely be discarded without affecting the meaning of the PDF file.

This property cannot be NULL.

Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
[out]pMediaBoxRetrieved value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_GetMetadata()

PDFTOOLBOX_EXPORT TPtxPdf_Metadata *PDFTOOLBOX_CALL PtxPdf_Page_GetMetadata ( TPtxPdf_Page * pPage)

the metadata of the page.

If the document is writable, the metadata object will be writable too and all changes to the metadata object are reflected in the document.

This property is NULL if the page has not metadata.

Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
Returns
Retrieved value.

NULL if either an error occurred or the returned object is actually NULL. To determine if an error has occurred, check the error code as described in the note section below.

Note
An error occurred when NULL was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_GetPageLabelA()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Page_GetPageLabelA ( TPtxPdf_Page * pPage,
char * pBuffer,
size_t nBufferSize )

Page label.

The label for this page. A page does not have to have a label and if it doesn't this property will be an empty string.

If it exists, a page label is designed to replace the page number in visual presentations and consists of an optional prefix and a number. Number can be in one of several styles (arabic, Roman, alphabetic) and starts at an arbitrary number for a range of pages.

Page labels are used to set distinct names or numbers, most often for preface, appendices and similar sections of the document.

Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if there is an error.
Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_GetPageLabelW()

PDFTOOLBOX_EXPORT size_t PDFTOOLBOX_CALL PtxPdf_Page_GetPageLabelW ( TPtxPdf_Page * pPage,
WCHAR * pBuffer,
size_t nBufferSize )

Page label.

The label for this page. A page does not have to have a label and if it doesn't this property will be an empty string.

If it exists, a page label is designed to replace the page number in visual presentations and consists of an optional prefix and a number. Number can be in one of several styles (arabic, Roman, alphabetic) and starts at an arbitrary number for a range of pages.

Page labels are used to set distinct names or numbers, most often for preface, appendices and similar sections of the document.

Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
[out]pBufferRetrieved value. To determine the required buffer size, the function has to be called with NULL. The return value of this function specifies the buffer size.
[in]nBufferSizeThe buffer size of the retrieved string pBuffer.
Returns
The amount of data written to the buffer pBuffer. 0 if there is an error.
Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_GetSize()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_GetSize ( TPtxPdf_Page * pPage,
TPtxGeomReal_Size * pSize )

the visible size of the page (crop box).

The page size corresponds to the size of the crop box. Since all coordinates are normalized to the origin of the crop box, the normalized origin of the crop box is always (0,0) and thus only the size is required.

The crop box defines the region to which the contents of the page shall be clipped (cropped) when displayed or printed. Unlike the other boxes, the crop box has no defined meaning in terms of physical page geometry or intended use; it merely imposes clipping on the page contents. However, in the absence of additional information (such as imposition instructions specified in a JDF job ticket), the crop box determines how the page's contents shall be positioned on the output medium. The default value is the page's media box.

This property cannot be NULL.

Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
[out]pSizeRetrieved value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_GetTrimBox()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_GetTrimBox ( TPtxPdf_Page * pPage,
TPtxGeomReal_Rectangle * pTrimBox )

The trim box of the page.

The trim box (PDF 1.3) defines the intended dimensions of the finished page after trimming. It may be smaller than the media box to allow for production-related content, such as printing instructions, cut marks, or colour bars. The default value is the page's crop box.

This property is NULL if the page contains no explicit trim box.

Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
[out]pTrimBoxRetrieved value.
Returns
FALSE if either an error occurred or the [out] argument returns NULL. To determine if an error has occurred, check the error code as described in the note section below.
Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_GetWidgets()

the list of this page's form field widgets. Adding to this list results in an error:

  • IllegalState if the list has already been closed
  • UnsupportedOperation if the document is read-only
  • IllegalArgument
    • if the given widget is NULL
    • if the given widget object has already been closed
    • if the given widget does not belong to the same document as the list
    • if the given widget is already associated with a page This list does not support removing or setting elements or clearing.
Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
Returns
Retrieved value.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_Rotate()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_Rotate ( TPtxPdf_Page * pPage,
TPtxGeom_Rotation iRotate )

Rotate the page by a multiple of 90 degrees.

Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
[in]iRotatethe desired rotation
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_SetMetadata()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_SetMetadata ( TPtxPdf_Page * pPage,
TPtxPdf_Metadata * pMetadata )

the metadata of the page.

If the document is writable, the metadata object will be writable too and all changes to the metadata object are reflected in the document.

This property is NULL if the page has not metadata.

Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
[in,out]pMetadataSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_Page_UpdateSize()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_Page_UpdateSize ( TPtxPdf_Page * pPage,
const TPtxGeomReal_Rectangle * pRectangle )

Update the page size to a specified rectangle. Note that all page-related coordinates are normalized to the crop box of the page. Updating the page size thus changes the coordinate system, rendering all previously extracted coordinates invalid.

Parameters
[in,out]pPageActs as a handle to the native object of type TPtxPdf_Page.
[in]pRectanglethe rectangle to update the page size to.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_PageCopyOptions_GetAnnotations()

PDFTOOLBOX_EXPORT TPtxPdf_CopyStrategy PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetAnnotations ( TPtxPdf_PageCopyOptions * pPageCopyOptions)

Copy strategy for annotations.

Specifies how interactive annotations (like sticky notes or text highlights) are treated when copying a page. This does not include links, form fields and signature fields which are not considered annotations in this products.

Default value: ePtxPdf_CopyStrategy_Copy

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_GetCopyAssociatedFiles()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetCopyAssociatedFiles ( TPtxPdf_PageCopyOptions * pPageCopyOptions)

Copy associated files.

Specifies whether embedded files associated with a page or any of its subobjects are also copied when copying the page.

Default value: TRUE

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_GetCopyLogicalStructure()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetCopyLogicalStructure ( TPtxPdf_PageCopyOptions * pPageCopyOptions)

Copy the logical structure and tagging information.

Specifies whether the logical structure and tagging information associated with a page or its content is also copied when copying the page.

This is required if the target document conformance is PDF/A Level a.

Default value: TRUE

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_GetCopyOutlineItems()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetCopyOutlineItems ( TPtxPdf_PageCopyOptions * pPageCopyOptions)

Copy outline items (bookmarks).

Specifies whether outline items (also known as bookmarks) pointing to the copied page should be copied to the target document automatically.

Default value: TRUE

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_GetFormFieldConflictResolution()

PDFTOOLBOX_EXPORT TPtxPdf_NameConflictResolution PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetFormFieldConflictResolution ( TPtxPdf_PageCopyOptions * pPageCopyOptions)

Resolution of conflicting form field names.

Form field of different files can have the same name (identifier). This property specifies how name conflicts are resolved, when copying pages from multiple source files.

Default value: ePtxPdf_NameConflictResolution_Merge

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_GetFormFields()

PDFTOOLBOX_EXPORT TPtxPdfForms_FormFieldCopyStrategy PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetFormFields ( TPtxPdf_PageCopyOptions * pPageCopyOptions)

Copy strategy for form fields and widgets.

Specifies how form fields and widgets are treated when copying a page.

Default value: ePtxPdfForms_FormFieldCopyStrategy_Copy

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_GetLinks()

PDFTOOLBOX_EXPORT TPtxPdf_CopyStrategy PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetLinks ( TPtxPdf_PageCopyOptions * pPageCopyOptions)

Copy strategy for links.

Specifies how links (document internal and external links) are treated when copying a page.

Default value: ePtxPdf_CopyStrategy_Copy

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_GetNamedDestinations()

PDFTOOLBOX_EXPORT TPtxPdfNav_NamedDestinationCopyStrategy PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetNamedDestinations ( TPtxPdf_PageCopyOptions * pPageCopyOptions)

Copy strategy for named destinations.

Specify whether named destinations are resolved when copying a page.

Default value: ePtxPdfNav_NamedDestinationCopyStrategy_Copy

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_GetOcgConflictResolution()

PDFTOOLBOX_EXPORT TPtxPdf_NameConflictResolution PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetOcgConflictResolution ( TPtxPdf_PageCopyOptions * pPageCopyOptions)
Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.
Deprecated
Deprecated in Version 3.3. Setting this property has no effect. When copying pages from multiple documents, layers (optional content groups, OCG) are always merged.

◆ PtxPdf_PageCopyOptions_GetOptimizeResources()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetOptimizeResources ( TPtxPdf_PageCopyOptions * pPageCopyOptions)

Find and merge redundant resources.

Find and merge redundant resources such as fonts and images. This can lead to much smaller files, especially when copying pages from multiple similar source files. However it also decreases performance.

Default value: TRUE

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_GetSignedSignatures()

PDFTOOLBOX_EXPORT TPtxPdf_RemovalStrategy PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetSignedSignatures ( TPtxPdf_PageCopyOptions * pPageCopyOptions)

Removal strategy for signed signature fields.

Signed digital signatures are always invalidated when copying a page and therefore have to be removed. This property specifies, whether the visual representation of the signature is preserved.

Default value: ePtxPdf_RemovalStrategy_Remove

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_GetUnsignedSignatures()

PDFTOOLBOX_EXPORT TPtxPdf_CopyStrategy PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_GetUnsignedSignatures ( TPtxPdf_PageCopyOptions * pPageCopyOptions)

Copy strategy for unsigned signature fields.

Specifies how signature fields are treated, that are not yet signed.

Default value: ePtxPdf_CopyStrategy_Copy

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
Returns
Retrieved value.

May indicate an error in certain scenarios. For further information see the note section below.

Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_New()

PDFTOOLBOX_EXPORT TPtxPdf_PageCopyOptions *PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_New ( void )
Returns
Handle to the newly created native object.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_SetAnnotations()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetAnnotations ( TPtxPdf_PageCopyOptions * pPageCopyOptions,
TPtxPdf_CopyStrategy iAnnotations )

Copy strategy for annotations.

Specifies how interactive annotations (like sticky notes or text highlights) are treated when copying a page. This does not include links, form fields and signature fields which are not considered annotations in this products.

Default value: ePtxPdf_CopyStrategy_Copy

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
[in]iAnnotationsSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_SetCopyAssociatedFiles()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetCopyAssociatedFiles ( TPtxPdf_PageCopyOptions * pPageCopyOptions,
BOOL bCopyAssociatedFiles )

Copy associated files.

Specifies whether embedded files associated with a page or any of its subobjects are also copied when copying the page.

Default value: TRUE

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
[in]bCopyAssociatedFilesSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_SetCopyLogicalStructure()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetCopyLogicalStructure ( TPtxPdf_PageCopyOptions * pPageCopyOptions,
BOOL bCopyLogicalStructure )

Copy the logical structure and tagging information.

Specifies whether the logical structure and tagging information associated with a page or its content is also copied when copying the page.

This is required if the target document conformance is PDF/A Level a.

Default value: TRUE

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
[in]bCopyLogicalStructureSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_SetCopyOutlineItems()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetCopyOutlineItems ( TPtxPdf_PageCopyOptions * pPageCopyOptions,
BOOL bCopyOutlineItems )

Copy outline items (bookmarks).

Specifies whether outline items (also known as bookmarks) pointing to the copied page should be copied to the target document automatically.

Default value: TRUE

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
[in]bCopyOutlineItemsSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_SetFormFieldConflictResolution()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetFormFieldConflictResolution ( TPtxPdf_PageCopyOptions * pPageCopyOptions,
TPtxPdf_NameConflictResolution iFormFieldConflictResolution )

Resolution of conflicting form field names.

Form field of different files can have the same name (identifier). This property specifies how name conflicts are resolved, when copying pages from multiple source files.

Default value: ePtxPdf_NameConflictResolution_Merge

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
[in]iFormFieldConflictResolutionSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_SetFormFields()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetFormFields ( TPtxPdf_PageCopyOptions * pPageCopyOptions,
TPtxPdfForms_FormFieldCopyStrategy iFormFields )

Copy strategy for form fields and widgets.

Specifies how form fields and widgets are treated when copying a page.

Default value: ePtxPdfForms_FormFieldCopyStrategy_Copy

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
[in]iFormFieldsSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_SetLinks()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetLinks ( TPtxPdf_PageCopyOptions * pPageCopyOptions,
TPtxPdf_CopyStrategy iLinks )

Copy strategy for links.

Specifies how links (document internal and external links) are treated when copying a page.

Default value: ePtxPdf_CopyStrategy_Copy

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
[in]iLinksSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_SetNamedDestinations()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetNamedDestinations ( TPtxPdf_PageCopyOptions * pPageCopyOptions,
TPtxPdfNav_NamedDestinationCopyStrategy iNamedDestinations )

Copy strategy for named destinations.

Specify whether named destinations are resolved when copying a page.

Default value: ePtxPdfNav_NamedDestinationCopyStrategy_Copy

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
[in]iNamedDestinationsSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_SetOcgConflictResolution()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetOcgConflictResolution ( TPtxPdf_PageCopyOptions * pPageCopyOptions,
TPtxPdf_NameConflictResolution iOcgConflictResolution )
Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
[in]iOcgConflictResolutionSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.
Deprecated
Deprecated in Version 3.3. Setting this property has no effect. When copying pages from multiple documents, layers (optional content groups, OCG) are always merged.

◆ PtxPdf_PageCopyOptions_SetOptimizeResources()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetOptimizeResources ( TPtxPdf_PageCopyOptions * pPageCopyOptions,
BOOL bOptimizeResources )

Find and merge redundant resources.

Find and merge redundant resources such as fonts and images. This can lead to much smaller files, especially when copying pages from multiple similar source files. However it also decreases performance.

Default value: TRUE

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
[in]bOptimizeResourcesSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_SetSignedSignatures()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetSignedSignatures ( TPtxPdf_PageCopyOptions * pPageCopyOptions,
TPtxPdf_RemovalStrategy iSignedSignatures )

Removal strategy for signed signature fields.

Signed digital signatures are always invalidated when copying a page and therefore have to be removed. This property specifies, whether the visual representation of the signature is preserved.

Default value: ePtxPdf_RemovalStrategy_Remove

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
[in]iSignedSignaturesSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageCopyOptions_SetUnsignedSignatures()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageCopyOptions_SetUnsignedSignatures ( TPtxPdf_PageCopyOptions * pPageCopyOptions,
TPtxPdf_CopyStrategy iUnsignedSignatures )

Copy strategy for unsigned signature fields.

Specifies how signature fields are treated, that are not yet signed.

Default value: ePtxPdf_CopyStrategy_Copy

Parameters
[in,out]pPageCopyOptionsActs as a handle to the native object of type TPtxPdf_PageCopyOptions.
[in]iUnsignedSignaturesSet value.
Returns
TRUE if the operation is successful; FALSE if there is an error.
Note
An error occurred when FALSE was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage.

◆ PtxPdf_PageList_Add()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageList_Add ( TPtxPdf_PageList * pPageList,
TPtxPdf_Page * pPage )

Add an element to the end of the list.

Parameters
[in,out]pPageListActs as a handle to the native object of type TPtxPdf_PageList.
[in,out]pPage
Returns
May indicate an error in certain scenarios. For further information see the note section below.
Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_PageList_AddRange()

PDFTOOLBOX_EXPORT BOOL PDFTOOLBOX_CALL PtxPdf_PageList_AddRange ( TPtxPdf_PageList * pPageList,
TPtxPdf_PageList * pInput )

Add range of elements to th end of the list.

Parameters
[in,out]pPageListActs as a handle to the native object of type TPtxPdf_PageList.
[in,out]pInput
Returns
May indicate an error in certain scenarios. For further information see the note section below.
Note
An error occurred when FALSE was returned and the error code returned by Ptx_GetLastError is different from ePtx_Error_Success. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_PageList_Copy()

PDFTOOLBOX_EXPORT TPtxPdf_PageList *PDFTOOLBOX_CALL PtxPdf_PageList_Copy ( TPtxPdf_Document * pTargetDocument,
TPtxPdf_PageList * pPageList,
TPtxPdf_PageCopyOptions * pOptions )

Copy a page list Copy pages from an input document to the given pTargetDocument. The returned list is associated with the given target document but not yet part of it. It can be appended to the document's page list.

Parameters
[in,out]pTargetDocumentthe output document with which the returned object is associated
[in,out]pPageLista page list of a different document
[in,out]pOptionsthe copy options
Returns
the copied page list, associated with the target document.

NULL if there is an error.

Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_PageList_Get()

PDFTOOLBOX_EXPORT TPtxPdf_Page *PDFTOOLBOX_CALL PtxPdf_PageList_Get ( TPtxPdf_PageList * pPageList,
int iIndex )

Returns the element at the specified position in the given list.

Parameters
[in,out]pPageListActs as a handle to the native object of type TPtxPdf_PageList.
[in]iIndex
Returns
NULL if there is an error.
Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_PageList_GetCount()

PDFTOOLBOX_EXPORT int PDFTOOLBOX_CALL PtxPdf_PageList_GetCount ( TPtxPdf_PageList * pPageList)

Get the number of elements in the list.

Parameters
[in,out]pPageListActs as a handle to the native object of type TPtxPdf_PageList.
Returns
May indicate an error in certain scenarios. For further information see the note section below.
Note
An error occurred when 0 was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes:

◆ PtxPdf_PageList_GetRange()

PDFTOOLBOX_EXPORT TPtxPdf_PageList *PDFTOOLBOX_CALL PtxPdf_PageList_GetRange ( TPtxPdf_PageList * pPageList,
int iIndex,
int iCount )

Get range of elements.

Parameters
[in,out]pPageListActs as a handle to the native object of type TPtxPdf_PageList.
[in]iIndex
[in]iCount
Returns
NULL if there is an error.
Note
An error occurred when NULL was returned. Retrieve specific error code by calling Ptx_GetLastError. Get the error message with Ptx_GetLastErrorMessage. Possible error codes: