Krita Source Code Documentation
Loading...
Searching...
No Matches
KoPathControlPointMoveStrategy.h
Go to the documentation of this file.
1/* This file is part of the KDE project
2 * SPDX-FileCopyrightText: 2006 Jan Hambrecht <jaham@gmx.net>
3 * SPDX-FileCopyrightText: 2006, 2007 Thorsten Zachmann <zachmann@kde.org>
4 *
5 * SPDX-License-Identifier: LGPL-2.0-or-later
6 */
7
8#ifndef KOPATHCONTROLPOINTMOVESTRATEGY_H
9#define KOPATHCONTROLPOINTMOVESTRATEGY_H
10
11#include <QPointF>
13#include "KoPathPoint.h"
14#include "KoPathPointData.h"
15
16class KoPathTool;
17
23{
24public:
26 KoPathPoint::PointType type, const QPointF &pos);
28 void handleMouseMove(const QPointF &mouseLocation, Qt::KeyboardModifiers modifiers) override;
29 void finishInteraction(Qt::KeyboardModifiers modifiers) override;
30 KUndo2Command* createCommand() override;
31
32private:
36 QPointF m_move;
37
42 QScopedPointer<KUndo2Command> m_intermediateCommand;
43};
44
45#endif /* KOPATHCONTROLPOINTMOVESTRATEGY_H */
46
Strategy for moving points of a path shape.
KoPathControlPointMoveStrategy(KoPathTool *tool, const KoPathPointData &point, KoPathPoint::PointType type, const QPointF &pos)
void finishInteraction(Qt::KeyboardModifiers modifiers) override
void handleMouseMove(const QPointF &mouseLocation, Qt::KeyboardModifiers modifiers) override
QScopedPointer< KUndo2Command > m_intermediateCommand
QPointF m_lastPosition
the last mouse position
QPointF m_move
the accumulated point move amount
Describe a KoPathPoint by a KoPathShape and its indices.
PointType
the type for identifying part of a KoPathPoint
Definition KoPathPoint.h:47
The position of a path point within a path shape.
Definition KoPathShape.h:63