PDF SDK Documentation

Comprehensive Guide for Developers: Features, Integration, and API Reference

Loading...
Searching...
No Matches
page.h
1// Copyright (c) 2009-2025 Avanquest Software. All rights reserved.
2
3#ifndef PDFSDK_CXX_PDF_PAGE_H_INCLUDED_
4#define PDFSDK_CXX_PDF_PAGE_H_INCLUDED_
5
7#include <pdfsdk/cxx/math.h>
8
9#include "forward_declarations.h"
10#include "wrapper_base.h"
11
12namespace PDF {
13
20class Page : public detail::RefCountedHandle<PDPage> {
21public:
27
33
38 bool IsContentModified() const;
39
44 void SetContentModified(bool modified = true);
45
53
58 size_t GetPageIndex() const;
59
64 PDRotate GetRotate() const;
65
70 void SetRotate(PDRotate rotate);
71
77
82 void SetCropBox(const RectF& box);
83
89
94 void SetMediaBox(const PDF::RectF& box);
95
101
106 void SetArtBox(const RectF& box);
107
113
118 void SetBleedBox(const RectF& box);
119
125
130 void SetTrimBox(const RectF& box);
131
137
142 float GetUserUnitSize() const;
143
148 void SetUserUnitSize(float unitSize);
149
157 Matrix GetPageToDevSpaceMatrix(float zoom = 1.f, PDRotate rotate = kPDRotate_0, float dpi = 96) const;
158
166 Matrix GetDevToPageSpaceMatrix(float zoom = 1.f, PDRotate rotate = kPDRotate_0, float dpi = 96) const;
167
175 RectF GetDevSpacePageBox(float zoom = 1.f, PDRotate rotate = kPDRotate_0, float dpi = 96) const;
176
181 size_t GetNumAnnots() const;
182
188 Annot GetAnnot(size_t index) const;
189
195 void AddAnnot(size_t insertAt, Annot annot);
196
201 void RemoveAnnot(Annot annot);
202
207 void RemoveAnnotByIndex(size_t index);
208
214 size_t GetAnnotIndex(Annot annot) const;
215
221
227
228 PDF_CXX_CORE_WRAPPER_DEFINE_MEMBERS_(Page, PDPage)
229};
230
231} // namespace PDF
232
233#include "page_impl.inl"
234
235#endif // PDFSDK_CXX_PDF_PAGE_H_INCLUDED_
Represents an annotation in a PDF document.
Definition annot.h:19
Represents the content of a PDF page.
Definition content.h:20
Represents a PDF document.
Definition document.h:22
Represents a PDF object.
Definition object.h:20
Represents a leaf node (Page Object).
Definition page.h:20
void FlushModifiedContent()
Content GetContent() const
void SetContentModified(bool modified=true)
Set the content modified flag.
RectF GetDevSpacePageBox(float zoom=1.f, PDRotate rotate=kPDRotate_0, float dpi=96) const
RectF GetBleedBox() const
void SetArtBox(const RectF &box)
void SetMediaBox(const PDF::RectF &box)
float GetUserUnitSize() const
Annot GetAnnot(size_t index) const
Matrix GetDevToPageSpaceMatrix(float zoom=1.f, PDRotate rotate=kPDRotate_0, float dpi=96) const
PDRotate GetRotate() const
void AddAnnot(size_t insertAt, Annot annot)
void SetUserUnitSize(float unitSize)
RectF GetArtBox() const
RectF GetTrimBox() const
RectF GetMediaBox() const
void SetBleedBox(const RectF &box)
RectF GetPageBox() const
void RemoveAnnot(Annot annot)
bool IsContentModified() const
Get the content modified flag.
size_t GetNumAnnots() const
Document GetDocument() const
void SetCropBox(const RectF &box)
void SetRotate(PDRotate rotate)
void RemoveAnnotByIndex(size_t index)
Matrix GetPageToDevSpaceMatrix(float zoom=1.f, PDRotate rotate=kPDRotate_0, float dpi=96) const
void SetTrimBox(const RectF &box)
size_t GetAnnotIndex(Annot annot) const
size_t GetPageIndex() const
Object GetPdfObject() const
RectF GetCropBox() const
PageText GetPageText() const
Represents text on a page.
Definition page_text.h:42
Document API.
Definition math.h:1053
Definition math.h:545