|
QCAD
Open Source 2D CAD
|
Go to the documentation of this file.
20 #ifndef RELLIPSEENTITY_H
21 #define RELLIPSEENTITY_H
96 virtual QPair<QVariant, RPropertyAttributes>
getProperty(
98 bool humanReadable =
false,
bool noAttributes =
false,
bool showOnRequest =
false);
113 return data.getCenter();
117 return data.getMajorPoint();
121 return data.getMajorRadius();
125 return data.getMinorRadius();
129 return data.getRatio();
133 return data.getAngle();
137 data.setRatio(ratio);
141 return data.getStartAngle();
145 return data.getStartParam();
149 data.setStartParam(param);
153 return data.getEndAngle();
157 return data.getEndParam();
161 data.setEndParam(param);
165 return data.getAngleLength();
169 return data.getAngleAt(distance, from);
173 return data.isReversed();
177 data.setReversed(reversed);
181 return data.getStartPoint();
185 return data.getEndPoint();
189 return data.isFullEllipse();
193 return data.getDirection1();
197 return data.getDirection2();
201 return data.reverse();
205 return data.getSideOfPoint(point);
209 return data.getParamTo(pos);
213 return data.getTrimEnd(trimPoint, clickPoint);
217 return data.trimStartPoint(trimPoint, clickPoint, extend);
221 return data.trimEndPoint(trimPoint, clickPoint, extend);
225 return data.getLength();
229 return data.getSweep();
233 return data.getPointAt(angle);
237 return data.approximateWithSplines();
241 return data.approximateWithArcs(segments);
245 virtual void print(QDebug dbg)
const;
static RPropertyTypeId PropertyEndPointX
Definition: REllipseEntity.h:72
double getAngleLength() const
Definition: REllipseEntity.h:164
double getLength() const
Definition: REllipseEntity.h:224
double getEndParam() const
Definition: REllipseEntity.h:156
static RPropertyTypeId PropertyStartPointY
Definition: REllipseEntity.h:70
RVector getStartPoint() const
Definition: REllipseEntity.h:180
Ellipse entity.
Definition: REllipseEntity.h:39
static RPropertyTypeId PropertyEndAngle
Definition: REllipseEntity.h:66
static RPropertyTypeId PropertyMajorPointX
Definition: REllipseEntity.h:59
static RPropertyTypeId PropertyEndParam
Definition: REllipseEntity.h:64
static RPropertyTypeId PropertyEndPointY
Definition: REllipseEntity.h:73
virtual REllipseEntity * clone() const
Definition: REllipseEntity.h:88
double getAngleAt(double distance, RS::From from) const
Definition: REllipseEntity.h:168
bool trimEndPoint(const RVector &trimPoint, const RVector &clickPoint=RVector::invalid, bool extend=false)
Definition: REllipseEntity.h:220
Side
Side used for side of a point relative to an entity (right hand or left hand side)
Definition: RS.h:205
Represents a 3d vector (x/y/z).
Definition: RVector.h:46
Ending
Entity ending.
Definition: RS.h:215
static RPropertyTypeId PropertyCenterZ
Definition: REllipseEntity.h:58
static RPropertyTypeId PropertyStartParam
Definition: REllipseEntity.h:63
static RPropertyTypeId PropertyEndPointZ
Definition: REllipseEntity.h:74
static RPropertyTypeId PropertyProtected
Definition: REllipseEntity.h:44
#define QCADENTITY_EXPORT
Definition: entity_global.h:10
REllipseData data
Definition: REllipseEntity.h:248
void setRatio(double ratio)
Definition: REllipseEntity.h:136
virtual void exportEntity(RExporter &e, bool preview=false, bool forceSelected=false) const =0
Exports the entity to the given exporter.
double getEndAngle() const
Definition: REllipseEntity.h:152
static RPropertyTypeId PropertyStartPointZ
Definition: REllipseEntity.h:71
bool isReversed() const
Definition: REllipseEntity.h:172
RVector getCenter() const
Definition: REllipseEntity.h:112
RS::Side getSideOfPoint(const RVector &point) const
Definition: REllipseEntity.h:204
Base class for all entity classes.
Definition: REntity.h:65
static RPropertyTypeId PropertyStartPointX
Definition: REllipseEntity.h:69
double getStartAngle() const
Definition: REllipseEntity.h:140
bool trimStartPoint(const RVector &trimPoint, const RVector &clickPoint=RVector::invalid, bool extend=false)
Definition: REllipseEntity.h:216
Q_DECLARE_METATYPE(RMath *)
static RPropertyTypeId PropertyWorkingSet
Definition: REllipseEntity.h:45
void setReversed(bool reversed)
Definition: REllipseEntity.h:176
double getMajorRadius() const
Definition: REllipseEntity.h:120
double getRatio() const
Definition: REllipseEntity.h:128
static RPropertyTypeId PropertyLinetype
Definition: REllipseEntity.h:49
static RPropertyTypeId PropertyLineweight
Definition: REllipseEntity.h:51
static void init()
Definition: REntity.cpp:88
virtual void print(QDebug dbg) const
Stream operator for QDebug.
Definition: REntity.cpp:455
Copyright (c) 2011-2018 by Andrew Mustun.
Definition: RPropertyTypeId.h:59
static RPropertyTypeId PropertyStartAngle
Definition: REllipseEntity.h:65
static RPropertyTypeId PropertyLinetypeScale
Definition: REllipseEntity.h:50
QList< RSpline > approximateWithSplines() const
Definition: REllipseEntity.h:236
RS::Ending getTrimEnd(const RVector &trimPoint, const RVector &clickPoint)
Definition: REllipseEntity.h:212
static RPropertyTypeId PropertyCenterY
Definition: REllipseEntity.h:57
static RPropertyTypeId PropertyType
Definition: REllipseEntity.h:46
bool isFullEllipse() const
Definition: REllipseEntity.h:188
RVector getPointAt(double angle) const
Definition: REllipseEntity.h:232
Abstract base class for exporters.
Definition: RExporter.h:72
virtual bool setProperty(RPropertyTypeId propertyTypeId, const QVariant &value, RTransaction *transaction=NULL)
Sets the given property to the given value.
Definition: REntity.cpp:323
virtual const REllipseData & getData() const
Definition: REllipseEntity.h:108
A graphics document contains and owns entities, layers, user coordinate systems, variables,...
Definition: RDocument.h:72
static RPropertyTypeId PropertyMajorPointY
Definition: REllipseEntity.h:60
static RPropertyTypeId PropertyRatio
Definition: REllipseEntity.h:62
static RPropertyTypeId PropertyDrawOrder
Definition: REllipseEntity.h:54
static RPropertyTypeId PropertyCircumference
Definition: REllipseEntity.h:76
virtual bool reverse()
Definition: REllipseEntity.h:200
virtual QSharedPointer< REntity > scaleNonUniform(const RVector &scaleFactors, const RVector ¢er=RDEFAULT_RVECTOR)
Definition: REntity.cpp:442
double getParamTo(const RVector &pos)
Definition: REllipseEntity.h:208
static RPropertyTypeId PropertyCustom
Copyright (c) 2011-2018 by Andrew Mustun.
Definition: REllipseEntity.h:42
static RPropertyTypeId PropertyColor
Definition: REllipseEntity.h:52
static QSet< RPropertyTypeId > getStaticPropertyTypeIds()
Definition: REllipseEntity.h:84
RVector getEndPoint() const
Definition: REllipseEntity.h:184
double getMinorRadius() const
Definition: REllipseEntity.h:124
RVector getMajorPoint() const
Definition: REllipseEntity.h:116
Low-level mathematical representation of an ellipse or ellipse arc.
Definition: REllipse.h:42
RPolyline approximateWithArcs(int segments) const
Definition: REllipseEntity.h:240
virtual QPair< QVariant, RPropertyAttributes > getProperty(RPropertyTypeId &propertyTypeId, bool humanReadable=false, bool noAttributes=false, bool showOnRequest=false)
Definition: REntity.cpp:230
Copyright (c) 2011-2018 by Andrew Mustun.
Definition: REllipseData.h:40
static RPropertyTypeId PropertyCenterX
Definition: REllipseEntity.h:56
static RPropertyTypeId PropertyLayer
Definition: REllipseEntity.h:48
Transaction implementation.
Definition: RTransaction.h:74
double getDirection1() const
Definition: REllipseEntity.h:192
static QSet< RPropertyTypeId > getPropertyTypeIds(const std::type_info &classInfo, RPropertyAttributes::Option=RPropertyAttributes::NoOptions)
Gets all property type IDs that where registered for the given class.
Definition: RPropertyTypeId.cpp:273
void setEndParam(double param)
Definition: REllipseEntity.h:160
static RPropertyTypeId PropertyDisplayedColor
Definition: REllipseEntity.h:53
static RPropertyTypeId PropertyHandle
Definition: REllipseEntity.h:43
static const RVector invalid
invalid vector
Definition: RVector.h:322
From
End used to specify from which end of a shape to measure a distance.
Definition: RS.h:263
virtual REllipseData & getData()
Definition: REllipseEntity.h:104
static RPropertyTypeId PropertyReversed
Definition: REllipseEntity.h:67
double getSweep() const
Definition: REllipseEntity.h:228
double getStartParam() const
Definition: REllipseEntity.h:144
Low-level mathematical representation of an open polyline or closed polyline (= polygon).
Definition: RPolyline.h:49
void setStartParam(double param)
Definition: REllipseEntity.h:148
static RPropertyTypeId PropertyMajorPointZ
Definition: REllipseEntity.h:61
static RPropertyTypeId PropertyBlock
Definition: REllipseEntity.h:47
double getDirection2() const
Definition: REllipseEntity.h:196
double getAngle() const
Definition: REllipseEntity.h:132