SketcherGui Namespace Reference

Namespaces

namespace  ConstraintFilter
 
namespace  Ui
 

Classes

struct  AnalysisResults
 Struct to hold the results of analysis performed on geometry. More...
 
struct  AutoConstraint
 
class  CarbonCopySelection
 
struct  CoinMapping
 Helper struct containing index conversions (mappings) between {GeoId, PointPos} and MF indices per layer, and VertexId and MF indices per layer. More...
 
class  ConstraintMultiFilterDialog
 
struct  ConstraintParameters
 Struct adapted to store the parameters necessary to create and update constraints. More...
 
class  ConstraintSettingsDialog
 
class  ConstraintView
 
class  CurveConverter
 Class to convert Part::Geometry to Vector2d based collections. More...
 
struct  DrawingParameters
 Struct for storing local drawing parameters. More...
 
class  DrawSketchHandler
 Handler to create new sketch geometry This class has to be reimplemented to create geometry in the sketcher while its in editing. More...
 
class  DrawSketchHandler3PointArc
 
class  DrawSketchHandler3PointCircle
 
class  DrawSketchHandlerArc
 
class  DrawSketchHandlerArcOfEllipse
 
class  DrawSketchHandlerArcOfHyperbola
 
class  DrawSketchHandlerArcOfParabola
 
class  DrawSketchHandlerBox
 
class  DrawSketchHandlerBSpline
 
class  DrawSketchHandlerCarbonCopy
 
class  DrawSketchHandlerCircle
 
class  DrawSketchHandlerEllipse
 This class handles user interaction to draw and save the ellipse. More...
 
class  DrawSketchHandlerExtend
 
class  DrawSketchHandlerExternal
 
class  DrawSketchHandlerFillet
 
class  DrawSketchHandlerLine
 
class  DrawSketchHandlerLineSet
 
class  DrawSketchHandlerOblong
 
class  DrawSketchHandlerPoint
 
class  DrawSketchHandlerRegularPolygon
 
class  DrawSketchHandlerSlot
 
class  DrawSketchHandlerSplitting
 
class  DrawSketchHandlerTrimming
 
class  EditDatumDialog
 
class  EditModeCoinManager
 Helper class for managing the Coin nodes of ViewProviderSketch. More...
 
class  EditModeConstraintCoinManager
 Class for managing the Edit mode coin nodes of ViewProviderSketch relating to constraints. More...
 
class  EditModeGeometryCoinConverter
 Class for creating the Geometry layer into coin nodes. More...
 
class  EditModeGeometryCoinManager
 Class for managing the Edit mode coin nodes of ViewProviderSketch relating to geometry. More...
 
class  EditModeInformationOverlayCoinConverter
 Class for creating the Overlay information layer. More...
 
struct  EditModeScenegraphNodes
 Helper struct adapted to store the pointer to edit mode scenegraph objects. More...
 
class  ElementView
 
class  ExceptionWrongInput
 
class  ExtendSelection
 
class  ExternalSelection
 
class  FilletSelection
 
class  GenericConstraintSelection
 The GenericConstraintSelection class SelectionFilterGate with changeable filters. More...
 
struct  GeometryLayerNodes
 Struct for storing references to the scenegraph nodes necessary for geometry layers. More...
 
class  GeometryLayerParameters
 Helper class to store geometry layers configuration. More...
 
class  Module
 
class  MultiFieldId
 Helper class to store together a field index of a coin multifield object and the coin geometry layer to which it belongs. More...
 
struct  OverlayParameters
 Struct adapted to store the parameters necessary to create and update the information overlay layer. More...
 
class  PropertyConstraintListItem
 
struct  SelIdPair
 
class  ShortcutListener
 
class  SketcherGeneralWidget
 
class  SketcherRegularPolygonDialog
 
class  SketcherSettings
 The SketcherSettings class implements a preference page to change sketcher settings. More...
 
class  SketcherSettingsColors
 The SketcherSettings class implements a preference page to change sketcher settings. More...
 
class  SketcherSettingsDisplay
 The SketcherSettings class implements a preference page to change sketcher display settings. More...
 
class  SketcherValidation
 
class  SketchMirrorDialog
 
class  SketchOrientationDialog
 
class  SketchRectangularArrayDialog
 
struct  SketchSelection
 
class  SoDatumLabel
 
class  SoZoomTranslation
 
class  SplittingSelection
 
class  TaskDlgEditSketch
 simulation dialog for the TaskView More...
 
class  TaskSketcherConstraints
 
class  TaskSketcherElements
 
class  TaskSketcherGeneral
 
class  TaskSketcherMessages
 
class  TaskSketcherSolverAdvanced
 
class  TaskSketcherValidation
 
class  TrimmingSelection
 
class  Ui_ConstraintMultiFilterDialog
 
class  Ui_ConstraintSettingsDialog
 
class  Ui_InsertDatum
 
class  Ui_SketcherRegularPolygonDialog
 
