QCAD
Open Source 2D CAD
Loading...
Searching...
No Matches
RDimArcLengthEntity.h
Go to the documentation of this file.
1
20#ifndef RDIMARCLENGTHENTITY_H
21#define RDIMARCLENGTHENTITY_H
22
23#include "entity_global.h"
24
25#include "RDimAngularEntity.h"
26#include "RDimArcLengthData.h"
27
28class RDocument;
29class RExporter;
30
39
40 Q_DECLARE_TR_FUNCTIONS(RDimArcLengthEntity)
41
42public:
56
64
70 //static RPropertyTypeId PropertyDimdli;
80 //static RPropertyTypeId PropertyDimaunit;
81 //static RPropertyTypeId PropertyDimadec;
82 //static RPropertyTypeId PropertyDimazin;
85
86// static RPropertyTypeId PropertyLinearFactor;
87// static RPropertyTypeId PropertyDimScale;
93
96
100
104
108
112
114
115public:
116 RDimArcLengthEntity(RDocument* document, const RDimArcLengthData& data);
117 virtual ~RDimArcLengthEntity();
118
119 static void init();
120
123 }
124
128
129 virtual QSharedPointer<RObject> clone() const {
130 return QSharedPointer<RObject>(new RDimArcLengthEntity(*this));
131 }
132
133 QSharedPointer<RDimArcLengthEntity> cloneToDimArcLengthEntity() const {
134 return QSharedPointer<RDimArcLengthEntity>(new RDimArcLengthEntity(*this));
135 }
136
137 virtual bool setProperty(RPropertyTypeId propertyTypeId, const QVariant& value,
138 RTransaction* transaction=NULL);
139 virtual QPair<QVariant, RPropertyAttributes> getProperty(
140 RPropertyTypeId& propertyTypeId,
141 bool humanReadable = false, bool noAttributes = false, bool showOnRequest = false);
142
144 return data;
145 }
146
148 data = d;
149 }
150
151 virtual const RDimArcLengthData& getData() const {
152 return data;
153 }
154
155 void setCenter(const RVector& p) {
156 getData().setCenter(p);
157 }
158
160 return getData().getCenter();
161 }
162
163protected:
164 virtual void print(QDebug dbg) const;
165
166protected:
168};
169
171Q_DECLARE_METATYPE(QSharedPointer<RDimArcLengthEntity>)
172Q_DECLARE_METATYPE(QSharedPointer<RDimArcLengthEntity>*)
173
174#endif
Q_DECLARE_METATYPE(RMath *)
virtual RVector getCenter() const =0
Angular dimension entity base class.
Definition RDimAngularEntity.h:39
static void init()
Definition RDimAngularEntity.cpp:101
virtual RDimAngularData & getData()=0
virtual void print(QDebug dbg) const
Stream operator for QDebug.
Definition RDimAngularEntity.cpp:178
Arc length dimension entity data class.
Definition RDimArcLengthData.h:39
Arc length dimension entity class.
Definition RDimArcLengthEntity.h:38
static RPropertyTypeId PropertyFontName
Definition RDimArcLengthEntity.h:90
static RPropertyTypeId PropertyCustom
Copyright (c) 2011-2018 by Andrew Mustun.
Definition RDimArcLengthEntity.h:43
static RPropertyTypeId PropertyDimscale
Definition RDimArcLengthEntity.h:65
static RPropertyTypeId PropertyDimtih
Definition RDimArcLengthEntity.h:74
static RPropertyTypeId PropertyAutoTextPos
Definition RDimArcLengthEntity.h:89
static RPropertyTypeId PropertyDimtxt
Definition RDimArcLengthEntity.h:67
static RPropertyTypeId PropertyDimasz
Definition RDimArcLengthEntity.h:69
static RPropertyTypeId PropertyExtLineFix
Definition RDimArcLengthEntity.h:94
static RPropertyTypeId PropertyDimexe
Definition RDimArcLengthEntity.h:71
static RPropertyTypeId PropertyLayer
Definition RDimArcLengthEntity.h:49
static RPropertyTypeId PropertyType
Definition RDimArcLengthEntity.h:47
RVector getCenter() const
Definition RDimArcLengthEntity.h:159
static RPropertyTypeId PropertyExtensionLine2EndY
Definition RDimArcLengthEntity.h:106
static RPropertyTypeId PropertyArrow2Flipped
Definition RDimArcLengthEntity.h:92
static RPropertyTypeId PropertyExtensionLine1EndX
Definition RDimArcLengthEntity.h:101
static RPropertyTypeId PropertyExtensionLine1EndZ
Definition RDimArcLengthEntity.h:103
static RPropertyTypeId PropertyExtensionLine2EndZ
Definition RDimArcLengthEntity.h:107
static RPropertyTypeId PropertyArchTick
Definition RDimArcLengthEntity.h:83
static RPropertyTypeId PropertyDimgap
Definition RDimArcLengthEntity.h:68
static RPropertyTypeId PropertyBlock
Definition RDimArcLengthEntity.h:48
static QSet< RPropertyTypeId > getStaticPropertyTypeIds()
Definition RDimArcLengthEntity.h:125
static RPropertyTypeId PropertyMeasuredValue
Definition RDimArcLengthEntity.h:63
virtual QSharedPointer< RObject > clone() const
Definition RDimArcLengthEntity.h:129
static RPropertyTypeId PropertyColor
Definition RDimArcLengthEntity.h:53
static RPropertyTypeId PropertyMiddleOfTextZ
Definition RDimArcLengthEntity.h:59
RDimArcLengthData data
Definition RDimArcLengthEntity.h:167
static RPropertyTypeId PropertyLinetype
Definition RDimArcLengthEntity.h:50
static RPropertyTypeId PropertyUpperTolerance
Definition RDimArcLengthEntity.h:61
void setData(RDimArcLengthData &d)
Definition RDimArcLengthEntity.h:147
static RPropertyTypeId PropertyDimArcPositionZ
Definition RDimArcLengthEntity.h:111
static RPropertyTypeId PropertyCenterX
Definition RDimArcLengthEntity.h:97
static RPropertyTypeId PropertyHandle
Definition RDimArcLengthEntity.h:44
static RPropertyTypeId PropertyWorkingSet
Definition RDimArcLengthEntity.h:46
QSharedPointer< RDimArcLengthEntity > cloneToDimArcLengthEntity() const
Definition RDimArcLengthEntity.h:133
static RPropertyTypeId PropertyDimBlockName
Definition RDimArcLengthEntity.h:88
static RPropertyTypeId PropertyExtLineFixLength
Definition RDimArcLengthEntity.h:95
static RPropertyTypeId PropertyDimArcPositionY
Definition RDimArcLengthEntity.h:110
virtual const RDimArcLengthData & getData() const
Definition RDimArcLengthEntity.h:151
static RPropertyTypeId PropertyDimdec
Definition RDimArcLengthEntity.h:77
static RPropertyTypeId PropertyDimdsep
Definition RDimArcLengthEntity.h:78
static RPropertyTypeId PropertyDimArcSymbolType
Definition RDimArcLengthEntity.h:113
static RPropertyTypeId PropertyArrow1Flipped
Definition RDimArcLengthEntity.h:91
static RPropertyTypeId PropertyMiddleOfTextX
Definition RDimArcLengthEntity.h:57
static RPropertyTypeId PropertyDimArcPositionX
Definition RDimArcLengthEntity.h:109
void setCenter(const RVector &p)
Definition RDimArcLengthEntity.h:155
static RPropertyTypeId PropertyDimlfac
Definition RDimArcLengthEntity.h:66
static RPropertyTypeId PropertyText
Definition RDimArcLengthEntity.h:60
static RPropertyTypeId PropertyDimlunit
Definition RDimArcLengthEntity.h:76
static RPropertyTypeId PropertyExtensionLine1EndY
Definition RDimArcLengthEntity.h:102
static RPropertyTypeId PropertyDimtsz
Definition RDimArcLengthEntity.h:75
static RPropertyTypeId PropertyDimexo
Definition RDimArcLengthEntity.h:72
static RPropertyTypeId PropertyDimzin
Definition RDimArcLengthEntity.h:79
static RPropertyTypeId PropertyLineweight
Definition RDimArcLengthEntity.h:52
static RPropertyTypeId PropertyProtected
Definition RDimArcLengthEntity.h:45
static RPropertyTypeId PropertyExtensionLine2EndX
Definition RDimArcLengthEntity.h:105
static RPropertyTypeId PropertyDimtad
Definition RDimArcLengthEntity.h:73
static RS::EntityType getRtti()
Definition RDimArcLengthEntity.h:121
static RPropertyTypeId PropertyLowerTolerance
Definition RDimArcLengthEntity.h:62
static RPropertyTypeId PropertyDrawOrder
Definition RDimArcLengthEntity.h:55
virtual RDimArcLengthData & getData()
Definition RDimArcLengthEntity.h:143
static RPropertyTypeId PropertyDisplayedColor
Definition RDimArcLengthEntity.h:54
static RPropertyTypeId PropertyDimclrt
Definition RDimArcLengthEntity.h:84
static RPropertyTypeId PropertyLinetypeScale
Definition RDimArcLengthEntity.h:51
static RPropertyTypeId PropertyCenterY
Definition RDimArcLengthEntity.h:98
static RPropertyTypeId PropertyMiddleOfTextY
Definition RDimArcLengthEntity.h:58
static RPropertyTypeId PropertyCenterZ
Definition RDimArcLengthEntity.h:99
virtual QPair< QVariant, RPropertyAttributes > getProperty(RPropertyTypeId &propertyTypeId, bool humanReadable=false, bool noAttributes=false, bool showOnRequest=false)
Definition RDimensionEntity.cpp:278
virtual bool setProperty(RPropertyTypeId propertyTypeId, const QVariant &value, RTransaction *transaction=NULL)
Sets the given property to the given value.
Definition RDimensionEntity.cpp:185
A graphics document contains and owns entities, layers, user coordinate systems, variables,...
Definition RDocument.h:78
Abstract base class for exporters.
Definition RExporter.h:78
Copyright (c) 2011-2018 by Andrew Mustun.
Definition RPropertyTypeId.h:54
static QSet< RPropertyTypeId > getPropertyTypeIds(RS::EntityType type, RPropertyAttributes::Option=RPropertyAttributes::NoOptions)
Gets all property type IDs that where registered for the given class.
Definition RPropertyTypeId.cpp:283
EntityType
Entity types used for property handling / filtering.
Definition RS.h:227
@ EntityDimArcLength
Arc Length Dimension.
Definition RS.h:271
Transaction implementation.
Definition RTransaction.h:73
Represents a 3d vector (x/y/z).
Definition RVector.h:47
#define QCADENTITY_EXPORT
Definition entity_global.h:10
#define NULL
Definition opennurbs_system.h:256