47 #ifndef VABSTRACTCURVE_H
48 #define VABSTRACTCURVE_H
50 #include <qcompilerdetection.h>
52 #include <QSharedDataPointer>
58 #include "../ifc/ifcdef.h"
59 #include "../vmisc/vmath.h"
77 #ifdef Q_COMPILER_RVALUE_REFS
85 bool reverse =
false);
88 virtual QPainterPath
GetPath()
const;
129 QSharedDataPointer<VAbstractCurveData>
d;
virtual qreal GetEndAngle() const =0
QString getLineWeight() const
getLineWeight return weight of the lines
void SetDuplicate(quint32 number)
virtual QVector< DirectionArrow > DirectionArrows() const
virtual ~VAbstractCurve() Q_DECL_OVERRIDE
virtual QVector< QPointF > IntersectLine(const QLineF &line) const
IntersectLine return list of points for real intersection with line.
virtual QVector< QPointF > getPoints() const =0
static qreal PathLength(const QVector< QPointF > &path)
void SetPenStyle(const QString &penStyle)
VAbstractCurve & operator=(const VAbstractCurve &curve)
virtual qreal GetStartAngle() const =0
VAbstractCurve(const GOType &type, const quint32 &idObject=null_id, const Draw &mode=Draw::Calculation)
virtual void CreateName()=0
void setLineColor(const QString &color)
virtual bool IsIntersectLine(const QLineF &line) const
virtual QString NameForHistory(const QString &toolName) const =0
void setLineWeight(const QString &lineWeight)
setLineWeight set weight of the lines
QString GetPenStyle() const
static QVector< QPointF > ToEnd(const QVector< QPointF > &points, const QPointF &end, bool *ok=nullptr)
quint32 GetDuplicate() const
static QVector< QPointF > FromBegin(const QVector< QPointF > &points, const QPointF &begin, bool *ok=nullptr)
void Swap(VAbstractCurve &curve) Q_DECL_NOTHROW
QSharedDataPointer< VAbstractCurveData > d
virtual QPainterPath GetPath() const
static const qreal lengthCurveDirectionArrow
QString getLineColor() const
qreal GetLengthByPoint(const QPointF &point) const
static bool isPointOnCurve(const QVector< QPointF > &points, const QPointF &p)
static QVector< QPointF > CurveIntersectLine(const QVector< QPointF > &points, const QLineF &line)
static QPainterPath ShowDirection(const QVector< DirectionArrow > &arrows, qreal width)
virtual qreal GetLength() const =0
static QVector< QPointF > GetSegmentPoints(const QVector< QPointF > &points, const QPointF &begin, const QPointF &end, bool reverse=false)
The VGObject class keep information graphical objects.
Q_DECLARE_TYPEINFO(VAbstractCurve, Q_MOVABLE_TYPE)
QPair< QLineF, QLineF > DirectionArrow