class  Ui_SketcherSettings
 
class  Ui_SketcherSettingsColors
 
class  Ui_SketcherSettingsDisplay
 
class  Ui_SketchMirrorDialog
 
class  Ui_SketchOrientationDialog
 
class  Ui_SketchRectangularArrayDialog
 
class  Ui_TaskSketcherConstraints
 
class  Ui_TaskSketcherElements
 
class  Ui_TaskSketcherGeneral
 
class  Ui_TaskSketcherValidation
 
class  ViewProviderCustom
 
class  ViewProviderSketch
 The Sketch ViewProvider. More...
 
class  ViewProviderSketchCoinAttorney
 Attorney class for limiting access to viewprovider. More...
 
class  ViewProviderSketchDrawSketchHandlerAttorney
 In order to enforce a certain degree of encapsulation and promote a not too tight coupling, while still allowing well defined collaboration, DrawSketchHandler accesses ViewProviderSketch via this Attorney class. More...
 
class  ViewProviderSketchGeometryExtension
 
class  ViewProviderSketchShortcutListenerAttorney
 
class  Workbench
 

Typedefs

using GeoList = Sketcher::GeoList
 
using GeoListFacade = Sketcher::GeoListFacade
 
typedef Gui::ViewProviderPythonFeatureT< ViewProviderCustomViewProviderCustomPython
 
typedef Gui::ViewProviderPythonFeatureT< ViewProviderSketchViewProviderPython
 

Enumerations

enum  ConstraintCreationMode { Driving , Reference }
 
enum  GeometryCreationMode { Normal , Construction }
 
enum  SelType {
  SelUnknown = 0 , SelVertex = 1 , SelVertexOrRoot = 64 , SelRoot = 2 ,
  SelEdge = 4 , SelEdgeOrAxis = 128 , SelHAxis = 8 , SelVAxis = 16 ,
  SelExternalEdge = 32
}
 The SelType enum Types of sketch elements that can be (pre)selected. More...
 

Functions

void ActivateHandler (Gui::Document *doc, DrawSketchHandler *handler)
 
void addSketcherWorkbenchBSplines (Gui::MenuItem &bspline)
 
void addSketcherWorkbenchBSplines (Gui::ToolBarItem &bspline)
 
void addSketcherWorkbenchConstraints (Gui::MenuItem &cons)
 
void addSketcherWorkbenchConstraints (Gui::ToolBarItem &cons)
 
void addSketcherWorkbenchGeometries (Gui::MenuItem &geom)
 
void addSketcherWorkbenchGeometries (Gui::ToolBarItem &geom)
 
void addSketcherWorkbenchSketchActions (Gui::MenuItem &sketch)
 
void addSketcherWorkbenchSketchActions (Gui::ToolBarItem &sketch)
 
void addSketcherWorkbenchTools (Gui::MenuItem &consaccel)
 
void addSketcherWorkbenchTools (Gui::ToolBarItem &consaccel)
 
void addSketcherWorkbenchVirtualSpace (Gui::MenuItem &virtualspace)
 
void addSketcherWorkbenchVirtualSpace (Gui::ToolBarItem &virtualspace)
 
bool areAllPointsOrSegmentsFixed (const Sketcher::SketchObject *Obj, int GeoId1, int GeoId2, int GeoId3)
 
bool areBothPointsOrSegmentsFixed (const Sketcher::SketchObject *Obj, int GeoId1, int GeoId2)
 
bool checkBothExternal (int GeoId1, int GeoId2)
 
bool checkBothExternalOrBSplinePoints (const Sketcher::SketchObject *Obj, int GeoId1, int GeoId2)
 
bool checkConstraint (const std::vector< Sketcher::Constraint * > &vals, Sketcher::ConstraintType type, int geoid, Sketcher::PointPos pos)
 Checks whether there is a constraint of the given type with a First element geoid and a FirstPos PosId. More...
 
void ConstraintToAttachment (Sketcher::GeoElementId element, Sketcher::GeoElementId attachment, double distance, App::DocumentObject *obj)
 
void doEndpointTangency (Sketcher::SketchObject *Obj, int GeoId1, int GeoId2, Sketcher::PointPos PosId1, Sketcher::PointPos PosId2)
 Does an endpoint-to-endpoint tangency. More...
 
void doEndpointToEdgeTangency (Sketcher::SketchObject *Obj, int GeoId1, Sketcher::PointPos PosId1, int GeoId2)
 Does an endpoint-edge tangency. More...
 
void getIdsFromName (const std::string &name, const Sketcher::SketchObject *Obj, int &GeoId, Sketcher::PointPos &PosId)
 
double GetPointAngle (const Base::Vector2d &p1, const Base::Vector2d &p2)
 
SketcherGui::ViewProviderSketchgetSketchViewprovider (Gui::Document *doc)
 
std::string getStrippedPythonExceptionString (const Base::Exception &)
 
PyObjectinitModule ()
 
