Make Subclasses of Part::Feature objects repr as their derived Type (#24429)

This commit is contained in:
Steven James
2026-02-03 12:03:29 -05:00
committed by GitHub
parent dafed93c63
commit c07d248bc3

View File

@@ -37,7 +37,7 @@ using namespace Part;
// returns a string which represent the object e.g. when printed in python
std::string PartFeaturePy::representation() const
{
return {"<Part::Feature>"};
return fmt::format("<{}>", static_cast<std::string>(getTypeId()));
}
PyObject* PartFeaturePy::getElementHistory(PyObject* args, PyObject* kwds) const