diff --git a/src/Mod/Sketcher/App/ConstraintPy.xml b/src/Mod/Sketcher/App/ConstraintPy.xml index 5ef77d5aaa..88e8461ec6 100644 --- a/src/Mod/Sketcher/App/ConstraintPy.xml +++ b/src/Mod/Sketcher/App/ConstraintPy.xml @@ -44,13 +44,13 @@ Position of second geometry index the Constraint refers to - + Third geometry index the Constraint refers to - + @@ -82,5 +82,11 @@ + + + Returns whether the constraint active (enforced) or not + + + diff --git a/src/Mod/Sketcher/App/ConstraintPyImp.cpp b/src/Mod/Sketcher/App/ConstraintPyImp.cpp index 076ef24778..25a24c7d86 100644 --- a/src/Mod/Sketcher/App/ConstraintPyImp.cpp +++ b/src/Mod/Sketcher/App/ConstraintPyImp.cpp @@ -707,6 +707,11 @@ Py::Boolean ConstraintPy::getInVirtualSpace(void) const return Py::Boolean(this->getConstraintPtr()->isInVirtualSpace); } +Py::Boolean ConstraintPy::getIsActive(void) const +{ + return Py::Boolean(this->getConstraintPtr()->isActive); +} + PyObject *ConstraintPy::getCustomAttributes(const char* /*attr*/) const { return 0;