9#include <klocalizedstring.h>
16 , m_pointData1(pointData1)
17 , m_pointData2(pointData2)
QPair< int, int > KoPathPointIndex
void setText(const KUndo2MagicString &text)
Describe a KoPathPoint by a KoPathShape and its indices.
KoPathPointIndex pointIndex
position of the point in the path shape
KoPathShape * pathShape
path shape the path point belongs too
A KoPathPoint represents a point in a path.
PointProperties properties
void setProperties(PointProperties properties)
Set the properties of a point.
The position of a path point within a path shape.
bool breakAfter(const KoPathPointIndex &pointIndex)
Breaks the path after the point index.
int subpathPointCount(int subpathIndex) const
Returns the number of points in a subpath.
bool isClosedSubpath(int subpathIndex) const
Checks if a subpath is closed.
bool reverseSubpath(int subpathIndex)
Reverse subpath.
void recommendPointSelectionChange(const QList< KoPathPointIndex > &newSelection)
virtual QPointF normalize()
Normalizes the path data.
bool moveSubpath(int oldSubpathIndex, int newSubpathIndex)
Moves the position of a subpath within a path.
bool join(int subpathIndex)
Joins the given subpath with the following one.
KoPathPointIndex closeSubpath(const KoPathPointIndex &pointIndex)
Close a open subpath.
KoPathPointIndex openSubpath(const KoPathPointIndex &pointIndex)
Opens a closed subpath.
KoPathPointIndex pathPointIndex(const KoPathPoint *point) const
Returns the path point index of a given path point.
KoPathPoint * pointByIndex(const KoPathPointIndex &pointIndex) const
Returns the path point specified by a path point index.
void update() const override
reimplemented
KoPathPoint::PointProperties m_oldProperties1
bool closeSubpathMode() const
KoSubpathJoinCommand(const KoPathPointData &pointData1, const KoPathPointData &pointData2, KUndo2Command *parent=0)
KoPathPointIndex m_splitIndex
boost::optional< QPointF > m_savedControlPoint1
~KoSubpathJoinCommand() override
boost::optional< QPointF > m_savedControlPoint2
KoPathPointData m_pointData1
void undo() override
revert the actions done in redo
void redo() override
redo the command
KoPathPointData m_pointData2
KoPathPoint::PointProperties m_oldProperties2
#define KIS_SAFE_ASSERT_RECOVER_RETURN(cond)
KUndo2MagicString kundo2_i18n(const char *text)
void makeSymmetric(KoPathPoint *pt, bool copyFromFirst)
void restoreControlPoint(KoPathPoint *pt, bool restoreFirst, boost::optional< QPointF > savedPoint)
boost::optional< QPointF > fetchControlPoint(KoPathPoint *pt, bool takeFirst)