PageInfo.h
1 #pragma once
2 // Copyright (c) 2001-2024 Aspose Pty Ltd. All Rights Reserved.
3 
4 #include <system/shared_ptr.h>
5 #include <system/icloneable.h>
6 
7 #include "Aspose.PDF.Cpp/aspose_pdf_api_defs.h"
8 
9 namespace Aspose
10 {
11 namespace Pdf
12 {
13 class ApsPagePreprocessor;
14 class Document;
15 class MarginInfo;
16 class Page;
17 class Table;
18 namespace Text
19 {
20 class TextState;
21 } // namespace Text
22 namespace Utils
23 {
24 class PdfDocumentUtils;
25 } // namespace Utils
26 } // namespace Pdf
27 } // namespace Aspose
28 namespace System
29 {
30 namespace Xml
31 {
32 class XmlReader;
33 class XmlTextWriter;
34 } // namespace Xml
35 } // namespace System
36 
37 namespace Aspose {
38 
39 namespace Pdf {
40 
44 class ASPOSE_PDF_SHARED_CLASS PageInfo final : public System::ICloneable
45 {
46  typedef PageInfo ThisType;
48 
49  typedef ::System::BaseTypesInfo<BaseType> ThisTypeBaseTypesInfo;
50  ASPOSE_PDF_SHARED_RTTI_INFO_DECL();
51 
52  friend class Aspose::Pdf::Document;
53  friend class Aspose::Pdf::Page;
54  friend class Aspose::Pdf::Table;
55  friend class Aspose::Pdf::ApsPagePreprocessor;
56  friend class Aspose::Pdf::Utils::PdfDocumentUtils;
57 
58 public:
59 
63  ASPOSE_PDF_SHARED_API const System::SharedPtr<MarginInfo>& get_AnyMargin() const;
67  ASPOSE_PDF_SHARED_API void set_AnyMargin(System::SharedPtr<MarginInfo> value);
71  ASPOSE_PDF_SHARED_API const System::SharedPtr<Text::TextState>& get_DefaultTextState() const;
75  ASPOSE_PDF_SHARED_API void set_DefaultTextState(System::SharedPtr<Text::TextState> value);
79  ASPOSE_PDF_SHARED_API double get_Height() const;
83  ASPOSE_PDF_SHARED_API void set_Height(double value);
87  ASPOSE_PDF_SHARED_API double get_PureHeight();
91  ASPOSE_PDF_SHARED_API bool get_IsLandscape() const;
95  ASPOSE_PDF_SHARED_API void set_IsLandscape(bool value);
99  ASPOSE_PDF_SHARED_API System::SharedPtr<MarginInfo> get_Margin() const;
103  ASPOSE_PDF_SHARED_API void set_Margin(System::SharedPtr<MarginInfo> value);
107  ASPOSE_PDF_SHARED_API double get_Width() const;
111  ASPOSE_PDF_SHARED_API void set_Width(double value);
112 
113  ASPOSE_PDF_SHARED_API PageInfo();
114 
119  ASPOSE_PDF_SHARED_API System::SharedPtr<System::Object> Clone() override;
120 
121 protected:
122 
124 
125  bool get_IsDefaultSize();
126  bool get_IsDefault();
130  double get_PureWidth();
134  bool get_IsWidthSet() const;
138  bool get_IsHeightSet() const;
139 
140  void Serialize(System::SharedPtr<System::Xml::XmlTextWriter> writer);
141  void Deserialize(System::SharedPtr<System::Xml::XmlReader> reader);
142 
143 private:
144 
146  double height;
147  double width;
148  System::SharedPtr<MarginInfo> pr_AnyMargin;
149  System::SharedPtr<Text::TextState> pr_DefaultTextState;
150  bool pr_IsLandscape;
151  bool pr_IsWidthSet;
152 
156  void set_IsWidthSet(bool value);
157 
158  bool pr_IsHeightSet;
159 
163  void set_IsHeightSet(bool value);
164 
165 };
166 
167 } // namespace Pdf
168 } // namespace Aspose
169 
170 
Class representing PDF document
Definition: Document.h:621
Definition: Artifact.h:71
Represents the page information.
Definition: PageInfo.h:44
Pointer class to wrap types being allocated on heap. Use it to manage memory for classes inheriting O...
Definition: SideBySidePdfComparer.h:24
Represents a text type.
means saving in XML format
Class representing page of PDF document.
Definition: Page.h:384
Definition: AFRelationship.h:4
Defies a method that enables object cloning - creating a copy of an object. Objects of this class sho...
Definition: icloneable.h:15
The coordinates are in the page coordinate context.
Represents a table that can be added to the page.
Definition: Table.h:86
bool IsMarginSet
Definition: PageInfo.h:123
Whole PDF file will be submitted.