|
Krita Source Code Documentation
|
The undo / redo command for breaking a subpath by removing the segment. More...
#include <KoPathSegmentBreakCommand.h>
Inheritance diagram for KoPathSegmentBreakCommand:Public Member Functions | |
| KoPathSegmentBreakCommand (const KoPathPointData &pointData, KUndo2Command *parent=0) | |
| void | redo () override |
| redo the command | |
| void | undo () override |
| revert the actions done in redo | |
| ~KoPathSegmentBreakCommand () override | |
Public Member Functions inherited from KUndo2Command | |
| QString | actionText () const |
| virtual bool | canAnnihilateWith (const KUndo2Command *other) const |
| const KUndo2Command * | child (int index) const |
| int | childCount () const |
| virtual QTime | endTime () const |
| KUndo2CommandExtraData * | extraData () const |
| bool | hasParent () const |
| virtual int | id () const |
| virtual bool | isMerged () const |
| KUndo2Command (const KUndo2MagicString &text, KUndo2Command *parent=0) | |
| KUndo2Command (KUndo2Command *parent=0) | |
| virtual QVector< KUndo2Command * > | mergeCommandsVector () const |
| virtual bool | mergeWith (const KUndo2Command *other) |
| virtual void | redoMergedCommands () |
| void | setEndTime () |
| virtual void | setEndTime (const QTime &time) |
| void | setExtraData (KUndo2CommandExtraData *data) |
| void | setText (const KUndo2MagicString &text) |
| void | setTime () |
| virtual void | setTime (const QTime &time) |
| virtual void | setTimedID (int timedID) |
| KUndo2MagicString | text () const |
| virtual QTime | time () const |
| virtual int | timedId () const |
| virtual bool | timedMergeWith (KUndo2Command *other) |
| virtual void | undoMergedCommands () |
| virtual | ~KUndo2Command () |
Private Attributes | |
| bool | m_broken |
| KoPathPointData | m_pointData |
| KoPathPointIndex | m_startIndex |
The undo / redo command for breaking a subpath by removing the segment.
Definition at line 15 of file KoPathSegmentBreakCommand.h.
|
explicit |
Command to break a subpath by removing the segment
The segment following the given point will be removed.
| pointData | describing the point |
| parent | the parent command used for macro commands |
Definition at line 13 of file KoPathSegmentBreakCommand.cpp.
References KoPathShape::isClosedSubpath(), kundo2_i18n(), m_pointData, m_startIndex, KoPathPointData::pathShape, KoPathPointData::pointIndex, KUndo2Command::setText(), and KoPathShape::subpathPointCount().
|
override |
Definition at line 28 of file KoPathSegmentBreakCommand.cpp.
|
overridevirtual |
redo the command
Reimplemented from KUndo2Command.
Definition at line 32 of file KoPathSegmentBreakCommand.cpp.
References KoPathShape::breakAfter(), m_broken, m_pointData, m_startIndex, KoPathShape::normalize(), KoPathShape::openSubpath(), KoPathPointData::pathShape, KoPathPointData::pointIndex, KUndo2Command::redo(), and KoShapeContainer::update().
|
overridevirtual |
revert the actions done in redo
Reimplemented from KUndo2Command.
Definition at line 50 of file KoPathSegmentBreakCommand.cpp.
References KoPathShape::closeSubpath(), KoPathShape::join(), m_broken, m_pointData, m_startIndex, KoPathShape::normalize(), KoPathPointData::pathShape, KoPathPointData::pointIndex, KUndo2Command::undo(), and KoShapeContainer::update().
|
private |
Definition at line 36 of file KoPathSegmentBreakCommand.h.
|
private |
Definition at line 34 of file KoPathSegmentBreakCommand.h.
|
private |
Definition at line 35 of file KoPathSegmentBreakCommand.h.