bool isBsplineKnot (const Sketcher::SketchObject *Obj, int GeoId)
 Checks if GeoId corresponds to a B-Spline knot. More...
 
bool isBsplineKnotOrEndPoint (const Sketcher::SketchObject *Obj, int GeoId, Sketcher::PointPos PosId)
 Checks if the (GeoId, PosId) pair corresponds to a B-Spline knot, including first and last knots. More...
 
bool isBsplinePole (const Part::Geometry *geo)
 
bool isBsplinePole (const Sketcher::SketchObject *Obj, int GeoId)
 
bool isCommandActive (Gui::Document *doc, bool actsOnSelection=false)
 
bool isEdge (int GeoId, Sketcher::PointPos PosId)
 
bool IsPointAlreadyOnCurve (int GeoIdCurve, int GeoIdPoint, Sketcher::PointPos PosIdPoint, Sketcher::SketchObject *Obj)
 
bool isPointOrSegmentFixed (const Sketcher::SketchObject *Obj, int GeoId)
 
bool isSimpleVertex (const Sketcher::SketchObject *Obj, int GeoId, Sketcher::PointPos PosId)
 
bool isVertex (int GeoId, Sketcher::PointPos PosId)
 
void makeTangentToArcOfEllipseviaNewPoint (Sketcher::SketchObject *Obj, const Part::GeomArcOfEllipse *aoe, const Part::Geometry *geom2, int geoId1, int geoId2)
 Makes a tangency constraint using external construction line between aoe => an arc of ellipse geom2 => any of an arc of ellipse, a circle, or an arc (of circle) geoId1 => geoid of the arc of ellipse geoId2 => geoid of geom2 NOTE: A command must be opened before calling this function, which this function commits or aborts as appropriate. More...
 
void makeTangentToArcOfHyperbolaviaNewPoint (Sketcher::SketchObject *Obj, const Part::GeomArcOfHyperbola *aoh, const Part::Geometry *geom2, int geoId1, int geoId2)
 Makes a tangency constraint using external construction line between aoh => an arc of hyperbola geom2 => any of an arc of hyperbola, an arc of ellipse, a circle, or an arc (of circle) geoId1 => geoid of the arc of hyperbola geoId2 => geoid of geom2 NOTE: A command must be opened before calling this function, which this function commits or aborts as appropriate. More...
 
void makeTangentToArcOfParabolaviaNewPoint (Sketcher::SketchObject *Obj, const Part::GeomArcOfParabola *aop, const Part::Geometry *geom2, int geoId1, int geoId2)
 Makes a simple tangency constraint using extra point + tangent via point aop => an arc of parabola geom2 => any of an arc of parabola, an arc of hyperbola an arc of ellipse, a circle, or an arc (of circle) geoId1 => geoid of the arc of parabola geoId2 => geoid of geom2 NOTE: A command must be opened before calling this function, which this function commits or aborts as appropriate. More...
 
void makeTangentToEllipseviaNewPoint (Sketcher::SketchObject *Obj, const Part::GeomEllipse *ellipse, const Part::Geometry *geom2, int geoId1, int geoId2)
 Makes a tangency constraint using external construction line between ellipse => an ellipse geom2 => any of an ellipse, an arc of ellipse, a circle, or an arc (of circle) geoId1 => geoid of the ellipse geoId2 => geoid of geom2 NOTE: A command must be opened before calling this function, which this function commits or aborts as appropriate. More...
 
void notifyConstraintSubstitutions (const QString &message)
 shows constraint substitution information dialog box, enabling the user to forgo further notifications More...
 
bool ReleaseHandler (Gui::Document *doc)
 Release any currently-active handler for the document. More...
 
void removeRedundantHorizontalVertical (Sketcher::SketchObject *psketch, std::vector< AutoConstraint > &sug1, std::vector< AutoConstraint > &sug2)
 
template<typename T >
void SketcherAddWorkbenchBSplines (T &bspline)
 
template<>
void SketcherAddWorkbenchBSplines< Gui::MenuItem > (Gui::MenuItem &bspline)
 
template<>
void SketcherAddWorkbenchBSplines< Gui::ToolBarItem > (Gui::ToolBarItem &bspline)
 
template<typename T >
void SketcherAddWorkbenchConstraints (T &cons)
 
template<>
void SketcherAddWorkbenchConstraints< Gui::MenuItem > (Gui::MenuItem &cons)
 
template<>
void SketcherAddWorkbenchConstraints< Gui::ToolBarItem > (Gui::ToolBarItem &cons)
 
template<typename T >
void SketcherAddWorkbenchGeometries (T &geom)
 
template<typename T >
void SketcherAddWorkbenchSketchActions (T &sketch)
 
template<typename T >
void SketcherAddWorkbenchTools (T &consaccel)
 
template<>
void SketcherAddWorkbenchTools< Gui::MenuItem > (Gui::MenuItem &consaccel)
 
