|
Krita Source Code Documentation
|
snaps to x- or y-coordinates of path points More...
#include <KoSnapStrategy.h>
Inheritance diagram for OrthogonalSnapStrategy:Public Member Functions | |
| QPainterPath | decoration (const KoViewConverter &converter) const override |
| returns the current snap strategy decoration | |
| OrthogonalSnapStrategy () | |
| bool | snap (const QPointF &mousePosition, KoSnapProxy *proxy, qreal maxSnapDistance) override |
Public Member Functions inherited from KoSnapStrategy | |
| KoSnapStrategy (KoSnapGuide::Strategy type) | |
| QPointF | snappedPosition () const |
| returns the snapped position form the last call to snapToPoints | |
| SnapType | snappedType () const |
| KoSnapGuide::Strategy | type () const |
| returns the strategies type | |
| virtual | ~KoSnapStrategy () |
Private Attributes | |
| QLineF | m_hLine |
| QLineF | m_vLine |
Additional Inherited Members | |
Public Types inherited from KoSnapStrategy | |
| enum | SnapType { ToPoint = 0 , ToLine } |
Static Public Member Functions inherited from KoSnapStrategy | |
| static qreal | scalarProduct (const QPointF &p1, const QPointF &p2) |
| static qreal | squareDistance (const QPointF &p1, const QPointF &p2) |
Protected Member Functions inherited from KoSnapStrategy | |
| void | setSnappedPosition (const QPointF &position, SnapType snapType) |
| sets the current snapped position | |
snaps to x- or y-coordinates of path points
Definition at line 65 of file KoSnapStrategy.h.
| OrthogonalSnapStrategy::OrthogonalSnapStrategy | ( | ) |
Definition at line 64 of file KoSnapStrategy.cpp.
|
overridevirtual |
returns the current snap strategy decoration
Implements KoSnapStrategy.
Definition at line 120 of file KoSnapStrategy.cpp.
References decoration(), m_hLine, and m_vLine.
|
overridevirtual |
Implements KoSnapStrategy.
Definition at line 69 of file KoSnapStrategy.cpp.
References m_hLine, m_vLine, KoSnapProxy::pointsFromShape(), KoSnapStrategy::setSnappedPosition(), KoSnapProxy::shapes(), KoSnapStrategy::snappedType(), KoSnapStrategy::ToLine, and KoSnapStrategy::ToPoint.
|
private |
Definition at line 72 of file KoSnapStrategy.h.
|
private |
Definition at line 73 of file KoSnapStrategy.h.