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

Method sSetActiveDocument

src/App/ApplicationPy.cpp:430–446  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

428}
429
430PyObject* ApplicationPy::sSetActiveDocument(PyObject* /*self*/, PyObject* args)
431{
432 char* pstr = nullptr;
433 if (!PyArg_ParseTuple(args, "s", &pstr)) {
434 return nullptr;
435 }
436
437 try {
438 GetApplication().setActiveDocument(pstr);
439 }
440 catch (const Base::Exception& e) {
441 e.setPyException();
442 return nullptr;
443 }
444
445 Py_Return;
446}
447
448PyObject* ApplicationPy::sCloseDocument(PyObject* /*self*/, PyObject* args)
449{

Callers

nothing calls this directly

Calls 2

setActiveDocumentMethod · 0.45
setPyExceptionMethod · 0.45

Tested by

no test coverage detected