template<>
void SketcherAddWorkbenchTools< Gui::ToolBarItem > (Gui::ToolBarItem &consaccel)
 
template<typename T >
void SketcherAddWorkbenchVirtualSpace (T &virtualspace)
 
template<>
void SketcherAddWorkbenchVirtualSpace< Gui::MenuItem > (Gui::MenuItem &virtualspace)
 
template<>
void SketcherAddWorkbenchVirtualSpace< Gui::ToolBarItem > (Gui::ToolBarItem &virtualspace)
 
template<typename T >
void SketcherAddWorkspaceArcs (T &geom)
 
template<>
void SketcherAddWorkspaceArcs< Gui::MenuItem > (Gui::MenuItem &geom)
 
template<>
void SketcherAddWorkspaceArcs< Gui::ToolBarItem > (Gui::ToolBarItem &geom)
 
template<typename T >
void SketcherAddWorkspaceFillets (T &geom)
 
template<>
void SketcherAddWorkspaceFillets< Gui::MenuItem > (Gui::MenuItem &geom)
 
template<>
void SketcherAddWorkspaceFillets< Gui::ToolBarItem > (Gui::ToolBarItem &geom)
 
template<typename T >
void SketcherAddWorkspaceRectangles (T &geom)
 
template<>
void SketcherAddWorkspaceRectangles< Gui::MenuItem > (Gui::MenuItem &geom)
 
template<>
void SketcherAddWorkspaceRectangles< Gui::ToolBarItem > (Gui::ToolBarItem &geom)
 
template<typename T >
void SketcherAddWorkspaceRegularPolygon (T &geom)
 
template<>
void SketcherAddWorkspaceRegularPolygon< Gui::MenuItem > (Gui::MenuItem &geom)
 
template<>
void SketcherAddWorkspaceRegularPolygon< Gui::ToolBarItem > (Gui::ToolBarItem &geom)
 
template<typename T >
void SketcherAddWorkspaceSketchExtra (T &)
 
template<>
void SketcherAddWorkspaceSketchExtra< Gui::MenuItem > (Gui::MenuItem &sketch)
 
template<>
void SketcherAddWorkspaceSketchExtra< Gui::ToolBarItem > (Gui::ToolBarItem &sketch)
 
Attacher::eMapMode SuggestAutoMapMode (Attacher::SuggestResult::eSuggestResult *pMsgId=nullptr, QString *message=nullptr, std::vector< Attacher::eMapMode > *allmodes=nullptr)
 
bool tryAutoRecompute (Sketcher::SketchObject *obj)
 This function tries to auto-recompute the active document if the option is set in the user parameter. More...
 
bool tryAutoRecompute (Sketcher::SketchObject *obj, bool &autoremoveredundants)
 Same as the other overload, but also returns whether redundants shall be removed or not. More...
 
void tryAutoRecomputeIfNotSolve (Sketcher::SketchObject *obj)
 This function tries to auto-recompute as tryAutoRecompute. More...
 

Variables

GeometryCreationMode geometryCreationMode =Normal
 

Typedef Documentation

◆ GeoList

◆ GeoListFacade

◆ ViewProviderCustomPython

◆ ViewProviderPython

Enumeration Type Documentation

◆ ConstraintCreationMode

Enumerator
Driving 
Reference 

◆ GeometryCreationMode

Enumerator
Normal 
Construction 

◆ SelType

The SelType enum Types of sketch elements that can be (pre)selected.

The root/origin and the axes are put up separately so that they can be specifically disallowed, for example, when in lock, horizontal, or vertical constraint modes.

Enumerator
SelUnknown 
SelVertex 
SelVertexOrRoot 
SelRoot 
SelEdge 
SelEdgeOrAxis 
SelHAxis 
SelVAxis 
SelExternalEdge 

Function Documentation

◆ ActivateHandler()

◆ addSketcherWorkbenchBSplines() [1/2]

void SketcherGui::addSketcherWorkbenchBSplines ( Gui::MenuItem bspline)

◆ addSketcherWorkbenchBSplines() [2/2]

void SketcherGui::addSketcherWorkbenchBSplines ( Gui::ToolBarItem bspline)

◆ addSketcherWorkbenchConstraints() [1/2]

void SketcherGui::addSketcherWorkbenchConstraints ( Gui::MenuItem cons)

◆ addSketcherWorkbenchConstraints() [2/2]

void SketcherGui::addSketcherWorkbenchConstraints ( Gui::ToolBarItem cons)

◆ addSketcherWorkbenchGeometries() [1/2]

void SketcherGui::addSketcherWorkbenchGeometries ( Gui::MenuItem geom)

◆ addSketcherWorkbenchGeometries() [2/2]

void SketcherGui::addSketcherWorkbenchGeometries ( Gui::ToolBarItem geom)

◆ addSketcherWorkbenchSketchActions() [1/2]

void SketcherGui::addSketcherWorkbenchSketchActions ( Gui::MenuItem sketch)

◆ addSketcherWorkbenchSketchActions() [2/2]

