20 #ifndef SketchSolver_ConstraintMulti_H_
21 #define SketchSolver_ConstraintMulti_H_
23 #include <SketchSolver_Constraint.h>
41 myIsEventsBlocked(false),
65 void getEntities(std::list<EntityWrapperPtr>& theEntities);
68 virtual void getAttributes(EntityWrapperPtr&, std::vector<EntityWrapperPtr>&)
82 virtual void getRelative(
double theAbsX,
double theAbsY,
double& theRelX,
double& theRelY) = 0;
84 virtual void getAbsolute(
double theRelX,
double theRelY,
double& theAbsX,
double& theAbsY) = 0;
97 std::set<FeaturePtr> myCopiedFeatures;
99 bool myIsEventsBlocked;
Send events to listeners about changing a feature.
Definition: PlaneGCSSolver_Update.h:38
Common base class for the Multi constraints.
Definition: SketchSolver_ConstraintMulti.h:32
virtual void getAttributes(EntityWrapperPtr &, std::vector< EntityWrapperPtr > &)
Generate list of attributes of constraint in order useful for SolveSpace constraints.
Definition: SketchSolver_ConstraintMulti.h:68
bool myAdjusted
the constraint is already adjusted (to not do it several times)
Definition: SketchSolver_ConstraintMulti.h:93
bool myIsFullValue
value whether the angle/distance is a full or single for objects
Definition: SketchSolver_ConstraintMulti.h:91
SketchSolver_ConstraintMulti(ConstraintPtr theConstraint)
Constructor based on SketchPlugin constraint.
Definition: SketchSolver_ConstraintMulti.h:35
virtual void blockEvents(bool isBlocked)
Block or unblock events from this constraint.
Definition: SketchSolver_ConstraintMulti.cpp:251
virtual void notify(const FeaturePtr &theFeature, PlaneGCSSolver_Update *)
Notify this object about the feature is changed somewhere.
Definition: SketchSolver_ConstraintMulti.cpp:227
virtual void transformRelative(double &theX, double &theY)=0
Apply transformation for relative coordinates.
void getEntities(std::list< EntityWrapperPtr > &theEntities)
Collect entities which are translated or rotated (not their copies)
Definition: SketchSolver_ConstraintMulti.cpp:45
std::set< FeaturePtr > myOriginalFeatures
lists of original features and their copies to find whether some of them are disappeared
Definition: SketchSolver_ConstraintMulti.h:96
virtual void adjustConstraint()
This method is used in derived objects to check consistence of constraint.
Definition: SketchSolver_ConstraintMulti.cpp:154
virtual void process()
Converts SketchPlugin constraint to a list of SolveSpace constraints.
Definition: SketchSolver_ConstraintMulti.h:61
virtual void updateLocal()=0
Update parameters of derived classes.
int myNumberOfObjects
number of previous initial objects
Definition: SketchSolver_ConstraintMulti.h:89
virtual const std::string & nameNbObjects()=0
Returns name of NUMBER_OF_COPIES parameter for corresponding feature.
int myNumberOfCopies
number of previous copies of initial objects
Definition: SketchSolver_ConstraintMulti.h:90
bool myIsProcessingNotify
the notification is already processing
Definition: SketchSolver_ConstraintMulti.h:100
virtual void getRelative(double theAbsX, double theAbsY, double &theRelX, double &theRelY)=0
Convert absolute coordinates to relative coordinates.
virtual bool remove()
Tries to remove constraint.
Definition: SketchSolver_ConstraintMulti.cpp:92
virtual void getAbsolute(double theRelX, double theRelY, double &theAbsX, double &theAbsY)=0
Convert relative coordinates to absolute coordinates.
virtual void update()
Update constraint.
Definition: SketchSolver_ConstraintMulti.cpp:115
Converts SketchPlugin constraint to the constraint applicable for solver.
Definition: SketchSolver_Constraint.h:39