1 #ifndef __DIMDIAMETER_H__
2 #define __DIMDIAMETER_H__
7 * Holds the data that defines a diametric dimension entity.
13 * Default constructor. Leaves the data object uninitialized.
18 * Constructor with initialisation.
20 * @param definitionPoint Definition point of the diametric dimension.
21 * @param leader Leader length.
23 DimDiametricData(const Vector& definitionPoint,
25 this->definitionPoint = definitionPoint;
26 this->leader = leader;
29 friend class DimDiametric;
30 //friend class RS_ActionDimDiametric;
32 friend std::ostream & operator<<(std::ostream & os, const DimDiametricData & dd)
34 os << "(" << dd.definitionPoint << "/" << dd.leader << ")";
39 /** Definition point. */
40 Vector definitionPoint;
46 * Class for diametric dimension entities.
48 * @author Andrew Mustun
50 class DimDiametric: public Dimension
53 DimDiametric(EntityContainer * parent, const DimensionData & d, const DimDiametricData & ed);
54 virtual ~DimDiametric();
56 virtual Entity * clone();
57 virtual RS2::EntityType rtti() const;
58 DimDiametricData getEData() const;
59 virtual VectorSolutions getRefPoints();
60 virtual QString getMeasuredLabel();
61 virtual void update(bool autoText=false);
62 Vector getDefinitionPoint();
64 virtual void move(Vector offset);
65 virtual void rotate(Vector center, double angle);
66 virtual void scale(Vector center, Vector factor);
67 virtual void mirror(Vector axisPoint1, Vector axisPoint2);
68 virtual void moveRef(const Vector & ref, const Vector & offset);
70 friend std::ostream & operator<<(std::ostream & os, const DimDiametric & d);
74 DimDiametricData edata;