void SketcherGui::addSketcherWorkbenchSketchActions ( Gui::ToolBarItem sketch)

◆ addSketcherWorkbenchTools() [1/2]

void SketcherGui::addSketcherWorkbenchTools ( Gui::MenuItem consaccel)

◆ addSketcherWorkbenchTools() [2/2]

void SketcherGui::addSketcherWorkbenchTools ( Gui::ToolBarItem consaccel)

◆ addSketcherWorkbenchVirtualSpace() [1/2]

void SketcherGui::addSketcherWorkbenchVirtualSpace ( Gui::MenuItem virtualspace)

◆ addSketcherWorkbenchVirtualSpace() [2/2]

void SketcherGui::addSketcherWorkbenchVirtualSpace ( Gui::ToolBarItem virtualspace)

◆ areAllPointsOrSegmentsFixed()

◆ areBothPointsOrSegmentsFixed()

◆ checkBothExternal()

bool SketcherGui::checkBothExternal ( int  GeoId1,
int  GeoId2 
)

◆ checkBothExternalOrBSplinePoints()

bool SketcherGui::checkBothExternalOrBSplinePoints ( const Sketcher::SketchObject Obj,
int  GeoId1,
int  GeoId2 
)

References isBsplineKnot().

◆ checkConstraint()

bool SketcherGui::checkConstraint ( const std::vector< Sketcher::Constraint * > &  vals,
Sketcher::ConstraintType  type,
int  geoid,
Sketcher::PointPos  pos 
)

Checks whether there is a constraint of the given type with a First element geoid and a FirstPos PosId.

Referenced by CmdSketcherConstrainBlock::activated(), CmdSketcherConstrainBlock::applyConstraint(), areAllPointsOrSegmentsFixed(), areBothPointsOrSegmentsFixed(), and isPointOrSegmentFixed().

◆ ConstraintToAttachment()

◆ doEndpointTangency()

void SketcherGui::doEndpointTangency ( Sketcher::SketchObject Obj,
int  GeoId1,
int  GeoId2,
Sketcher::PointPos  PosId1,
Sketcher::PointPos  PosId2 
)

◆ doEndpointToEdgeTangency()

void SketcherGui::doEndpointToEdgeTangency ( Sketcher::SketchObject Obj,
int  GeoId1,
Sketcher::PointPos  PosId1,
int  GeoId2 
)

◆ getIdsFromName()

◆ GetPointAngle()

◆ getSketchViewprovider()

SketcherGui::ViewProviderSketch * SketcherGui::getSketchViewprovider ( Gui::Document doc)

◆ getStrippedPythonExceptionString()

std::string SketcherGui::getStrippedPythonExceptionString ( const Base::Exception e)

◆ initModule()

PyObject * SketcherGui::initModule ( )

◆ isBsplineKnot()

◆ isBsplineKnotOrEndPoint()

bool SketcherGui::isBsplineKnotOrEndPoint ( const Sketcher::SketchObject Obj,
int  GeoId,
Sketcher::PointPos  PosId 
)

Checks if the (GeoId, PosId) pair corresponds to a B-Spline knot, including first and last knots.

References Sketcher::end, Base::Persistence::getClassTypeId(), Sketcher::SketchObject::getGeometry(), Base::Persistence::getTypeId(), isBsplineKnot(), and Sketcher::start.

◆ isBsplinePole() [1/2]

◆ isBsplinePole() [2/2]

bool SketcherGui::isBsplinePole ( const Sketcher::SketchObject Obj,
int  GeoId 
)

◆ isCommandActive()

bool SketcherGui::isCommandActive ( Gui::Document doc,
bool  actsOnSelection = false 
)

◆ isEdge()

◆ IsPointAlreadyOnCurve()

◆ isPointOrSegmentFixed()

◆ isSimpleVertex()

◆ isVertex()

◆ makeTangentToArcOfEllipseviaNewPoint()

void SketcherGui::makeTangentToArcOfEllipseviaNewPoint ( Sketcher::SketchObject Obj,
const Part::GeomArcOfEllipse aoe,
const Part::Geometry geom2,
int  geoId1,
int  geoId2 
)

Makes a tangency constraint using external construction line between aoe => an arc of ellipse geom2 => any of an arc of ellipse, a circle, or an arc (of circle) geoId1 => geoid of the arc of ellipse geoId2 => geoid of geom2 NOTE: A command must be opened before calling this function, which this function commits or aborts as appropriate.

Makes a simple tangency constraint using extra point + tangent via point aoe => an arc of ellipse geom2 => any of an arc of ellipse, a circle, or an arc (of circle) geoId1 => geoid of the arc of ellipse geoId2 => geoid of geom2 NOTE: A command must be opened before calling this function, which this function commits or aborts as appropriate.

The reason is for compatibility reasons with other code e.g. "Autoconstraints" in DrawSketchHandler.cpp

