PDF Toolbox
Loading...
Searching...
No Matches
PdfTools_Toolbox_PtxPdfStructure.h
Go to the documentation of this file.
1/******************************************************************************
2 *
3 * File: PdfTools_Toolbox_PtxPdfStructure.h
4 *
5 * Description: Sub Header file for Toolbox SDK
6 *
7 * Author: PDF Tools AG
8 *
9 * Copyright: Copyright (C) 2024 - 2024 PDF Tools AG, Switzerland
10 * All rights reserved.
11 *
12 * Notice: By downloading and using this artifact, you accept PDF Tools AG's
13 * [license agreement](https://www.pdf-tools.com/license-agreement/),
14 * [privacy policy](https://www.pdf-tools.com/privacy-policy/),
15 * and allow PDF Tools AG to track your usage data.
16 *
17 *****************************************************************************/
18
19#ifndef PDFTOOLS_TOOLBOX_PTXPDFSTRUCTURE_H__
20#define PDFTOOLS_TOOLBOX_PTXPDFSTRUCTURE_H__
21
22#ifndef PDFTOOLS_TOOLBOX_CALL
23#if defined(WIN32)
24#define PDFTOOLS_TOOLBOX_CALL __stdcall
25#else
26#define PDFTOOLS_TOOLBOX_CALL
27#endif
28#endif
29
32
33#ifdef __cplusplus
34extern "C"
35{
36#endif
37
38#ifdef _UNICODE
39#define PtxPdfStructure_RoleMap_Get PtxPdfStructure_RoleMap_GetW
40#define PtxPdfStructure_RoleMap_GetKey PtxPdfStructure_RoleMap_GetKeyW
41#define PtxPdfStructure_RoleMap_GetValue PtxPdfStructure_RoleMap_GetValueW
42#define PtxPdfStructure_RoleMap_Set PtxPdfStructure_RoleMap_SetW
43#define PtxPdfStructure_RoleMap_SetValue PtxPdfStructure_RoleMap_SetValueW
44
45#define PtxPdfStructure_Node_New PtxPdfStructure_Node_NewW
46#define PtxPdfStructure_Node_GetTag PtxPdfStructure_Node_GetTagW
47#define PtxPdfStructure_Node_SetTag PtxPdfStructure_Node_SetTagW
48#define PtxPdfStructure_Node_GetAlternateText PtxPdfStructure_Node_GetAlternateTextW
49#define PtxPdfStructure_Node_SetAlternateText PtxPdfStructure_Node_SetAlternateTextW
50
51#else
52#define PtxPdfStructure_RoleMap_Get PtxPdfStructure_RoleMap_GetA
53#define PtxPdfStructure_RoleMap_GetKey PtxPdfStructure_RoleMap_GetKeyA
54#define PtxPdfStructure_RoleMap_GetValue PtxPdfStructure_RoleMap_GetValueA
55#define PtxPdfStructure_RoleMap_Set PtxPdfStructure_RoleMap_SetA
56#define PtxPdfStructure_RoleMap_SetValue PtxPdfStructure_RoleMap_SetValueA
57
58#define PtxPdfStructure_Node_New PtxPdfStructure_Node_NewA
59#define PtxPdfStructure_Node_GetTag PtxPdfStructure_Node_GetTagA
60#define PtxPdfStructure_Node_SetTag PtxPdfStructure_Node_SetTagA
61#define PtxPdfStructure_Node_GetAlternateText PtxPdfStructure_Node_GetAlternateTextA
62#define PtxPdfStructure_Node_SetAlternateText PtxPdfStructure_Node_SetAlternateTextA
63
64#endif
65
66/******************************************************************************
67 * RoleMap
68 *****************************************************************************/
159 int it);
180 const char* szKey);
201 const WCHAR* szKey);
224 int it, char* pBuffer,
225 size_t nBufferSize);
248 int it, WCHAR* pBuffer,
249 size_t nBufferSize);
272PtxPdfStructure_RoleMap_GetValueA(TPtxPdfStructure_RoleMap* pRoleMap, int it, char* pBuffer, size_t nBufferSize);
295PtxPdfStructure_RoleMap_GetValueW(TPtxPdfStructure_RoleMap* pRoleMap, int it, WCHAR* pBuffer, size_t nBufferSize);
316 const char* szKey, const char* szValue);
337 const WCHAR* szKey,
338 const WCHAR* szValue);
356 int it, const char* szValue);
374 int it, const WCHAR* szValue);
375
376/******************************************************************************
377 * Node
378 *****************************************************************************/
404PtxPdfStructure_Node_NewA(const char* szTag, TPtxPdf_Document* pDocument, TPtxPdf_Page* pPage);
431
498 char* pBuffer, size_t nBufferSize);
524 WCHAR* pBuffer, size_t nBufferSize);
545 const char* szTag);
566 const WCHAR* szTag);
607 TPtxPdf_Page* pPage);
633PtxPdfStructure_Node_GetAlternateTextA(TPtxPdfStructure_Node* pNode, char* pBuffer, size_t nBufferSize);
678 const char* szAlternateText);
697 const WCHAR* szAlternateText);
738
739/******************************************************************************
740 * NodeList
741 *****************************************************************************/
790 TPtxPdfStructure_Node* pNode);
791
792/******************************************************************************
793 * Tree
794 *****************************************************************************/
814
849
850#ifdef __cplusplus
851}
852#endif
853
854#endif /* PDFTOOLS_TOOLBOX_PTXPDFSTRUCTURE_H__ */
#define PDFTOOLS_TOOLBOX_EXPORT
Definition PdfTools_Toolbox_Platform.h:143
unsigned short WCHAR
Definition PdfTools_Toolbox_Platform.h:95
PDFTOOLS_TOOLBOX_EXPORT size_t PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_GetAlternateTextW(TPtxPdfStructure_Node *pNode, WCHAR *pBuffer, size_t nBufferSize)
PDFTOOLS_TOOLBOX_EXPORT BOOL PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_SetTagA(TPtxPdfStructure_Node *pNode, const char *szTag)
PDFTOOLS_TOOLBOX_EXPORT TPtxPdfStructure_Node *PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_NewW(const WCHAR *szTag, TPtxPdf_Document *pDocument, TPtxPdf_Page *pPage)
PDFTOOLS_TOOLBOX_EXPORT size_t PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_GetKeyW(TPtxPdfStructure_RoleMap *pRoleMap, int it, WCHAR *pBuffer, size_t nBufferSize)
Get the key of the entry given a position.
PDFTOOLS_TOOLBOX_EXPORT size_t PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_GetValueA(TPtxPdfStructure_RoleMap *pRoleMap, int it, char *pBuffer, size_t nBufferSize)
Get the value of the entry given a position.
PDFTOOLS_TOOLBOX_EXPORT size_t PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_GetTagA(TPtxPdfStructure_Node *pNode, char *pBuffer, size_t nBufferSize)
PDFTOOLS_TOOLBOX_EXPORT BOOL PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_SetValueW(TPtxPdfStructure_RoleMap *pRoleMap, int it, const WCHAR *szValue)
Set the value of the entry at a position in the map.
PDFTOOLS_TOOLBOX_EXPORT TPtxPdfStructure_Node *PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Tree_GetDocumentNode(TPtxPdfStructure_Tree *pTree)
PDFTOOLS_TOOLBOX_EXPORT TPtxPdfStructure_Node *PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_GetParent(TPtxPdfStructure_Node *pNode)
PDFTOOLS_TOOLBOX_EXPORT BOOL PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_SetW(TPtxPdfStructure_RoleMap *pRoleMap, const WCHAR *szKey, const WCHAR *szValue)
Set the value of an entry for a given key. This operation invalidates all positions previously return...
PDFTOOLS_TOOLBOX_EXPORT BOOL PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_SetBoundingBox(TPtxPdfStructure_Node *pNode, const TPtxGeomReal_Rectangle *pBoundingBox)
Bounding box for contents - should only be set for Figure, Formula and Table.
PDFTOOLS_TOOLBOX_EXPORT int PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_GetBegin(TPtxPdfStructure_RoleMap *pRoleMap)
Get the position of the first entry in the map.
PDFTOOLS_TOOLBOX_EXPORT BOOL PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_SetPage(TPtxPdfStructure_Node *pNode, TPtxPdf_Page *pPage)
PDFTOOLS_TOOLBOX_EXPORT TPtxPdf_Page *PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_GetPage(TPtxPdfStructure_Node *pNode)
PDFTOOLS_TOOLBOX_EXPORT TPtxPdfStructure_Node *PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_NodeList_Get(TPtxPdfStructure_NodeList *pNodeList, int iIndex)
Returns the element at the specified position in the given list.
#define PDFTOOLS_TOOLBOX_CALL
Definition PdfTools_Toolbox_PtxPdfStructure.h:26
PDFTOOLS_TOOLBOX_EXPORT BOOL PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_SetValueA(TPtxPdfStructure_RoleMap *pRoleMap, int it, const char *szValue)
Set the value of the entry at a position in the map.
PDFTOOLS_TOOLBOX_EXPORT size_t PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_GetAlternateTextA(TPtxPdfStructure_Node *pNode, char *pBuffer, size_t nBufferSize)
PDFTOOLS_TOOLBOX_EXPORT BOOL PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_SetA(TPtxPdfStructure_RoleMap *pRoleMap, const char *szKey, const char *szValue)
Set the value of an entry for a given key. This operation invalidates all positions previously return...
PDFTOOLS_TOOLBOX_EXPORT int PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_GetCount(TPtxPdfStructure_RoleMap *pRoleMap)
The number of key-value pairs in the map.
PDFTOOLS_TOOLBOX_EXPORT size_t PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_GetValueW(TPtxPdfStructure_RoleMap *pRoleMap, int it, WCHAR *pBuffer, size_t nBufferSize)
Get the value of the entry given a position.
PDFTOOLS_TOOLBOX_EXPORT int PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_GetNext(TPtxPdfStructure_RoleMap *pRoleMap, int it)
Get the position of the next entry in the map.
PDFTOOLS_TOOLBOX_EXPORT size_t PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_GetKeyA(TPtxPdfStructure_RoleMap *pRoleMap, int it, char *pBuffer, size_t nBufferSize)
Get the key of the entry given a position.
PDFTOOLS_TOOLBOX_EXPORT TPtxPdfStructure_Node *PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_NewA(const char *szTag, TPtxPdf_Document *pDocument, TPtxPdf_Page *pPage)
PDFTOOLS_TOOLBOX_EXPORT BOOL PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_SetAlternateTextA(TPtxPdfStructure_Node *pNode, const char *szAlternateText)
PDFTOOLS_TOOLBOX_EXPORT BOOL PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_GetBoundingBox(TPtxPdfStructure_Node *pNode, TPtxGeomReal_Rectangle *pBoundingBox)
Bounding box for contents - should only be set for Figure, Formula and Table.
PDFTOOLS_TOOLBOX_EXPORT TPtxPdfStructure_RoleMap *PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Tree_GetRoleMap(TPtxPdfStructure_Tree *pTree)
PDFTOOLS_TOOLBOX_EXPORT size_t PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_GetTagW(TPtxPdfStructure_Node *pNode, WCHAR *pBuffer, size_t nBufferSize)
PDFTOOLS_TOOLBOX_EXPORT int PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_GetEnd(TPtxPdfStructure_RoleMap *pRoleMap)
Get the end position of the map.
PDFTOOLS_TOOLBOX_EXPORT TPtxPdfStructure_Tree *PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Tree_New(TPtxPdf_Document *pDocument)
PDFTOOLS_TOOLBOX_EXPORT int PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_GetW(TPtxPdfStructure_RoleMap *pRoleMap, const WCHAR *szKey)
Get the position of a key in the map. If no error occurred, then the position can be used to get the ...
PDFTOOLS_TOOLBOX_EXPORT BOOL PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_NodeList_Add(TPtxPdfStructure_NodeList *pNodeList, TPtxPdfStructure_Node *pNode)
Add an element to the end of the list.
PDFTOOLS_TOOLBOX_EXPORT int PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_GetA(TPtxPdfStructure_RoleMap *pRoleMap, const char *szKey)
Get the position of a key in the map. If no error occurred, then the position can be used to get the ...
PDFTOOLS_TOOLBOX_EXPORT BOOL PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_SetAlternateTextW(TPtxPdfStructure_Node *pNode, const WCHAR *szAlternateText)
PDFTOOLS_TOOLBOX_EXPORT BOOL PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_SetTagW(TPtxPdfStructure_Node *pNode, const WCHAR *szTag)
PDFTOOLS_TOOLBOX_EXPORT int PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_RoleMap_GetSize(TPtxPdfStructure_RoleMap *pRoleMap)
The number of key-value pairs in the map.
PDFTOOLS_TOOLBOX_EXPORT int PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_NodeList_GetCount(TPtxPdfStructure_NodeList *pNodeList)
Get the number of elements in the list.
PDFTOOLS_TOOLBOX_EXPORT TPtxPdfStructure_NodeList *PDFTOOLS_TOOLBOX_CALL PtxPdfStructure_Node_GetChildren(TPtxPdfStructure_Node *pNode)
#define BOOL
Definition PdfTools_Toolbox_Types.h:23
Definition PdfTools_Toolbox_Types.h:2139