#include <DrawSketchHandlerLineSet.h>
Public Types | |
enum | SEGMENT_MODE { SEGMENT_MODE_Arc , SEGMENT_MODE_Line } |
enum | SELECT_MODE { STATUS_SEEK_First , STATUS_SEEK_Second , STATUS_Do , STATUS_Close } |
mode table More... | |
enum | SNAP_MODE { SNAP_MODE_Free , SNAP_MODE_45Degree } |
enum | TRANSITION_MODE { TRANSITION_MODE_Free , TRANSITION_MODE_Tangent , TRANSITION_MODE_Perpendicular_L , TRANSITION_MODE_Perpendicular_R } |
Protected Member Functions | |
void | updateTransitionData (int GeoId, Sketcher::PointPos PosId) |
Protected Member Functions inherited from SketcherGui::DrawSketchHandler | |
virtual QString | getCrosshairCursorSVGName () const |
void | setCursor (const QPixmap &pixmap, int x, int y, bool autoScale=true) |
void | updateCursor () |
updates the actCursor with the icon by calling getCrosshairCursorSVGName(), enabling to set data member dependent icons (i.e. More... | |
void | unsetCursor (void) |
restitutes the cursor that was in use at the moment of starting the DrawSketchHandler (i.e. oldCursor) More... | |
void | applyCursor (void) |
restitutes the DSH cached cursor (e.g. without any tail due to autoconstraints, ...) More... | |
unsigned long | getCrosshairColor () |
returns the color to be used for the crosshair (configurable as a parameter) More... | |
qreal | devicePixelRatio () |
functions to set the cursor to a given svgName (to be migrated to NVI style) More... | |
void | drawEdit (const std::vector< Base::Vector2d > &EditCurve) |
void | drawEdit (const std::list< std::vector< Base::Vector2d > > &list) |
void | drawEdit (const std::vector< Part::Geometry * > &geometries) |
void | drawEditMarkers (const std::vector< Base::Vector2d > &EditMarkers, unsigned int augmentationlevel=0) |
void | setAxisPickStyle (bool on) |
void | moveCursorToSketchPoint (Base::Vector2d point) |
void | preselectAtPoint (Base::Vector2d point) |
void | drawPositionAtCursor (const Base::Vector2d &position) |
void | drawDirectionAtCursor (const Base::Vector2d &position, const Base::Vector2d &origin) |
int | getPreselectPoint (void) const |
int | getPreselectCurve (void) const |
int | getPreselectCross (void) const |
Sketcher::SketchObject * | getSketchObject () |
std::vector< QPixmap > | suggestedConstraintsPixmaps (std::vector< AutoConstraint > &suggestedConstraints) |
Returns constraints icons scaled to width. More... | |
Protected Attributes | |
double | arcRadius |
Base::Vector2d | CenterPoint |
Base::Vector3d | dirVec |
std::vector< Base::Vector2d > | EditCurve |
double | endAngle |
int | firstCurve |
Sketcher::PointPos | firstPosId |
bool | firstsegment |
SELECT_MODE | Mode |
int | previousCurve |
Sketcher::PointPos | previousPosId |
SEGMENT_MODE | SegmentMode |
SNAP_MODE | SnapMode |
double | startAngle |
std::vector< AutoConstraint > | sugConstr1 |
std::vector< AutoConstraint > | sugConstr2 |
bool | suppressTransition |
TRANSITION_MODE | TransitionMode |
std::vector< AutoConstraint > | virtualsugConstr1 |
Protected Attributes inherited from SketcherGui::DrawSketchHandler | |
ViewProviderSketch * | sketchgui |
QCursor | oldCursor |
QCursor | actCursor |
QPixmap | actCursorPixmap |
SketcherGui::DrawSketchHandlerLineSet::DrawSketchHandlerLineSet | ( | ) |
|
virtualdefault |
|
overridevirtual |
Implements SketcherGui::DrawSketchHandler.
References SketcherGui::DrawSketchHandler::applyCursor(), arcRadius, CenterPoint, dirVec, SketcherGui::DrawSketchHandler::drawEdit(), EditCurve, endAngle, Mode, SketcherGui::DrawSketchHandler::renderSuggestConstraintsCursor(), SketcherGui::DrawSketchHandler::seekAutoConstraint(), SEGMENT_MODE_Arc, SEGMENT_MODE_Line, SegmentMode, SketcherGui::DrawSketchHandler::setPositionText(), SNAP_MODE_45Degree, SNAP_MODE_Free, startAngle, STATUS_SEEK_First, STATUS_SEEK_Second, sugConstr1, sugConstr2, suppressTransition, TRANSITION_MODE_Free, TRANSITION_MODE_Perpendicular_L, TRANSITION_MODE_Perpendicular_R, TRANSITION_MODE_Tangent, TransitionMode, Base::Vector2d::x, Base::Vector3< _Precision >::x, Base::Vector2d::y, and Base::Vector3< _Precision >::y.
Referenced by registerPressedKey(), and releaseButton().
|
overridevirtual |
Implements SketcherGui::DrawSketchHandler.
References SketcherGui::DrawSketchHandler::applyCursor(), Sketcher::SketchObject::arePointsCoincident(), Sketcher::Coincident, SketcherGui::DrawSketchHandler::drawEdit(), EditCurve, Sketcher::end, firstCurve, firstPosId, App::GetApplication(), ParameterGrp::GetBool(), Base::Persistence::getClassTypeId(), Sketcher::SketchObject::getGeometry(), Sketcher::SketchObject::getGeoVertexIndex(), SketcherGui::DrawSketchHandler::getHighestCurveIndex(), App::Application::GetParameterGroupByPath(), SketcherGui::DrawSketchHandler::getPreselectCross(), SketcherGui::DrawSketchHandler::getPreselectPoint(), SketcherGui::ViewProviderSketch::getSketchObject(), Base::Persistence::getTypeId(), Mode, Sketcher::none, previousCurve, previousPosId, SketcherGui::ViewProviderSketch::purgeHandler(), SketcherGui::DrawSketchHandler::resetPositionText(), SEGMENT_MODE_Arc, SEGMENT_MODE_Line, SegmentMode, SketcherGui::DrawSketchHandler::sketchgui, SNAP_MODE_Free, Sketcher::start, STATUS_Close, STATUS_Do, STATUS_SEEK_First, STATUS_SEEK_Second, sugConstr1, suppressTransition, TRANSITION_MODE_Free, TRANSITION_MODE_Tangent, TransitionMode, SketcherGui::DrawSketchHandler::unsetCursor(), updateTransitionData(), and virtualsugConstr1.
|
overridevirtual |
Reimplemented from SketcherGui::DrawSketchHandler.
References SketcherGui::DrawSketchHandler::applyCursor(), SketcherGui::DrawSketchHandler::drawEdit(), EditCurve, firstCurve, firstPosId, firstsegment, App::GetApplication(), ParameterGrp::GetBool(), App::Application::GetParameterGroupByPath(), Mode, Sketcher::none, previousCurve, previousPosId, SketcherGui::DrawSketchHandler::quit(), SEGMENT_MODE_Line, SegmentMode, SNAP_MODE_Free, STATUS_SEEK_First, suppressTransition, TRANSITION_MODE_Free, and TransitionMode.
|
overridevirtual |
Reimplemented from SketcherGui::DrawSketchHandler.
References EditCurve, Base::Persistence::getClassTypeId(), Sketcher::SketchObject::getGeometry(), SketcherGui::ViewProviderSketch::getSketchObject(), Base::Persistence::getTypeId(), Mode, mouseMove(), previousCurve, SEGMENT_MODE_Arc, SEGMENT_MODE_Line, SegmentMode, SketcherGui::DrawSketchHandler::sketchgui, SNAP_MODE_Free, STATUS_SEEK_Second, TRANSITION_MODE_Free, TRANSITION_MODE_Perpendicular_L, TRANSITION_MODE_Perpendicular_R, TRANSITION_MODE_Tangent, and TransitionMode.
|
overridevirtual |
Implements SketcherGui::DrawSketchHandler.
References Gui::Command::abortCommand(), SketcherGui::DrawSketchHandler::applyCursor(), arcRadius, SketcherGui::ViewProviderSketch::Autoconstraints, SketcherGui::ViewProviderSketch::AvoidRedundant, CenterPoint, Gui::cmdAppObjectArgs(), Sketcher::Coincident, Gui::Command::commitCommand(), Base::Console(), SketcherGui::Construction, SketcherGui::DrawSketchHandler::createAutoConstraints(), SketcherGui::DrawSketchHandler::drawEdit(), EditCurve, Sketcher::end, endAngle, Base::ConsoleSingleton::Error(), firstCurve, firstPosId, firstsegment, SketcherGui::geometryCreationMode, App::GetApplication(), ParameterGrp::GetBool(), SketcherGui::DrawSketchHandler::getHighestCurveIndex(), Gui::ViewProviderDocumentObject::getObject(), App::Application::GetParameterGroupByPath(), App::PropertyBool::getValue(), Mode, mouseMove(), Sketcher::none, Gui::Command::openCommand(), previousCurve, previousPosId, SketcherGui::ViewProviderSketch::purgeHandler(), draftutils.translate::QT_TRANSLATE_NOOP, SketcherGui::removeRedundantHorizontalVertical(), SketcherGui::DrawSketchHandler::resetPositionText(), SEGMENT_MODE_Arc, SEGMENT_MODE_Line, SegmentMode, SketcherGui::DrawSketchHandler::sketchgui, SNAP_MODE_45Degree, SNAP_MODE_Free, Sketcher::start, startAngle, STATUS_Close, STATUS_Do, STATUS_SEEK_First, STATUS_SEEK_Second, sugConstr1, sugConstr2, suppressTransition, TRANSITION_MODE_Free, TRANSITION_MODE_Perpendicular_L, TRANSITION_MODE_Perpendicular_R, TRANSITION_MODE_Tangent, TransitionMode, SketcherGui::tryAutoRecomputeIfNotSolve(), SketcherGui::DrawSketchHandler::unsetCursor(), updateTransitionData(), virtualsugConstr1, Base::Vector2d::x, and Base::Vector2d::y.
|
protected |
References dirVec, EditCurve, Part::GeomArcOfConic::getCenter(), Base::Persistence::getClassTypeId(), Part::GeomLineSegment::getEndPoint(), Part::GeomArcOfConic::getEndPoint(), Sketcher::SketchObject::getGeometry(), SketcherGui::ViewProviderSketch::getSketchObject(), Part::GeomLineSegment::getStartPoint(), Part::GeomArcOfConic::getStartPoint(), Base::Persistence::getTypeId(), Base::Vector3< _Precision >::Normalize(), Base::Vector3< _Precision >::Set(), SketcherGui::DrawSketchHandler::sketchgui, Sketcher::start, Base::Vector3< _Precision >::x, and Base::Vector3< _Precision >::y.
Referenced by pressButton(), and releaseButton().
|
protected |
Referenced by mouseMove(), and releaseButton().
|
protected |
Referenced by mouseMove(), and releaseButton().
|
protected |
Referenced by mouseMove(), and updateTransitionData().
|
protected |
Referenced by mouseMove(), pressButton(), quit(), registerPressedKey(), releaseButton(), and updateTransitionData().
|
protected |
Referenced by mouseMove(), and releaseButton().
|
protected |
Referenced by pressButton(), quit(), and releaseButton().
|
protected |
Referenced by pressButton(), quit(), and releaseButton().
|
protected |
Referenced by quit(), and releaseButton().
|
protected |
Referenced by mouseMove(), pressButton(), quit(), registerPressedKey(), and releaseButton().
|
protected |
Referenced by pressButton(), quit(), registerPressedKey(), and releaseButton().
|
protected |
Referenced by pressButton(), quit(), and releaseButton().
|
protected |
Referenced by mouseMove(), pressButton(), quit(), registerPressedKey(), and releaseButton().
|
protected |
|
protected |
Referenced by mouseMove(), and releaseButton().
|
protected |
Referenced by mouseMove(), pressButton(), and releaseButton().
|
protected |
Referenced by mouseMove(), and releaseButton().
|
protected |
Referenced by mouseMove(), pressButton(), quit(), and releaseButton().
|
protected |
Referenced by mouseMove(), pressButton(), quit(), registerPressedKey(), and releaseButton().
|
protected |
Referenced by pressButton(), and releaseButton().