1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D -->
3 // File: SketchPlugin_ConstraintEqual.cpp
4 // Created: 16 Mar 2015
5 // Author: Artem ZHIDKOV
7 #include "SketchPlugin_ConstraintEqual.h"
9 #include <ModelAPI_AttributeDouble.h>
10 #include <ModelAPI_Data.h>
11 #include <ModelAPI_ResultConstruction.h>
13 #include <SketchPlugin_Line.h>
14 #include <SketchPlugin_Sketch.h>
16 #include <SketcherPrs_Factory.h>
18 #include <Config_PropManager.h>
20 SketchPlugin_ConstraintEqual::SketchPlugin_ConstraintEqual()
24 void SketchPlugin_ConstraintEqual::initAttributes()
26 data()->addAttribute(SketchPlugin_Constraint::ENTITY_A(), ModelAPI_AttributeRefAttr::typeId());
27 data()->addAttribute(SketchPlugin_Constraint::ENTITY_B(), ModelAPI_AttributeRefAttr::typeId());
30 void SketchPlugin_ConstraintEqual::execute()
34 AISObjectPtr SketchPlugin_ConstraintEqual::getAISObject(AISObjectPtr thePrevious)
39 AISObjectPtr anAIS = thePrevious;
41 anAIS = SketcherPrs_Factory::equalConstraint(this, sketch()->coordinatePlane());