References Gui::Command::abortCommand(), Gui::cmdAppObjectArgs(), Gui::Command::commitCommand(), Base::Console(), Base::ConsoleSingleton::Error(), Part::GeomArcOfConic::getCenter(), Base::Persistence::getClassTypeId(), Sketcher::SketchObject::getHighestCurveIndex(), Part::GeomArcOfEllipse::getMajorAxisDir(), Part::GeomArcOfEllipse::getMajorRadius(), Part::GeomArcOfEllipse::getMinorRadius(), Base::Persistence::getTypeId(), Sketcher::start, tryAutoRecompute(), Base::Vector3< _Precision >::x, and Base::Vector3< _Precision >::y.

Referenced by CmdSketcherConstrainTangent::activated(), and SketcherGui::DrawSketchHandler::createAutoConstraints().

◆ makeTangentToArcOfHyperbolaviaNewPoint()

void SketcherGui::makeTangentToArcOfHyperbolaviaNewPoint ( Sketcher::SketchObject Obj,
const Part::GeomArcOfHyperbola aoh,
const Part::Geometry geom2,
int  geoId1,
int  geoId2 
)

Makes a tangency constraint using external construction line between aoh => an arc of hyperbola geom2 => any of an arc of hyperbola, an arc of ellipse, a circle, or an arc (of circle) geoId1 => geoid of the arc of hyperbola geoId2 => geoid of geom2 NOTE: A command must be opened before calling this function, which this function commits or aborts as appropriate.

Makes a simple tangency constraint using extra point + tangent via point aoh => an arc of hyperbola geom2 => any of an arc of hyperbola, an arc of ellipse, a circle, or an arc (of circle) geoId1 => geoid of the arc of hyperbola geoId2 => geoid of geom2 NOTE: A command must be opened before calling this function, which this function commits or aborts as appropriate.

The reason is for compatibility reasons with other code e.g. "Autoconstraints" in DrawSketchHandler.cpp

References Gui::Command::abortCommand(), Gui::cmdAppObjectArgs(), Gui::Command::commitCommand(), Base::Console(), Base::ConsoleSingleton::Error(), Part::GeomArcOfConic::getCenter(), Base::Persistence::getClassTypeId(), Sketcher::SketchObject::getHighestCurveIndex(), Part::GeomArcOfHyperbola::getMajorAxisDir(), Part::GeomArcOfHyperbola::getMajorRadius(), Part::GeomArcOfHyperbola::getMinorRadius(), Base::Persistence::getTypeId(), Sketcher::start, tryAutoRecompute(), Base::Vector3< _Precision >::x, and Base::Vector3< _Precision >::y.

Referenced by CmdSketcherConstrainTangent::activated(), and CmdSketcherConstrainTangent::applyConstraint().

◆ makeTangentToArcOfParabolaviaNewPoint()

void SketcherGui::makeTangentToArcOfParabolaviaNewPoint ( Sketcher::SketchObject Obj,
const Part::GeomArcOfParabola aop,
const Part::Geometry geom2,
int  geoId1,
int  geoId2 
)

Makes a simple tangency constraint using extra point + tangent via point aop => an arc of parabola geom2 => any of an arc of parabola, an arc of hyperbola an arc of ellipse, a circle, or an arc (of circle) geoId1 => geoid of the arc of parabola geoId2 => geoid of geom2 NOTE: A command must be opened before calling this function, which this function commits or aborts as appropriate.

The reason is for compatibility reasons with other code e.g. "Autoconstraints" in DrawSketchHandler.cpp

References Gui::Command::abortCommand(), Gui::cmdAppObjectArgs(), Gui::Command::commitCommand(), Base::Console(), Base::ConsoleSingleton::Error(), Part::GeomArcOfConic::getCenter(), Base::Persistence::getClassTypeId(), Part::GeomArcOfParabola::getFocus(), Sketcher::SketchObject::getHighestCurveIndex(), Part::GeomArcOfHyperbola::getMajorAxisDir(), Part::GeomArcOfHyperbola::getMajorRadius(), Part::GeomArcOfHyperbola::getMinorRadius(), Base::Persistence::getTypeId(), Sketcher::start, tryAutoRecompute(), Base::Vector3< _Precision >::x, and Base::Vector3< _Precision >::y.

Referenced by CmdSketcherConstrainTangent::activated(), and CmdSketcherConstrainTangent::applyConstraint().

◆ makeTangentToEllipseviaNewPoint()

void SketcherGui::makeTangentToEllipseviaNewPoint ( Sketcher::SketchObject Obj,
const Part::GeomEllipse ellipse,
const Part::Geometry geom2,
int  geoId1,
int  geoId2 
)

Makes a tangency constraint using external construction line between ellipse => an ellipse geom2 => any of an ellipse, an arc of ellipse, a circle, or an arc (of circle) geoId1 => geoid of the ellipse geoId2 => geoid of geom2 NOTE: A command must be opened before calling this function, which this function commits or aborts as appropriate.

