QCAD
Open Source 2D CAD
RDimAngularEntity.h
Go to the documentation of this file.
1 
20 #ifndef RDIMANGULARENTITY_H
21 #define RDIMANGULARENTITY_H
22 
23 #include "entity_global.h"
24 
25 #include "RDimensionEntity.h"
26 #include "RDimAngularData.h"
27 
28 class RDocument;
29 class RExporter;
30 
39 
40  Q_DECLARE_TR_FUNCTIONS(RDimAngularEntity)
41 
42 public:
55 
63 
70 
73 
77 
81 
85 
86 public:
87  RDimAngularEntity(RDocument* document);
88  virtual ~RDimAngularEntity();
89 
90  static void init();
91 
92  virtual RDimAngularData& getData() = 0;
93  virtual const RDimAngularData& getData() const = 0;
94 
95  void setExtensionLine1End(const RVector& p) {
96  getData().setExtensionLine1End(p);
97  }
98 
100  return getData().getExtensionLine1End();
101  }
102 
103  void setExtensionLine2End(const RVector& p) {
104  getData().setExtensionLine2End(p);
105  }
106 
108  return getData().getExtensionLine2End();
109  }
110 
111  void setDimArcPosition(const RVector& p) {
112  getData().setDimArcPosition(p);
113  }
114 
116  return getData().getDimArcPosition();
117  }
118 
119  virtual RArc getDimensionArc() const {
120  return getData().getDimensionArc();
121  }
122 
123 protected:
124  virtual void print(QDebug dbg) const;
125 
126 //protected:
127  //RDimAngularData data;
128 };
129 
131 Q_DECLARE_METATYPE(QSharedPointer<RDimAngularEntity>)
132 Q_DECLARE_METATYPE(QSharedPointer<RDimAngularEntity>*)
133 
134 #endif
Angular dimension entity base class.
Definition: RDimAngularEntity.h:38
static RPropertyTypeId PropertyExtLineFixLength
Definition: RDimAngularEntity.h:72
static RPropertyTypeId PropertyLayer
Definition: RDimAngularEntity.h:48
static RPropertyTypeId PropertyLinetype
Definition: RDimAngularEntity.h:49
static RPropertyTypeId PropertyHandle
Definition: RDimAngularEntity.h:44
Represents a 3d vector (x/y/z).
Definition: RVector.h:46
Base class for dimension entity classes.
Definition: RDimensionEntity.h:38
static RPropertyTypeId PropertyExtensionLine2EndY
Definition: RDimAngularEntity.h:79
virtual RDimensionData & getData()=0
RVector getDimArcPosition() const
Definition: RDimAngularEntity.h:115
RVector getExtensionLine2End() const
Definition: RDimAngularEntity.h:107
void setDimArcPosition(const RVector &p)
Definition: RDimAngularEntity.h:111
static RPropertyTypeId PropertyColor
Definition: RDimAngularEntity.h:52
static RPropertyTypeId PropertyUpperTolerance
Definition: RDimAngularEntity.h:60
static RPropertyTypeId PropertyText
Definition: RDimAngularEntity.h:59
static RPropertyTypeId PropertyExtensionLine2EndX
Definition: RDimAngularEntity.h:78
#define QCADENTITY_EXPORT
Definition: entity_global.h:10
void setExtensionLine2End(const RVector &p)
Definition: RDimAngularEntity.h:103
Low-level mathematical representation of an arc.
Definition: RArc.h:40
Copyright (c) 2011-2018 by Andrew Mustun.
Definition: RPropertyTypeId.h:59
static RPropertyTypeId PropertyDimArcPositionY
Definition: RDimAngularEntity.h:83
virtual RArc getDimensionArc() const
Definition: RDimAngularEntity.h:119
void setExtensionLine1End(const RVector &p)
Definition: RDimAngularEntity.h:95
static RPropertyTypeId PropertyMeasuredValue
Definition: RDimAngularEntity.h:62
static RPropertyTypeId PropertyType
Definition: RDimAngularEntity.h:46
static RPropertyTypeId PropertyExtLineFix
Definition: RDimAngularEntity.h:71
static RPropertyTypeId PropertyCustom
Copyright (c) 2011-2018 by Andrew Mustun.
Definition: RDimAngularEntity.h:43
static RPropertyTypeId PropertyArrow2Flipped
Definition: RDimAngularEntity.h:69
static RPropertyTypeId PropertyFontName
Definition: RDimAngularEntity.h:67
virtual void print(QDebug dbg) const
Stream operator for QDebug.
Definition: RDimensionEntity.cpp:333
static RPropertyTypeId PropertyArrow1Flipped
Definition: RDimAngularEntity.h:68
static RPropertyTypeId PropertyExtensionLine1EndZ
Definition: RDimAngularEntity.h:76
A graphics document contains and owns entities, layers, user coordinate systems, variables, block definitions, etc.
Definition: RDocument.h:67
static RPropertyTypeId PropertyMiddleOfTextY
Definition: RDimAngularEntity.h:57
Q_DECLARE_METATYPE(RMath *)
static RPropertyTypeId PropertyExtensionLine1EndX
Definition: RDimAngularEntity.h:74
static RPropertyTypeId PropertyExtensionLine2EndZ
Definition: RDimAngularEntity.h:80
static RPropertyTypeId PropertyDrawOrder
Definition: RDimAngularEntity.h:54
Copyright (c) 2011-2018 by Andrew Mustun.
Definition: RDimAngularData.h:38
RVector getExtensionLine1End() const
Definition: RDimAngularEntity.h:99
static RPropertyTypeId PropertyLinetypeScale
Definition: RDimAngularEntity.h:50
static RPropertyTypeId PropertyMiddleOfTextX
Definition: RDimAngularEntity.h:56
static RPropertyTypeId PropertyDimScale
Definition: RDimAngularEntity.h:64
static RPropertyTypeId PropertyLowerTolerance
Definition: RDimAngularEntity.h:61
Abstract base class for exporters.
Definition: RExporter.h:71
static RPropertyTypeId PropertyDimBlockName
Definition: RDimAngularEntity.h:65
static RPropertyTypeId PropertyAutoTextPos
Definition: RDimAngularEntity.h:66
static RPropertyTypeId PropertyDisplayedColor
Definition: RDimAngularEntity.h:53
static RPropertyTypeId PropertyLineweight
Definition: RDimAngularEntity.h:51
static RPropertyTypeId PropertyProtected
Definition: RDimAngularEntity.h:45
static RPropertyTypeId PropertyExtensionLine1EndY
Definition: RDimAngularEntity.h:75
static RPropertyTypeId PropertyBlock
Definition: RDimAngularEntity.h:47
static void init()
Definition: RDimensionEntity.cpp:74
static RPropertyTypeId PropertyMiddleOfTextZ
Definition: RDimAngularEntity.h:58
static RPropertyTypeId PropertyDimArcPositionZ
Definition: RDimAngularEntity.h:84
static RPropertyTypeId PropertyDimArcPositionX
Definition: RDimAngularEntity.h:82