MCPcopy Create free account
hub / github.com/FreeCAD/FreeCAD / getLibraryRoot

Method getLibraryRoot

src/Mod/Material/App/MaterialPyImp.cpp:80–89  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

78}
79
80Py::String MaterialPy::getLibraryRoot() const
81{
82 auto library = getMaterialPtr()->getLibrary();
83 if (library->isLocal()) {
84 auto materialLibrary =
85 std::dynamic_pointer_cast<Materials::MaterialLibraryLocal>(library);
86 return {materialLibrary ? materialLibrary->getDirectoryPath().toStdString() : ""};
87 }
88 return "";
89}
90
91Py::Object MaterialPy::getLibraryIcon() const
92{

Callers

nothing calls this directly

Calls 4

isLocalMethod · 0.80
toStdStringMethod · 0.80
getDirectoryPathMethod · 0.80
getLibraryMethod · 0.45

Tested by

no test coverage detected