Makes a simple tangency constraint using extra point + tangent via point ellipse => an ellipse geom2 => any of an ellipse, an arc of ellipse, a circle, or an arc (of circle) geoId1 => geoid of the ellipse geoId2 => geoid of geom2 NOTE: A command must be opened before calling this function, which this function commits or aborts as appropriate.

The reason is for compatibility reasons with other code e.g. "Autoconstraints" in DrawSketchHandler.cpp

References Gui::Command::abortCommand(), Gui::cmdAppObjectArgs(), Gui::Command::commitCommand(), Base::Console(), Base::ConsoleSingleton::Error(), Base::Persistence::getClassTypeId(), Sketcher::SketchObject::getHighestCurveIndex(), Base::Persistence::getTypeId(), Sketcher::start, tryAutoRecompute(), Base::Vector3< _Precision >::x, and Base::Vector3< _Precision >::y.

Referenced by CmdSketcherConstrainTangent::activated(), CmdSketcherConstrainTangent::applyConstraint(), and SketcherGui::DrawSketchHandler::createAutoConstraints().

◆ notifyConstraintSubstitutions()

void SketcherGui::notifyConstraintSubstitutions ( const QString &  message)

◆ ReleaseHandler()

bool SketcherGui::ReleaseHandler ( Gui::Document doc)

Release any currently-active handler for the document.

Returns true if a handler was released, and false if not

References Base::Persistence::getClassTypeId(), SketcherGui::ViewProviderSketch::getSketchMode(), and SketcherGui::ViewProviderSketch::purgeHandler().

Referenced by SketcherGui::ConstraintView::contextMenuEvent().

◆ removeRedundantHorizontalVertical()

◆ SketcherAddWorkbenchBSplines()

template<typename T >
void SketcherGui::SketcherAddWorkbenchBSplines ( T &  bspline)

◆ SketcherAddWorkbenchBSplines< Gui::MenuItem >()

◆ SketcherAddWorkbenchBSplines< Gui::ToolBarItem >()

◆ SketcherAddWorkbenchConstraints()

template<typename T >
void SketcherGui::SketcherAddWorkbenchConstraints ( T &  cons)

◆ SketcherAddWorkbenchConstraints< Gui::MenuItem >()

◆ SketcherAddWorkbenchConstraints< Gui::ToolBarItem >()

◆ SketcherAddWorkbenchGeometries()

template<typename T >
void SketcherGui::SketcherAddWorkbenchGeometries ( T &  geom)

◆ SketcherAddWorkbenchSketchActions()

template<typename T >
void SketcherGui::SketcherAddWorkbenchSketchActions ( T &  sketch)

◆ SketcherAddWorkbenchTools()

template<typename T >
void SketcherGui::SketcherAddWorkbenchTools ( T &  consaccel)

◆ SketcherAddWorkbenchTools< Gui::MenuItem >()

◆ SketcherAddWorkbenchTools< Gui::ToolBarItem >()

◆ SketcherAddWorkbenchVirtualSpace()

template<typename T >
void SketcherGui::SketcherAddWorkbenchVirtualSpace ( T &  virtualspace)

◆ SketcherAddWorkbenchVirtualSpace< Gui::MenuItem >()

◆ SketcherAddWorkbenchVirtualSpace< Gui::ToolBarItem >()

◆ SketcherAddWorkspaceArcs()

template<typename T >
void SketcherGui::SketcherAddWorkspaceArcs ( T &  geom)

◆ SketcherAddWorkspaceArcs< Gui::MenuItem >()

◆ SketcherAddWorkspaceArcs< Gui::ToolBarItem >()

◆ SketcherAddWorkspaceFillets()

template<typename T >
void SketcherGui::SketcherAddWorkspaceFillets ( T &  geom)

◆ SketcherAddWorkspaceFillets< Gui::MenuItem >()

◆ SketcherAddWorkspaceFillets< Gui::ToolBarItem >()

◆ SketcherAddWorkspaceRectangles()

template<typename T >
void SketcherGui::SketcherAddWorkspaceRectangles ( T &  geom)

◆ SketcherAddWorkspaceRectangles< Gui::MenuItem >()

◆ SketcherAddWorkspaceRectangles< Gui::ToolBarItem >()

◆ SketcherAddWorkspaceRegularPolygon()

template<typename T >
void SketcherGui::SketcherAddWorkspaceRegularPolygon ( T &  geom)

◆ SketcherAddWorkspaceRegularPolygon< Gui::MenuItem >()

◆ SketcherAddWorkspaceRegularPolygon< Gui::ToolBarItem >()

◆ SketcherAddWorkspaceSketchExtra()

template<typename T >
void SketcherGui::SketcherAddWorkspaceSketchExtra ( T &  )

◆ SketcherAddWorkspaceSketchExtra< Gui::MenuItem >()

◆ SketcherAddWorkspaceSketchExtra< Gui::ToolBarItem >()

◆ SuggestAutoMapMode()

