All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
PolyLine.h
Go to the documentation of this file.
1 //---------------------------------------------------------------------------------------
2 // Copyright (c) 2001-2018 by PDFTron Systems Inc. All Rights Reserved.
3 // Consult legal.txt regarding legal and license information.
4 //---------------------------------------------------------------------------------------
5 #ifndef PDFTRON_H_CPPPDFAnnotsPolyLine
6 #define PDFTRON_H_CPPPDFAnnotsPolyLine
7 
8 #include <PDF/Annots/Line.h>
9 #include <PDF/QuadPoint.h>
10 
11 #ifdef SWIG
12 #define Line LineAnnot
13 #endif
14 
15 namespace pdftron {
16  namespace PDF {
17  namespace Annots {
25 class PolyLine : public Line
26 {
27  public:
34  PolyLine(SDF::Obj d = 0);
35 
42  PolyLine(const Annot& ann) : Line(ann.GetSDFObj()) {}
43 
52  static PolyLine Create(SDF::SDFDoc& doc, const Rect& pos);
53 
61  int GetVertexCount() const;
62 
72  Point GetVertex(int idx) const;
73 
83  void SetVertex(int idx, const Point& pt);
84 
85 
91  {
96  };
97 
104  IntentType GetIntentName() const;
105 
113  void SetIntentName(IntentType mode);
114 
115 
117 #ifndef SWIGHIDDEN
118 PolyLine(TRN_Annot polyline);
119 #endif
120 
122 };//class PolyLine
123 
124 
125 
126 
127 class Polygon : public PolyLine
128 {
129  public:
136  Polygon(SDF::Obj d = 0);
137 
144  Polygon(const Annot& ann) : PolyLine(ann.GetSDFObj()) {}
145 
154  static Polygon Create(SDF::SDFDoc& doc, const Rect& pos);
155 
156 
158 #ifndef SWIGHIDDEN
159 Polygon(TRN_Annot polyline);
160 #endif
161 
163 };//class Polygon
164 
165 
166 
167 
168  };//namespace Annot
169  };//namespace PDF
170 };//namespace pdftron
171 
172 #ifdef SWIG
173 #undef Line
174 #endif
175 
176 #include <Impl/Page.inl>
177 
178 #endif // PDFTRON_H_CPPPDFAnnotsPolyLine
SDF::Obj GetSDFObj() const
Non-standard intent type.
Definition: PolyLine.h:95
Polygon(const Annot &ann)
Definition: PolyLine.h:144
Point GetVertex(int idx) const
The annotation is intended to function as a cloud object.
Definition: PolyLine.h:92
IntentType GetIntentName() const
The polyline annotation is intended to function as a dimension. (PDF 1.7)
Definition: PolyLine.h:93
static PolyLine Create(SDF::SDFDoc &doc, const Rect &pos)
void SetIntentName(IntentType mode)
void SetVertex(int idx, const Point &pt)
PolyLine(const Annot &ann)
Definition: PolyLine.h:42
The polygon annotation is intended to function as a dimension. (PDF 1.7)
Definition: PolyLine.h:94
static Polygon Create(SDF::SDFDoc &doc, const Rect &pos)

© 2002-2014 PDFTron Systems Inc.