MarkupAnnotation.h
1 #pragma once
2 // Copyright (c) 2001-2024 Aspose Pty Ltd. All Rights Reserved.
3 
4 #include <system/string.h>
5 
6 #include "Aspose.PDF.Cpp/InteractiveFeatures/Annotations/Annotation.h"
7 #include "Aspose.PDF.Cpp/aspose_pdf_api_defs.h"
8 
9 namespace Aspose
10 {
11 namespace Pdf
12 {
13 namespace Annotations
14 {
15 enum class AnnotationState;
16 enum class AnnotationStateModel;
17 class CaretAnnotation;
18 class CommonFigureAnnotation;
19 class FileAttachmentAnnotation;
20 class FreeTextAnnotation;
21 class InkAnnotation;
22 class LineAnnotation;
23 enum class LineEnding;
24 class PolyAnnotation;
25 class PopupAnnotation;
26 class RedactionAnnotation;
27 enum class ReplyType;
28 class SoundAnnotation;
29 class StampAnnotation;
30 class TextAnnotation;
31 class TextMarkupAnnotation;
32 } // namespace Annotations
33 class Document;
34 namespace Engine
35 {
36 namespace Data
37 {
38 class IPdfObject;
39 } // namespace Data
40 } // namespace Engine
41 class Operator;
42 class Page;
43 class Point;
44 class Rectangle;
45 namespace Tests
46 {
47 namespace Annotations
48 {
49 class AnnotationStateTests;
50 } // namespace Annotations
51 class RegressionTests_v24_02;
52 } // namespace Tests
53 } // namespace Pdf
54 } // namespace Aspose
55 namespace System
56 {
57 namespace Collections
58 {
59 namespace Generic
60 {
61 template <typename, typename> class Dictionary;
62 template <typename> class List;
63 } // namespace Generic
64 } // namespace Collections
65 class DateTime;
66 namespace Xml
67 {
68 class XmlReader;
69 class XmlWriter;
70 } // namespace Xml
71 } // namespace System
72 
73 namespace Aspose {
74 
75 namespace Pdf {
76 
77 namespace Annotations {
78 
83 {
84  typedef MarkupAnnotation ThisType;
87 
88  typedef ::System::BaseTypesInfo<BaseType, BaseType1> ThisTypeBaseTypesInfo;
89  ASPOSE_PDF_SHARED_RTTI_INFO_DECL();
90 
103  friend class Aspose::Pdf::Tests::Annotations::AnnotationStateTests;
104  friend class Aspose::Pdf::Tests::RegressionTests_v24_02;
105 
106 public:
107 
111  ASPOSE_PDF_SHARED_API System::String get_Title() override;
115  ASPOSE_PDF_SHARED_API void set_Title(System::String value) override;
119  ASPOSE_PDF_SHARED_API System::String get_RichText();
123  ASPOSE_PDF_SHARED_API void set_RichText(System::String value);
127  ASPOSE_PDF_SHARED_API System::DateTime get_CreationDate();
131  ASPOSE_PDF_SHARED_API System::String get_Subject();
135  ASPOSE_PDF_SHARED_API void set_Subject(System::String value);
139  ASPOSE_PDF_SHARED_API System::SharedPtr<PopupAnnotation> get_Popup();
143  ASPOSE_PDF_SHARED_API void set_Popup(System::SharedPtr<PopupAnnotation> value);
147  ASPOSE_PDF_SHARED_API double get_Opacity();
151  ASPOSE_PDF_SHARED_API void set_Opacity(double value);
156  ASPOSE_PDF_SHARED_API System::SharedPtr<Annotation> get_InReplyTo();
161  ASPOSE_PDF_SHARED_API void set_InReplyTo(System::SharedPtr<Annotation> value);
166  ASPOSE_PDF_SHARED_API Aspose::Pdf::Annotations::ReplyType get_ReplyType();
171  ASPOSE_PDF_SHARED_API void set_ReplyType(Aspose::Pdf::Annotations::ReplyType value);
172 
177  ASPOSE_PDF_SHARED_API MarkupAnnotation(System::SharedPtr<Document> document);
178 
184  ASPOSE_PDF_SHARED_API void ClearState();
193  ASPOSE_PDF_SHARED_API void SetReviewState(AnnotationState state, System::String userName);
200  ASPOSE_PDF_SHARED_API void SetReviewState(AnnotationState state);
206  ASPOSE_PDF_SHARED_API void SetMarkedState(bool marked);
212  ASPOSE_PDF_SHARED_API AnnotationState GetState();
218  ASPOSE_PDF_SHARED_API AnnotationStateModel GetStateModel();
219 
220 protected:
221 
227 
235 
240  ASPOSE_PDF_SHARED_API void WriteXfdfAttributes(System::SharedPtr<System::Xml::XmlWriter> writer) override;
245  ASPOSE_PDF_SHARED_API void WriteXfdfElements(System::SharedPtr<System::Xml::XmlWriter> writer) override;
250  ASPOSE_PDF_SHARED_API void ReadXfdfAttributes(System::SharedPtr<System::Xml::XmlReader> reader) override;
251  ASPOSE_PDF_SHARED_API void AfterImport() override;
256  ASPOSE_PDF_SHARED_API void ReadXfdfElements(System::SharedPtr<System::Collections::Generic::Dictionary<System::String, System::String>> table) override;
257  System::SharedPtr<TextAnnotation> FindStateAnnotation();
270  double GetEndingRadius();
277 
278  virtual ASPOSE_PDF_SHARED_API ~MarkupAnnotation();
279 
280 private:
281 
283  System::String _inReplyToName;
284 
285  void SetCreationDate();
286  System::SharedPtr<TextAnnotation> CreateStateAnnotation();
287 
288 };
289 
290 } // namespace Annotations
291 } // namespace Pdf
292 } // namespace Aspose
293 
294 
Abstract base class for poly- annotations.
Definition: PolyAnnotation.h:65
Represents a freehand "scribble" composed of one or more disjoint paths.
Definition: InkAnnotation.h:69
Abstract class representing markup annotation.
Definition: MarkupAnnotation.h:82
String class used across the library. Is a substitute for C# System.String when translating code...
Definition: string.h:121
class ASPOSECPP_SHARED_CLASS List
Definition: ienumerable.h:17
Represents rubber stamp annotation. This type of annotation displays text or graphics intended to loo...
Definition: StampAnnotation.h:86
Class representing line annotation.
Definition: LineAnnotation.h:74
Definition: Artifact.h:67
AnnotationStateModel
The state model corresponding to state of annotation.
Definition: AnnotationStateModel.h:22
Represents a free text annotation that displays text directly on the page. Unlike an ordinary text an...
Definition: FreeTextAnnotation.h:91
This annotation allows to get/set Title property.
Definition: Annotation.h:512
Definition: signed_info.h:13
LineEnding
Enumerates the line ending styles to be used in drawing the line.
Definition: LineEnding.h:22
Pointer class to wrap types being allocated on heap. Use it to manage memory for classes inheriting O...
Definition: fwd.h:22
means saving in XML format
Definition: AFRelationship.h:4
Class describes file attachment annotation.
Definition: FileAttachmentAnnotation.h:58
AnnotationState
The enumeration of states to which the original annotation can be set.
Definition: AnnotationState.h:22
Defies a method that enables object cloning - creating a copy of an object. Objects of this class sho...
Definition: icloneable.h:15
Class representing Caret annotation.
Definition: CaretAnnotation.h:55
Represents a specific date and time value on the time continuum. This type should be allocated on sta...
Definition: date_time.h:49
A printer&#39;s point (1/72 of an inch).
Represents a text annotation that is a �sticky note� attached to a point in the PDF document...
Definition: TextAnnotation.h:82
The coordinates are in the page coordinate context.
Abstract class representing common figure annotation.
Definition: CommonFigureAnnotation.h:47
Represents Redact annotation.
Definition: RedactionAnnotation.h:61
Represents a sound annotation that contains sound recorded from the computer�s microphone or importe...
Definition: SoundAnnotation.h:60
Abstract base class for text markup annotations.
Definition: TextMarkupAnnotation.h:57
Class representing annotation object.
Definition: Annotation.h:303
Represents a abstract base object can be added to the page(doc.Paragraphs.Add()). ...
Definition: BaseParagraph.h:66
ReplyType
Enumerates the kinds of the relationships (the “reply type”) between the annotation and one specifi...
Definition: ReplyType.h:22
Whole PDF file will be submitted.