◆ tryAutoRecompute() [1/2]

bool SketcherGui::tryAutoRecompute ( Sketcher::SketchObject obj)

This function tries to auto-recompute the active document if the option is set in the user parameter.

If the option is not set nothing will be done

Returns
true if a recompute was undertaken, false if not.

References tryAutoRecompute().

Referenced by CmdSketcherConstrainHorizontal::activated(), CmdSketcherConstrainVertical::activated(), CmdSketcherConstrainLock::activated(), CmdSketcherConstrainBlock::activated(), CmdSketcherConstrainCoincident::activated(), CmdSketcherConstrainParallel::activated(), CmdSketcherConstrainPerpendicular::activated(), CmdSketcherConstrainTangent::activated(), CmdSketcherConstrainEqual::activated(), CmdSketcherConstrainSymmetric::activated(), CmdSketcherConstrainHorizontal::applyConstraint(), CmdSketcherConstrainVertical::applyConstraint(), CmdSketcherConstrainBlock::applyConstraint(), CmdSketcherConstrainPointOnObject::applyConstraint(), CmdSketcherConstrainParallel::applyConstraint(), CmdSketcherConstrainPerpendicular::applyConstraint(), CmdSketcherConstrainTangent::applyConstraint(), CmdSketcherConstrainEqual::applyConstraint(), CmdSketcherConstrainSymmetric::applyConstraint(), makeTangentToArcOfEllipseviaNewPoint(), makeTangentToArcOfHyperbolaviaNewPoint(), makeTangentToArcOfParabolaviaNewPoint(), makeTangentToEllipseviaNewPoint(), SketcherGui::DrawSketchHandlerFillet::releaseButton(), SketcherGui::DrawSketchHandlerRegularPolygon::releaseButton(), SketcherGui::DrawSketchHandlerOblong::releaseButton(), SketcherGui::DrawSketchHandlerSlot::releaseButton(), SketcherGui::DrawSketchHandlerSplitting::releaseButton(), SketcherGui::DrawSketchHandlerTrimming::releaseButton(), tryAutoRecompute(), and tryAutoRecomputeIfNotSolve().

◆ tryAutoRecompute() [2/2]

bool SketcherGui::tryAutoRecompute ( Sketcher::SketchObject obj,
bool autoremoveredundants 
)

Same as the other overload, but also returns whether redundants shall be removed or not.

References App::GetApplication(), ParameterGrp::GetBool(), App::Application::GetParameterGroupByPath(), and Gui::Command::updateActive().

◆ tryAutoRecomputeIfNotSolve()

void SketcherGui::tryAutoRecomputeIfNotSolve ( Sketcher::SketchObject obj)

This function tries to auto-recompute as tryAutoRecompute.

If tryAutoRecompute is not enabled, then it solves the SketchObject.

References tryAutoRecompute().

Referenced by CmdSketcherConstrainRadius::activated(), CmdSketcherConstrainDiameter::activated(), CmdSketcherConstrainRadiam::activated(), CmdSketcherConstrainRadius::applyConstraint(), CmdSketcherConstrainDiameter::applyConstraint(), CmdSketcherConstrainRadiam::applyConstraint(), SketcherGui::ViewProviderSketch::mouseButtonPressed(), SketcherGui::DrawSketchHandlerCarbonCopy::onSelectionChanged(), SketcherGui::DrawSketchHandlerExternal::onSelectionChanged(), SketcherGui::DrawSketchHandlerBSpline::quit(), DrawSketchHandlerBSplineInsertKnot::releaseButton(), DrawSketchHandlerCopy::releaseButton(), DrawSketchHandlerRectangularArray::releaseButton(), SketcherGui::DrawSketchHandlerArc::releaseButton(), SketcherGui::DrawSketchHandler3PointArc::releaseButton(), SketcherGui::DrawSketchHandlerArcOfEllipse::releaseButton(), SketcherGui::DrawSketchHandlerCircle::releaseButton(), SketcherGui::DrawSketchHandler3PointCircle::releaseButton(), SketcherGui::DrawSketchHandlerFillet::releaseButton(), SketcherGui::DrawSketchHandlerLine::releaseButton(), SketcherGui::DrawSketchHandlerLineSet::releaseButton(), SketcherGui::DrawSketchHandlerPoint::releaseButton(), SketcherGui::DrawSketchHandlerRegularPolygon::releaseButton(), SketcherGui::DrawSketchHandlerBox::releaseButton(), SketcherGui::DrawSketchHandlerOblong::releaseButton(), SketcherGui::DrawSketchHandlerSlot::releaseButton(), SketcherGui::DrawSketchHandlerArcOfHyperbola::releaseButton(), SketcherGui::DrawSketchHandlerArcOfParabola::releaseButton(), CmdSketcherConstrainTangent::substituteConstraintCombinations(), and CmdSketcherConstrainCoincident::substituteConstraintCombinations().

Variable Documentation

◆ geometryCreationMode