Seamly2D
Code documentation
VisToolCubicBezierPath Class Reference

#include <vistoolcubicbezierpath.h>

Inheritance diagram for VisToolCubicBezierPath:
Collaboration diagram for VisToolCubicBezierPath:

Public Types

enum  { Type = UserType + static_cast<int>(Vis::ToolCubicBezierPath) }
 
- Public Types inherited from VisPath
enum  { Type = UserType + static_cast<int>(Vis::Path) }
 
- Public Types inherited from VCurvePathItem
enum  { Type = UserType + static_cast<int>(Vis::CurvePathItem) }
 

Public Member Functions

 VisToolCubicBezierPath (const VContainer *data, QGraphicsItem *parent=nullptr)
 
virtual ~VisToolCubicBezierPath ()
 
virtual void RefreshGeometry () Q_DECL_OVERRIDE
 
void setPath (const VCubicBezierPath &value)
 
VCubicBezierPath getPath ()
 
virtual int type () const Q_DECL_OVERRIDE
 
- Public Member Functions inherited from VisPath
 VisPath (const VContainer *data, QGraphicsItem *parent=nullptr)
 
virtual ~VisPath ()=default
 
- Public Member Functions inherited from Visualization
 Visualization (const VContainer *data)
 
virtual ~Visualization () Q_DECL_EQ_DEFAULT
 
void setObject1Id (const quint32 &value)
 
void setLineStyle (const Qt::PenStyle &value)
 
void setLineWeight (const QString &value)
 
void setScenePos (const QPointF &value)
 
virtual void VisualMode (const quint32 &pointId)
 
void setMainColor (const QColor &value)
 
const VContainergetData () const
 
void setData (const VContainer *data)
 
Mode GetMode () const
 
void SetMode (const Mode &value)
 
QString CurrentToolTip () const
 
- Public Member Functions inherited from VCurvePathItem
 VCurvePathItem (QGraphicsItem *parent=nullptr)
 
virtual ~VCurvePathItem ()=default
 
virtual QPainterPath shape () const Q_DECL_OVERRIDE
 
virtual void paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget=nullptr) Q_DECL_OVERRIDE
 
void SetDirectionArrows (const QVector< QPair< QLineF, QLineF >> &arrows)
 
void SetPoints (const QVector< QPointF > &points)
 

Protected Attributes

QVector< VScaledEllipse * > mainPoints
 
QVector< VScaledEllipse * > ctrlPoints
 
QVector< VScaledLine * > lines
 
VCurvePathItemnewCurveSegment
 
VCubicBezierPath path
 
VScaledLinehelpLine1
 
VScaledLinehelpLine2
 
- Protected Attributes inherited from Visualization
const VContainerdata
 
QPointF scenePos
 
QColor mainColor
 
QColor supportColor
 
Qt::PenStyle lineStyle
 
qreal lineWeight
 
quint32 object1Id
 
QString toolTip
 
Mode mode
 

Private Member Functions

VScaledEllipsegetPoint (QVector< VScaledEllipse * > &points, quint32 i, qreal z=0)
 
VScaledLinegetLine (quint32 i)
 
void Creating (const QVector< VPointF > &pathPoints, int pointsLeft)
 
void RefreshToolTip ()
 

Additional Inherited Members

- Public Slots inherited from Visualization
void mousePos (const QPointF &scenePos)
 
- Signals inherited from Visualization
void ToolTip (const QString &toolTip)
 
- Static Public Member Functions inherited from Visualization
static qreal FindLength (const QString &expression, const QHash< QString, QSharedPointer< VInternalVariable > > *vars)
 
static qreal FindVal (const QString &expression, const QHash< QString, QSharedPointer< VInternalVariable > > *vars)
 
- Protected Member Functions inherited from VisPath
virtual void initPen () Q_DECL_OVERRIDE
 
virtual void AddOnScene () Q_DECL_OVERRIDE
 
VSimplePointGetPoint (QVector< VSimplePoint * > &points, quint32 i, const QColor &color)
 
- Protected Member Functions inherited from Visualization
VScaledEllipseInitPoint (const QColor &color, QGraphicsItem *parent, qreal z=0) const
 
void DrawPoint (QGraphicsEllipseItem *point, const QPointF &pos, const QColor &color, Qt::PenStyle style=Qt::SolidLine)
 
virtual void DrawLine (VScaledLine *lineItem, const QLineF &line, const QColor &color, const qreal &lineWeight, Qt::PenStyle style=Qt::SolidLine)
 
