diff --git a/src/Mod/Fem/CMakeLists.txt b/src/Mod/Fem/CMakeLists.txt index 2f693f6156..461f65c18e 100755 --- a/src/Mod/Fem/CMakeLists.txt +++ b/src/Mod/Fem/CMakeLists.txt @@ -347,6 +347,10 @@ SET(FemGuiObjects_SRCS femguiobjects/readme.md ) +SET(FemGuiTaskPanels_SRCS + femtaskpanels/__init__.py +) + SET(FemGuiTests_SRCS femtest/gui/__init__.py femtest/gui/test_open.py @@ -386,6 +390,7 @@ SET(FemGuiViewProvider_SRCS SET(FemAllGuiScripts ${FemGuiBaseModules_SRCS} ${FemGuiObjects_SRCS} + ${FemGuiTaskPanels_SRCS} ${FemGuiTests_SRCS} ${FemGuiUtils_SRCS} ${FemGuiViewProvider_SRCS} @@ -401,6 +406,7 @@ if(BUILD_GUI) # install directories for Python packages (for make install) INSTALL(FILES ${FemGuiBaseModules_SRCS} DESTINATION Mod/Fem/) INSTALL(FILES ${FemGuiObjects_SRCS} DESTINATION Mod/Fem/femguiobjects/) + INSTALL(FILES ${FemGuiTaskPanels_SRCS} DESTINATION Mod/Fem/femtaskpanels/) INSTALL(FILES ${FemGuiTests_SRCS} DESTINATION Mod/Fem/femtest/gui/) INSTALL(FILES ${FemGuiUtils_SRCS} DESTINATION Mod/Fem/femguiutils/) INSTALL(FILES ${FemGuiViewProvider_SRCS} DESTINATION Mod/Fem/femviewprovider/) diff --git a/src/Mod/Fem/coding_conventions.md b/src/Mod/Fem/coding_conventions.md index 1b6d43cadf..a6417630cd 100644 --- a/src/Mod/Fem/coding_conventions.md +++ b/src/Mod/Fem/coding_conventions.md @@ -102,6 +102,14 @@ Python style is preferred over Doxygen style - see `ccx` tools module in fem tools package - see [forum topic](https://forum.freecadweb.org/viewtopic.php?f=10&t=37094) +### Module structure +- task panels should go into a separate package too + - according pep8 imports should be on module beginning + - if task panel class in inside viewprovider module, the imports needed for task panel are module beginning too + - might be some special plot module or what ever is needed + - if this is not available the object can not even created + - if task panel is separate the object can be createdh + ## C++ ### Naming policy - CamelCase names diff --git a/src/Mod/Fem/femtaskpanels/__init__.py b/src/Mod/Fem/femtaskpanels/__init__.py new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/Mod/Fem/femtest/app/test_common.py b/src/Mod/Fem/femtest/app/test_common.py index aa17d70463..e05135dad5 100644 --- a/src/Mod/Fem/femtest/app/test_common.py +++ b/src/Mod/Fem/femtest/app/test_common.py @@ -117,6 +117,7 @@ class TestFemCommon(unittest.TestCase): if FreeCAD.GuiUp: pymodules += testtools.collect_python_modules("femcommands") pymodules += testtools.collect_python_modules("femguiobjects") + pymodules += testtools.collect_python_modules("femtaskpanels") # import all collected modules # fcc_print(pymodules)