|
Krita Source Code Documentation
|
#include <KisToolSelectMagnetic.h>
Inheritance diagram for KisToolSelectMagnetic:Public Slots | |
| void | activate (const QSet< KoShape * > &shapes) override |
| void | deactivate () override |
| void | slotCalculateEdge () |
| void | slotSetAnchorGap (int) |
| void | slotSetFilterRadius (qreal) |
| void | slotSetSearchRadius (int) |
| void | slotSetThreshold (int) |
| void | undoPoints () |
Signals | |
| void | setButtonsEnabled (bool) |
Protected Attributes | |
| KisSelectionToolConfigWidgetHelper | m_widgetHelper |
Protected Attributes inherited from KisToolSelectBase< BaseClass > | |
| SelectionAction | m_selectionActionAlternate |
| KisSelectionToolConfigWidgetHelper | m_widgetHelper |
Private Member Functions | |
| void | calculateCheckPoints (vQPointF points) |
| void | checkIfAnchorIsSelected (QPointF pt) |
| vQPointF | computeEdgeWrapper (QPoint a, QPoint b) |
| void | deleteSelectedAnchor () |
| void | drawAnchors (QPainter &gc) |
| void | finishSelectionAction () |
| void | reEvaluatePoints () |
| void | resetVariables () |
| void | updateCanvas () |
| void | updateContinuedMode () |
| void | updateFeedback () |
| int | updateInitialAnchorBounds (QPoint pt) |
| void | updatePaintPath () |
| void | updateSelectedAnchor () |
Private Attributes | |
| int | m_anchorGap {30} |
| QVector< QPoint > | m_anchorPoints |
| bool | m_complete {false} |
| KConfigGroup | m_configGroup |
| bool | m_continuedMode {false} |
| QPointF | m_cursorOnPress |
| qreal | m_filterRadius {3.0} |
| bool | m_finished {false} |
| QPoint | m_lastAnchor |
| QPointF | m_lastCursorPos |
| KisSignalCompressor | m_mouseHoverCompressor |
| QPainterPath | m_paintPath |
| QVector< vQPointF > | m_pointCollection |
| QVector< QPointF > | m_points |
| int | m_searchRadius {30} |
| bool | m_selected {false} |
| int | m_selectedAnchor {0} |
| QRectF | m_snapBound |
| int | m_threshold {70} |
| QScopedPointer< KisMagneticWorker > | m_worker |
Additional Inherited Members | |
Public Types inherited from KisToolSelectBase< BaseClass > | |
| enum | SampleLayersMode { SampleAllLayers , SampleCurrentLayer , SampleColorLabeledLayers } |
Protected Member Functions inherited from KisToolSelectBase< BaseClass > | |
| virtual bool | isPixelOnly () const |
| virtual bool | usesColorLabels () const |
Definition at line 19 of file KisToolSelectMagnetic.h.
| KisToolSelectMagnetic::KisToolSelectMagnetic | ( | KoCanvasBase * | canvas | ) |
Definition at line 48 of file KisToolSelectMagnetic.cc.
|
overridedefault |
Definition at line 670 of file KisToolSelectMagnetic.cc.
References KisToolSelectBase< BaseClass >::activate(), connect(), m_configGroup, m_mouseHoverCompressor, m_worker, slotCalculateEdge(), and undoPoints().
|
override |
Definition at line 207 of file KisToolSelectMagnetic.cc.
References KisToolSelectBase< BaseClass >::beginPrimaryAction(), KisToolSelectBase< BaseClass >::beginSelectInteraction(), bounds, checkIfAnchorIsSelected(), computeEdgeWrapper(), KisToolSelectBase< BaseClass >::isMovingSelection(), m_anchorPoints, m_complete, m_cursorOnPress, m_lastAnchor, m_lastCursorPos, m_pointCollection, m_points, m_selected, KisTool::PAINT_MODE, reEvaluatePoints(), setButtonsEnabled(), and updateInitialAnchorBounds().
Definition at line 72 of file KisToolSelectMagnetic.cc.
References calculateCheckPoints(), kisDistance(), m_anchorGap, m_anchorPoints, m_lastAnchor, m_pointCollection, m_threshold, m_worker, and reEvaluatePoints().
|
private |
Definition at line 246 of file KisToolSelectMagnetic.cc.
References m_anchorPoints, m_selected, and m_selectedAnchor.
|
private |
Definition at line 186 of file KisToolSelectMagnetic.cc.
References m_filterRadius, m_searchRadius, and m_worker.
|
override |
Definition at line 310 of file KisToolSelectMagnetic.cc.
References KisToolSelectBase< BaseClass >::continuePrimaryAction(), KisToolSelectBase< BaseClass >::isMovingSelection(), kisDistance(), m_anchorGap, m_anchorPoints, m_complete, m_cursorOnPress, m_lastCursorPos, m_mouseHoverCompressor, m_selected, m_selectedAnchor, and KisSignalCompressor::start().
|
override |
Definition at line 722 of file KisToolSelectMagnetic.cc.
References KisOptionCollectionWidget::appendWidget(), KisOptionCollectionWidgetWithHeader::appendWidget(), connect(), KisToolSelectBase< BaseClass >::createOptionWidget(), m_anchorGap, m_configGroup, m_filterRadius, m_searchRadius, m_threshold, requestStrokeCancellation(), requestStrokeEnd(), KisToolSelectBase< BaseClass >::selectionOptionWidget(), setButtonsEnabled(), KisSliderSpinBox::setRange(), KisDoubleSliderSpinBox::setRange(), KisSliderSpinBox::setValue(), KisDoubleSliderSpinBox::setValue(), slotSetAnchorGap(), slotSetFilterRadius(), slotSetSearchRadius(), and slotSetThreshold().
|
overrideslot |
Definition at line 679 of file KisToolSelectMagnetic.cc.
References KisTool::deactivate(), KIS_ASSERT_RECOVER_RETURN, m_continuedMode, resetVariables(), and KisCanvas2::updateCanvas().
|
private |
Definition at line 378 of file KisToolSelectMagnetic.cc.
References computeEdgeWrapper(), m_anchorPoints, m_complete, m_pointCollection, m_selectedAnchor, reEvaluatePoints(), and resetVariables().
|
private |
Definition at line 630 of file KisToolSelectMagnetic.cc.
References KisHandlePainterHelper::drawHandleRect(), KisHandleStyle::highlightedPrimaryHandles(), m_anchorPoints, m_lastCursorPos, KisHandleStyle::primarySelection(), KisHandlePainterHelper::setHandleStyle(), and updateInitialAnchorBounds().
|
override |
Definition at line 340 of file KisToolSelectMagnetic.cc.
References bounds, computeEdgeWrapper(), deleteSelectedAnchor(), KisToolSelectBase< BaseClass >::endPrimaryAction(), finishSelectionAction(), KisSignalCompressor::isActive(), KisToolSelectBase< BaseClass >::isMovingSelection(), m_anchorPoints, m_complete, m_cursorOnPress, m_mouseHoverCompressor, m_pointCollection, m_points, m_selected, m_selectedAnchor, m_snapBound, slotCalculateEdge(), KisSignalCompressor::stop(), and updateSelectedAnchor().
|
private |
Definition at line 473 of file KisToolSelectMagnetic.cc.
References KisAlgebra2D::accumulateBounds(), KisSelectionToolHelper::addSelectionShape(), KisToolSelectBase< BaseClass >::antiAliasSelection(), KisProcessingApplicator::applyCommand(), KisPaintDevice::colorSpace(), KisProcessingApplicator::end(), KisToolSelectBase< BaseClass >::endSelectInteraction(), KisToolSelectBase< BaseClass >::featherSelection(), KisPainter::FillStyleForegroundColor, KisToolSelectBase< BaseClass >::growSelection(), KisTool::HOVER_MODE, KisPixelSelection::invalidateOutlineCache(), KIS_ASSERT_RECOVER_RETURN, KoPathShapeId, kundo2_i18n(), m_complete, m_finished, m_points, KisProcessingApplicator::NONE, KisPainter::paintPainterPath(), PIXEL_SELECTION, KisFeatherSelectionFilter::process(), KisGrowSelectionFilter::process(), KisShrinkSelectionFilter::process(), resetVariables(), KisPixelSelection::selectedRect(), KisViewManager::selection(), KisToolSelectBase< BaseClass >::selectionAction(), KisToolSelectBase< BaseClass >::selectionMode(), KisSelectionToolHelper::selectPixelSelection(), KisStrokeJobData::SEQUENTIAL, KisPainter::setAntiAliasPolygonFill(), KisPainter::setFillStyle(), KisPixelSelection::setOutlineCache(), KisPainter::setPaintColor(), KisPainter::setStrokeStyle(), KisPainter::StrokeStyleNone, KisSelectionToolHelper::tryDeselectCurrentSelection(), KisSelectionToolHelper::tryOverrideSelectionMode(), KisCanvas2::updateCanvas(), KisCanvas2::viewManager(), and KisCursor::waitCursor().
|
override |
Definition at line 56 of file KisToolSelectMagnetic.cc.
References KisToolSelectBase< BaseClass >::isSelecting(), KisToolSelectBase< BaseClass >::keyPressEvent(), and m_continuedMode.
|
override |
Definition at line 163 of file KisToolSelectMagnetic.cc.
References finishSelectionAction(), KisToolSelectBase< BaseClass >::isSelecting(), KisToolSelectBase< BaseClass >::keyReleaseEvent(), m_continuedMode, and m_points.
|
override |
Definition at line 192 of file KisToolSelectMagnetic.cc.
References KisToolSelectBase< BaseClass >::isMovingSelection(), KisToolSelectBase< BaseClass >::isSelecting(), m_lastCursorPos, KisToolSelectBase< BaseClass >::mouseMoveEvent(), and updatePaintPath().
|
override |
Definition at line 614 of file KisToolSelectMagnetic.cc.
References drawAnchors(), m_anchorPoints, m_continuedMode, m_lastCursorPos, m_paintPath, KisTool::PAINT_MODE, and updatePaintPath().
|
private |
Definition at line 463 of file KisToolSelectMagnetic.cc.
References m_pointCollection, m_points, and updatePaintPath().
|
override |
Definition at line 714 of file KisToolSelectMagnetic.cc.
References m_complete, m_finished, resetVariables(), and setButtonsEnabled().
|
override |
Definition at line 705 of file KisToolSelectMagnetic.cc.
References finishSelectionAction(), m_anchorPoints, m_finished, and setButtonsEnabled().
|
override |
Definition at line 876 of file KisToolSelectMagnetic.cc.
References KisCursor::load(), SELECTION_ADD, SELECTION_INTERSECT, SELECTION_SUBTRACT, SELECTION_SYMMETRICDIFFERENCE, and KisToolSelectBase< BaseClass >::selectionAction().
|
private |
Definition at line 586 of file KisToolSelectMagnetic.cc.
References m_anchorPoints, m_complete, m_paintPath, m_pointCollection, and m_points.
|
signal |
|
slot |
Definition at line 326 of file KisToolSelectMagnetic.cc.
References bounds, calculateCheckPoints(), computeEdgeWrapper(), kisDistance(), m_anchorGap, m_lastAnchor, and m_lastCursorPos.
|
slot |
Definition at line 870 of file KisToolSelectMagnetic.cc.
References m_anchorGap, and m_configGroup.
|
slot |
Definition at line 852 of file KisToolSelectMagnetic.cc.
References m_configGroup, and m_filterRadius.
|
slot |
Definition at line 864 of file KisToolSelectMagnetic.cc.
References m_configGroup, and m_searchRadius.
|
slot |
Definition at line 858 of file KisToolSelectMagnetic.cc.
References m_configGroup, and m_threshold.
|
slot |
Definition at line 691 of file KisToolSelectMagnetic.cc.
References m_anchorPoints, m_complete, m_pointCollection, reEvaluatePoints(), and resetVariables().
|
private |
|
private |
Definition at line 658 of file KisToolSelectMagnetic.cc.
References FEEDBACK_LINE_WIDTH, kisGrowRect(), m_lastCursorPos, and m_points.
|
private |
Definition at line 646 of file KisToolSelectMagnetic.cc.
References FEEDBACK_LINE_WIDTH, kisGrowRect(), and m_points.
|
private |
Definition at line 454 of file KisToolSelectMagnetic.cc.
References m_snapBound.
|
private |
Definition at line 595 of file KisToolSelectMagnetic.cc.
References bounds, m_continuedMode, m_paintPath, m_points, updateContinuedMode(), and updateFeedback().
|
private |
Definition at line 419 of file KisToolSelectMagnetic.cc.
References computeEdgeWrapper(), m_anchorPoints, m_complete, m_pointCollection, m_selectedAnchor, and reEvaluatePoints().
|
private |
Definition at line 88 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 77 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 81 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 91 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 78 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 79 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 89 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 83 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 80 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 79 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 93 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 75 of file KisToolSelectMagnetic.h.
Definition at line 92 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 76 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 86 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 82 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 87 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 90 of file KisToolSelectMagnetic.h.
|
private |
Definition at line 85 of file KisToolSelectMagnetic.h.
|
protected |
Definition at line 535 of file kis_tool_select_base.h.
|
private |
Definition at line 84 of file KisToolSelectMagnetic.h.