void DrawPath (VCurvePathItem *pathItem, const QPainterPath &path, const QColor &color, Qt::PenStyle style=Qt::SolidLine, const qreal &weight=0.35, Qt::PenCapStyle cap=Qt::SquareCap)
 
void DrawPath (VCurvePathItem *pathItem, const QPainterPath &path, const QVector< DirectionArrow > &directionArrows, const QColor &color, Qt::PenStyle style=Qt::SolidLine, const qreal &weight=0.35, Qt::PenCapStyle cap=Qt::SquareCap)
 
void drawArrowedLine (ArrowedLineItem *item, const QLineF &line, const QColor &color, Qt::PenStyle style=Qt::SolidLine)
 
void drawArrow (const QLineF &axis, QPainterPath &path, const qreal &arrow_size)
 
template<typename Item >
void addItem (Item *item)
 
template<class Item >
ItemInitItem (const QColor &color, QGraphicsItem *parent)
 
- Protected Member Functions inherited from VCurvePathItem
virtual void ScalePenWidth ()
 
- Static Protected Member Functions inherited from Visualization
static VScaledEllipseGetPointItem (QVector< VScaledEllipse * > &points, quint32 i, const QColor &color, QGraphicsItem *parent)
 

Detailed Description

Definition at line 67 of file vistoolcubicbezierpath.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
Type 

Definition at line 80 of file vistoolcubicbezierpath.h.

Constructor & Destructor Documentation

◆ VisToolCubicBezierPath()

VisToolCubicBezierPath::VisToolCubicBezierPath ( const VContainer data,
QGraphicsItem *  parent = nullptr 
)
explicit

◆ ~VisToolCubicBezierPath()

VisToolCubicBezierPath::~VisToolCubicBezierPath ( )
virtual

Definition at line 87 of file vistoolcubicbezierpath.cpp.

References lines, and mainPoints.

Member Function Documentation

◆ Creating()

◆ getLine()

VScaledLine * VisToolCubicBezierPath::getLine ( quint32  i)
private

Definition at line 183 of file vistoolcubicbezierpath.cpp.

References lines, and Visualization::mainColor.

Referenced by RefreshGeometry().

◆ getPath()

VCubicBezierPath VisToolCubicBezierPath::getPath ( )

Definition at line 162 of file vistoolcubicbezierpath.cpp.

References path.

◆ getPoint()

VScaledEllipse * VisToolCubicBezierPath::getPoint ( QVector< VScaledEllipse * > &  points,
quint32  i,
qreal  z = 0 
)
private

◆ RefreshGeometry()

◆ RefreshToolTip()

◆ setPath()

void VisToolCubicBezierPath::setPath ( const VCubicBezierPath value)

Definition at line 153 of file vistoolcubicbezierpath.cpp.

References path, and RefreshToolTip().

◆ type()

virtual int VisToolCubicBezierPath::type ( ) const
inlinevirtual

Reimplemented from VisPath.

Definition at line 79 of file vistoolcubicbezierpath.h.

References Type.

Member Data Documentation

◆ ctrlPoints

QVector<VScaledEllipse *> VisToolCubicBezierPath::ctrlPoints
protected

Definition at line 84 of file vistoolcubicbezierpath.h.

Referenced by Creating(), and RefreshGeometry().

◆ helpLine1

VScaledLine* VisToolCubicBezierPath::helpLine1
protected

Definition at line 88 of file vistoolcubicbezierpath.h.

Referenced by Creating(), and VisToolCubicBezierPath().

◆ helpLine2

VScaledLine* VisToolCubicBezierPath::helpLine2
protected

Definition at line 89 of file vistoolcubicbezierpath.h.

Referenced by Creating(), and VisToolCubicBezierPath().

◆ lines

QVector<VScaledLine *> VisToolCubicBezierPath::lines
protected

Definition at line 85 of file vistoolcubicbezierpath.h.

Referenced by getLine(), and ~VisToolCubicBezierPath().

◆ mainPoints

QVector<VScaledEllipse *> VisToolCubicBezierPath::mainPoints
protected

Definition at line 83 of file vistoolcubicbezierpath.h.

Referenced by RefreshGeometry(), and ~VisToolCubicBezierPath().

◆ newCurveSegment

VCurvePathItem* VisToolCubicBezierPath::newCurveSegment
protected

Definition at line 86 of file vistoolcubicbezierpath.h.

Referenced by Creating(), and VisToolCubicBezierPath().

◆ path

VCubicBezierPath VisToolCubicBezierPath::path
protected

Definition at line 87 of file vistoolcubicbezierpath.h.

Referenced by getPath(), RefreshGeometry(), RefreshToolTip(), and setPath().


The documentation for this class was generated from the following files: