|
Krita Source Code Documentation
|
snaps to intersections of shapes More...
#include <KoSnapStrategy.h>
Inheritance diagram for IntersectionSnapStrategy:Public Member Functions | |
| QPainterPath | decoration (const KoViewConverter &converter) const override |
| returns the current snap strategy decoration | |
| IntersectionSnapStrategy () | |
| 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 () |
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 intersections of shapes
Definition at line 101 of file KoSnapStrategy.h.
| IntersectionSnapStrategy::IntersectionSnapStrategy | ( | ) |
Definition at line 374 of file KoSnapStrategy.cpp.
|
overridevirtual |
returns the current snap strategy decoration
Implements KoSnapStrategy.
Definition at line 412 of file KoSnapStrategy.cpp.
References decoration(), KoSnapStrategy::snappedPosition(), and KoViewConverter::viewToDocument().
|
overridevirtual |
Implements KoSnapStrategy.
Definition at line 379 of file KoSnapStrategy.cpp.
References distance(), s1, KoSnapProxy::segmentsInRect(), KoSnapStrategy::setSnappedPosition(), KoSnapStrategy::squareDistance(), and KoSnapStrategy::ToPoint.