From dc9a591b4c58d48f33a8d13e541bd2d397540102f96a12f0a95886b25983ef34 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20Br=C3=BCns?= Date: Wed, 24 Mar 2021 12:00:30 +0000 Subject: [PATCH] Accepting request 880553 from home:StefanBruens:branches:science - Update to version 0.19.1: * Lots of new features, bug fixes and improvements, see https://wiki.freecadweb.org/Release_notes_0.19 - Drop upstream patches: * 0001-Fix-build-with-pyside2-shiboken2-5.12.1.patch * 0003-qt-5.14.patch * update-swigpyrunin-for-python-3.8.patch * 0001-fem-use-time.process_time-instead-of-removed-time.cl.patch * fix_qt_5.15_build.patch * 0001-boost-1.73.0-The-practice-of-declaring-the-Bind-plac.patch * 0001-Fix-ODR-violation-correct-Ui_TaskSketcherGeneral-nam.patch * 0001-Gui-skip-ci-fix-Wodr.patch * 0001-Part-Import-skip-ci-disable-use-of-Message_ProgressI.patch * 0001-import-Hotfix-for-build-failure-from-bad-debug-code.patch * 0001-partdesign-fix-failing-tapered-hole-test.patch * 0001-add-missing-std-namespace-to-build-on-Debian-10.patch - Rebase fix-smesh-vtk9.patch OBS-URL: https://build.opensuse.org/request/show/880553 OBS-URL: https://build.opensuse.org/package/show/science/FreeCAD?expand=0&rev=136 --- ...n-correct-Ui_TaskSketcherGeneral-nam.patch | 35 - ...-build-with-pyside2-shiboken2-5.12.1.patch | 88 - 0001-Gui-skip-ci-fix-Wodr.patch | 54 - ...-ci-disable-use-of-Message_ProgressI.patch | 426 -- ...-std-namespace-to-build-on-Debian-10.patch | 37 - ...-practice-of-declaring-the-Bind-plac.patch | 4461 ----------------- ...cess_time-instead-of-removed-time.cl.patch | 86 - ...or-build-failure-from-bad-debug-code.patch | 117 - ...design-fix-failing-tapered-hole-test.patch | 26 - 0003-qt-5.14.patch | 77 - FreeCAD-0.18.5.obscpio | 3 - FreeCAD-0.18.5.tar.xz | 3 - FreeCAD-0.19.1.tar.gz | 3 + FreeCAD-test.spec | 2 +- FreeCAD.changes | 21 + FreeCAD.obsinfo | 5 - FreeCAD.spec | 120 +- _constraints | 2 +- fix-smesh-vtk9.patch | 25 - fix_qt_5.15_build.patch | 21 - update-swigpyrunin-for-python-3.8.patch | 27 - 21 files changed, 64 insertions(+), 5575 deletions(-) delete mode 100644 0001-Fix-ODR-violation-correct-Ui_TaskSketcherGeneral-nam.patch delete mode 100644 0001-Fix-build-with-pyside2-shiboken2-5.12.1.patch delete mode 100644 0001-Gui-skip-ci-fix-Wodr.patch delete mode 100644 0001-Part-Import-skip-ci-disable-use-of-Message_ProgressI.patch delete mode 100644 0001-add-missing-std-namespace-to-build-on-Debian-10.patch delete mode 100644 0001-boost-1.73.0-The-practice-of-declaring-the-Bind-plac.patch delete mode 100644 0001-fem-use-time.process_time-instead-of-removed-time.cl.patch delete mode 100644 0001-import-Hotfix-for-build-failure-from-bad-debug-code.patch delete mode 100644 0001-partdesign-fix-failing-tapered-hole-test.patch delete mode 100644 0003-qt-5.14.patch delete mode 100644 FreeCAD-0.18.5.obscpio delete mode 100644 FreeCAD-0.18.5.tar.xz create mode 100644 FreeCAD-0.19.1.tar.gz delete mode 100644 FreeCAD.obsinfo delete mode 100644 fix_qt_5.15_build.patch delete mode 100644 update-swigpyrunin-for-python-3.8.patch diff --git a/0001-Fix-ODR-violation-correct-Ui_TaskSketcherGeneral-nam.patch b/0001-Fix-ODR-violation-correct-Ui_TaskSketcherGeneral-nam.patch deleted file mode 100644 index b31f335..0000000 --- a/0001-Fix-ODR-violation-correct-Ui_TaskSketcherGeneral-nam.patch +++ /dev/null @@ -1,35 +0,0 @@ -From 47be1f5e46acd7f438672b238f1e8354a494decf Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Stefan=20Br=C3=BCns?= -Date: Sat, 28 Nov 2020 13:35:59 +0100 -Subject: [PATCH] Fix ODR violation, correct Ui_TaskSketcherGeneral namespace - -The generated ui_TaskSketcherGeneral.h defines the class in the -SketcherGui namespace. ---- - src/Mod/Sketcher/Gui/TaskSketcherGeneral.h | 3 +-- - 1 file changed, 1 insertion(+), 2 deletions(-) - -diff --git a/src/Mod/Sketcher/Gui/TaskSketcherGeneral.h b/src/Mod/Sketcher/Gui/TaskSketcherGeneral.h -index eb3276ec7..c08489eeb 100644 ---- a/src/Mod/Sketcher/Gui/TaskSketcherGeneral.h -+++ b/src/Mod/Sketcher/Gui/TaskSketcherGeneral.h -@@ -28,8 +28,6 @@ - #include - #include - --class Ui_TaskSketcherGeneral; -- - namespace App { - class Property; - } -@@ -40,6 +38,7 @@ class ViewProvider; - - namespace SketcherGui { - -+class Ui_TaskSketcherGeneral; - class ViewProviderSketch; - - class SketcherGeneralWidget : public QWidget --- -2.29.2 - diff --git a/0001-Fix-build-with-pyside2-shiboken2-5.12.1.patch b/0001-Fix-build-with-pyside2-shiboken2-5.12.1.patch deleted file mode 100644 index 6137c55..0000000 --- a/0001-Fix-build-with-pyside2-shiboken2-5.12.1.patch +++ /dev/null @@ -1,88 +0,0 @@ -From 7d362752633f0e47cebc44f52db8dffbc3b3c2e6 Mon Sep 17 00:00:00 2001 -From: Christophe Giboudeaux -Date: Thu, 13 Jun 2019 14:15:07 +0200 -Subject: [PATCH] Fix build with pyside2/shiboken2 >= 5.12.1 - -Starting with 5.12.2, pyside2 and shiboken2 now create CMake build targets. -The old variables were removed, leading to linker errors when building FreeCAD. ---- - src/Gui/CMakeLists.txt | 54 ++++++++++++++++++++++++------------------ - 1 file changed, 31 insertions(+), 23 deletions(-) - -diff --git a/src/Gui/CMakeLists.txt b/src/Gui/CMakeLists.txt -index 3bd96e0..93babc5 100644 ---- a/src/Gui/CMakeLists.txt -+++ b/src/Gui/CMakeLists.txt -@@ -137,38 +137,46 @@ IF(OCULUS_FOUND) - ) - ENDIF(OCULUS_FOUND) - --if(SHIBOKEN_INCLUDE_DIR) -- if (BUILD_QT5) -+if(BUILD_QT5) -+ if(Shiboken2_FOUND) - add_definitions(-DHAVE_SHIBOKEN2) -- else() -+ if("${Shiboken2_VERSION}" VERSION_GREATER 5.12.1) -+ list(APPEND FreeCADGui_LIBS Shiboken2::libshiboken) -+ else() -+ include_directories(${SHIBOKEN_INCLUDE_DIR}) -+ list(APPEND FreeCADGui_LIBS ${SHIBOKEN_LIBRARY}) -+ endif() -+ endif() -+ if(PySide2_FOUND) -+ add_definitions(-DHAVE_PYSIDE2) -+ if("${PySide2_VERSION}" VERSION_GREATER 5.12.1) -+ list(APPEND FreeCADGui_LIBS PySide2::pyside2) -+ # Needed to '#include pyside2__python.h' -+ get_target_property(PYSIDE_INCLUDE_DIR PySide2::pyside2 INTERFACE_INCLUDE_DIRECTORIES) -+ else() -+ list(APPEND FreeCADGui_LIBS ${PYSIDE_LIBRARY}) -+ endif() -+ include_directories(${PYSIDE_INCLUDE_DIR}/QtWidgets) -+ endif() -+else() -+ if(SHIBOKEN_INCLUDE_DIR) - add_definitions(-DHAVE_SHIBOKEN) -+ include_directories(${SHIBOKEN_INCLUDE_DIR}) -+ list(APPEND FreeCADGui_LIBS ${SHIBOKEN_LIBRARY}) - endif() -- include_directories( -- ${SHIBOKEN_INCLUDE_DIR} -- ) -- list(APPEND FreeCADGui_LIBS -- ${SHIBOKEN_LIBRARY} -- ) --endif(SHIBOKEN_INCLUDE_DIR) -+ if(PYSIDE_INCLUDE_DIR) -+ add_definitions(-DHAVE_PYSIDE) -+ list(APPEND FreeCADGui_LIBS ${PYSIDE_LIBRARY}) -+ endif() -+endif() - --if(PYSIDE_INCLUDE_DIR) -+if(DEFINED PYSIDE_INCLUDE_DIR) - include_directories( - ${PYSIDE_INCLUDE_DIR} - ${PYSIDE_INCLUDE_DIR}/QtCore - ${PYSIDE_INCLUDE_DIR}/QtGui - ) -- list(APPEND FreeCADGui_LIBS -- ${PYSIDE_LIBRARY} -- ) -- if (BUILD_QT5) -- include_directories( -- ${PYSIDE_INCLUDE_DIR}/QtWidgets -- ) -- add_definitions(-DHAVE_PYSIDE2) -- else() -- add_definitions(-DHAVE_PYSIDE) -- endif() --endif(PYSIDE_INCLUDE_DIR) -+endif() - - generate_from_xml(DocumentPy) - generate_from_xml(PythonWorkbenchPy) --- -2.22.0 - diff --git a/0001-Gui-skip-ci-fix-Wodr.patch b/0001-Gui-skip-ci-fix-Wodr.patch deleted file mode 100644 index 45be8ce..0000000 --- a/0001-Gui-skip-ci-fix-Wodr.patch +++ /dev/null @@ -1,54 +0,0 @@ -From 6bd39e8a90e65d81733e06d73bc627387808c772 Mon Sep 17 00:00:00 2001 -From: wmayer -Date: Tue, 24 Nov 2020 15:46:46 +0100 -Subject: [PATCH] Gui: [skip ci] fix -Wodr The forward declarations of - QuantitySpinBox and Ui_TaskAppearance were done in the wrong namespace - ---- - src/Gui/TaskCSysDragger.h | 3 +-- - src/Gui/TaskView/TaskAppearance.h | 5 +++-- - 2 files changed, 4 insertions(+), 4 deletions(-) - -diff --git a/src/Gui/TaskCSysDragger.h b/src/Gui/TaskCSysDragger.h -index 721cc51c8d..b2dcad3b5e 100644 ---- a/src/Gui/TaskCSysDragger.h -+++ b/src/Gui/TaskCSysDragger.h -@@ -26,10 +26,9 @@ - #include - #include - --class QuantitySpinBox; -- - namespace Gui - { -+ class QuantitySpinBox; - class SoFCCSysDragger; - class ViewProviderDragger; - -diff --git a/src/Gui/TaskView/TaskAppearance.h b/src/Gui/TaskView/TaskAppearance.h -index 1e3de8a898..b637053f33 100644 ---- a/src/Gui/TaskView/TaskAppearance.h -+++ b/src/Gui/TaskView/TaskAppearance.h -@@ -29,16 +29,17 @@ - #include - - --class Ui_TaskAppearance; -- - namespace App { - class Property; - } - - namespace Gui { - class ViewProvider; -+ - namespace TaskView { -+ - typedef boost::signals2::connection TaskAppearance_Connection; -+class Ui_TaskAppearance; - - class TaskAppearance : public TaskBox, public Gui::SelectionSingleton::ObserverType - { --- -2.29.2 - diff --git a/0001-Part-Import-skip-ci-disable-use-of-Message_ProgressI.patch b/0001-Part-Import-skip-ci-disable-use-of-Message_ProgressI.patch deleted file mode 100644 index c789a42..0000000 --- a/0001-Part-Import-skip-ci-disable-use-of-Message_ProgressI.patch +++ /dev/null @@ -1,426 +0,0 @@ -From de4de28563383c08f247738623a7ea469604e4d0 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Stefan=20Br=C3=BCns?= -Date: Tue, 23 Feb 2021 17:37:07 +0100 -Subject: [PATCH] Part/Import: [skip ci] disable use of - Message_ProgressIndicator for OCC >= 7.5 due to major API changes - ---- - src/Mod/Import/App/AppImportPy.cpp | 8 ++++++++ - src/Mod/Import/Gui/AppImportGuiPy.cpp | 16 ++++++++++++++++ - src/Mod/Part/App/ImportIges.cpp | 6 ++++++ - src/Mod/Part/App/ImportStep.cpp | 4 ++++ - src/Mod/Part/App/ProgressIndicator.cpp | 2 ++ - src/Mod/Part/App/ProgressIndicator.h | 3 +++ - src/Mod/Part/App/TopoShape.cpp | 22 +++++++++++++++++++--- - src/Mod/Part/Gui/TaskCheckGeometry.cpp | 13 ++++++++++++- - src/Mod/Part/Gui/TaskCheckGeometry.h | 4 +++- - 9 files changed, 73 insertions(+), 5 deletions(-) - -diff --git a/src/Mod/Import/App/AppImportPy.cpp b/src/Mod/Import/App/AppImportPy.cpp -index dfb6234e5a..8c11ee2078 100644 ---- a/src/Mod/Import/App/AppImportPy.cpp -+++ b/src/Mod/Import/App/AppImportPy.cpp -@@ -146,12 +146,16 @@ private: - throw Py::Exception(PyExc_IOError, "cannot read STEP file"); - } - -+#if OCC_VERSION_HEX < 0x070500 - Handle(Message_ProgressIndicator) pi = new Part::ProgressIndicator(100); - aReader.Reader().WS()->MapReader()->SetProgress(pi); - pi->NewScope(100, "Reading STEP file..."); - pi->Show(); -+#endif - aReader.Transfer(hDoc); -+#if OCC_VERSION_HEX < 0x070500 - pi->EndScope(); -+#endif - } - catch (OSD_Exception& e) { - Base::Console().Error("%s\n", e.GetMessageString()); -@@ -178,12 +182,16 @@ private: - throw Py::Exception(PyExc_IOError, "cannot read IGES file"); - } - -+#if OCC_VERSION_HEX < 0x070500 - Handle(Message_ProgressIndicator) pi = new Part::ProgressIndicator(100); - aReader.WS()->MapReader()->SetProgress(pi); - pi->NewScope(100, "Reading IGES file..."); - pi->Show(); -+#endif - aReader.Transfer(hDoc); -+#if OCC_VERSION_HEX < 0x070500 - pi->EndScope(); -+#endif - // http://opencascade.blogspot.de/2009/03/unnoticeable-memory-leaks-part-2.html - Handle(IGESToBRep_Actor)::DownCast(aReader.WS()->TransferReader()->Actor()) - ->SetModel(new IGESData_IGESModel); -diff --git a/src/Mod/Import/Gui/AppImportGuiPy.cpp b/src/Mod/Import/Gui/AppImportGuiPy.cpp -index 8f9ace29c7..9414e622a8 100644 ---- a/src/Mod/Import/Gui/AppImportGuiPy.cpp -+++ b/src/Mod/Import/Gui/AppImportGuiPy.cpp -@@ -391,12 +391,16 @@ private: - throw Py::Exception(PyExc_IOError, "cannot read STEP file"); - } - -+#if OCC_VERSION_HEX < 0x070500 - Handle(Message_ProgressIndicator) pi = new Part::ProgressIndicator(100); - aReader.Reader().WS()->MapReader()->SetProgress(pi); - pi->NewScope(100, "Reading STEP file..."); - pi->Show(); -+#endif - aReader.Transfer(hDoc); -+#if OCC_VERSION_HEX < 0x070500 - pi->EndScope(); -+#endif - } - catch (OSD_Exception& e) { - Base::Console().Error("%s\n", e.GetMessageString()); -@@ -423,12 +427,16 @@ private: - throw Py::Exception(Base::BaseExceptionFreeCADError, "cannot read IGES file"); - } - -+#if OCC_VERSION_HEX < 0x070500 - Handle(Message_ProgressIndicator) pi = new Part::ProgressIndicator(100); - aReader.WS()->MapReader()->SetProgress(pi); - pi->NewScope(100, "Reading IGES file..."); - pi->Show(); -+#endif - aReader.Transfer(hDoc); -+#if OCC_VERSION_HEX < 0x070500 - pi->EndScope(); -+#endif - // http://opencascade.blogspot.de/2009/03/unnoticeable-memory-leaks-part-2.html - Handle(IGESToBRep_Actor)::DownCast(aReader.WS()->TransferReader()->Actor()) - ->SetModel(new IGESData_IGESModel); -@@ -601,12 +609,16 @@ private: - throw Py::Exception(PyExc_IOError, "cannot read STEP file"); - } - -+#if OCC_VERSION_HEX < 0x070500 - Handle(Message_ProgressIndicator) pi = new Part::ProgressIndicator(100); - aReader.Reader().WS()->MapReader()->SetProgress(pi); - pi->NewScope(100, "Reading STEP file..."); - pi->Show(); -+#endif - aReader.Transfer(hDoc); -+#if OCC_VERSION_HEX < 0x070500 - pi->EndScope(); -+#endif - } - else if (file.hasExtension("igs") || file.hasExtension("iges")) { - Base::Reference hGrp = App::GetApplication().GetUserParameter() -@@ -623,12 +635,16 @@ private: - throw Py::Exception(PyExc_IOError, "cannot read IGES file"); - } - -+#if OCC_VERSION_HEX < 0x070500 - Handle(Message_ProgressIndicator) pi = new Part::ProgressIndicator(100); - aReader.WS()->MapReader()->SetProgress(pi); - pi->NewScope(100, "Reading IGES file..."); - pi->Show(); -+#endif - aReader.Transfer(hDoc); -+#if OCC_VERSION_HEX < 0x070500 - pi->EndScope(); -+#endif - // http://opencascade.blogspot.de/2009/03/unnoticeable-memory-leaks-part-2.html - Handle(IGESToBRep_Actor)::DownCast(aReader.WS()->TransferReader()->Actor()) - ->SetModel(new IGESData_IGESModel); -diff --git a/src/Mod/Part/App/ImportIges.cpp b/src/Mod/Part/App/ImportIges.cpp -index abc0faeb59..f004e9bc36 100644 ---- a/src/Mod/Part/App/ImportIges.cpp -+++ b/src/Mod/Part/App/ImportIges.cpp -@@ -52,6 +52,8 @@ - #include - #include - #include -+#include -+ - - #include - #include -@@ -90,16 +92,20 @@ int Part::ImportIgesParts(App::Document *pcDoc, const char* FileName) - - #if 1 - std::string aName = fi.fileNamePure(); -+#if OCC_VERSION_HEX < 0x070500 - Handle(Message_ProgressIndicator) pi = new ProgressIndicator(100); - pi->NewScope(100, "Reading IGES file..."); - pi->Show(); - aReader.WS()->MapReader()->SetProgress(pi); -+#endif - - // make model - aReader.ClearShapes(); - //Standard_Integer nbRootsForTransfer = aReader.NbRootsForTransfer(); - aReader.TransferRoots(); -+#if OCC_VERSION_HEX < 0x070500 - pi->EndScope(); -+#endif - - // put all other free-flying shapes into a single compound - Standard_Boolean emptyComp = Standard_True; -diff --git a/src/Mod/Part/App/ImportStep.cpp b/src/Mod/Part/App/ImportStep.cpp -index 828c27040b..9db9e397d8 100644 ---- a/src/Mod/Part/App/ImportStep.cpp -+++ b/src/Mod/Part/App/ImportStep.cpp -@@ -105,10 +105,12 @@ int Part::ImportStepParts(App::Document *pcDoc, const char* Name) - throw Base::FileException("Cannot open STEP file"); - } - -+#if OCC_VERSION_HEX < 0x070500 - Handle(Message_ProgressIndicator) pi = new ProgressIndicator(100); - aReader.WS()->MapReader()->SetProgress(pi); - pi->NewScope(100, "Reading STEP file..."); - pi->Show(); -+#endif - - // Root transfers - Standard_Integer nbr = aReader.NbRootsForTransfer(); -@@ -117,7 +119,9 @@ int Part::ImportStepParts(App::Document *pcDoc, const char* Name) - Base::Console().Log("STEP: Transferring Root %d\n",n); - aReader.TransferRoot(n); - } -+#if OCC_VERSION_HEX < 0x070500 - pi->EndScope(); -+#endif - - // Collecting resulting entities - Standard_Integer nbs = aReader.NbShapes(); -diff --git a/src/Mod/Part/App/ProgressIndicator.cpp b/src/Mod/Part/App/ProgressIndicator.cpp -index c5f9d64261..8eb0fcadd1 100644 ---- a/src/Mod/Part/App/ProgressIndicator.cpp -+++ b/src/Mod/Part/App/ProgressIndicator.cpp -@@ -54,6 +54,7 @@ using namespace Part; - \endcode - */ - -+#if OCC_VERSION_HEX < 0x070500 - ProgressIndicator::ProgressIndicator (int theMaxVal) - : myProgress(new Base::SequencerLauncher("", theMaxVal)) - { -@@ -83,3 +84,4 @@ Standard_Boolean ProgressIndicator::UserBreak() - { - return myProgress->wasCanceled(); - } -+#endif -diff --git a/src/Mod/Part/App/ProgressIndicator.h b/src/Mod/Part/App/ProgressIndicator.h -index 73214c0716..ad34d2ee5e 100644 ---- a/src/Mod/Part/App/ProgressIndicator.h -+++ b/src/Mod/Part/App/ProgressIndicator.h -@@ -25,11 +25,13 @@ - #define PART_PROGRESSINDICATOR_H - - #include -+#include - #include - #include - - namespace Part { - -+#if OCC_VERSION_HEX < 0x070500 - class PartExport ProgressIndicator : public Message_ProgressIndicator - { - public: -@@ -42,6 +44,7 @@ public: - private: - std::unique_ptr myProgress; - }; -+#endif - - } - -diff --git a/src/Mod/Part/App/TopoShape.cpp b/src/Mod/Part/App/TopoShape.cpp -index cc8772e6ed..5615f217a7 100644 ---- a/src/Mod/Part/App/TopoShape.cpp -+++ b/src/Mod/Part/App/TopoShape.cpp -@@ -584,17 +584,21 @@ void TopoShape::importIges(const char *FileName) - if (aReader.ReadFile(encodeFilename(FileName).c_str()) != IFSelect_RetDone) - throw Base::FileException("Error in reading IGES"); - -+#if OCC_VERSION_HEX < 0x070500 - Handle(Message_ProgressIndicator) pi = new ProgressIndicator(100); - pi->NewScope(100, "Reading IGES file..."); - pi->Show(); - aReader.WS()->MapReader()->SetProgress(pi); -+#endif - - // make brep - aReader.ClearShapes(); - aReader.TransferRoots(); - // one shape that contains all subshapes - this->_Shape = aReader.OneShape(); -+#if OCC_VERSION_HEX < 0x070500 - pi->EndScope(); -+#endif - } - catch (Standard_Failure& e) { - throw Base::CADKernelError(e.GetMessageString()); -@@ -608,16 +612,20 @@ void TopoShape::importStep(const char *FileName) - if (aReader.ReadFile(encodeFilename(FileName).c_str()) != IFSelect_RetDone) - throw Base::FileException("Error in reading STEP"); - -+#if OCC_VERSION_HEX < 0x070500 - Handle(Message_ProgressIndicator) pi = new ProgressIndicator(100); - aReader.WS()->MapReader()->SetProgress(pi); - pi->NewScope(100, "Reading STEP file..."); - pi->Show(); -+#endif - - // Root transfers - aReader.TransferRoots(); - // one shape that contains all subshapes - this->_Shape = aReader.OneShape(); -+#if OCC_VERSION_HEX < 0x070500 - pi->EndScope(); -+#endif - } - catch (Standard_Failure& e) { - throw Base::CADKernelError(e.GetMessageString()); -@@ -630,7 +638,7 @@ void TopoShape::importBrep(const char *FileName) - // read brep-file - BRep_Builder aBuilder; - TopoDS_Shape aShape; --#if OCC_VERSION_HEX >= 0x060300 -+#if OCC_VERSION_HEX >= 0x060300 && OCC_VERSION_HEX < 0x070500 - Handle(Message_ProgressIndicator) pi = new ProgressIndicator(100); - pi->NewScope(100, "Reading BREP file..."); - pi->Show(); -@@ -652,16 +660,19 @@ void TopoShape::importBrep(std::istream& str, int indicator) - // read brep-file - BRep_Builder aBuilder; - TopoDS_Shape aShape; --#if OCC_VERSION_HEX >= 0x060300 -+#if OCC_VERSION_HEX >= 0x060300 && OCC_VERSION_HEX < 0x070500 - if (indicator) { - Handle(Message_ProgressIndicator) pi = new ProgressIndicator(100); - pi->NewScope(100, "Reading BREP file..."); - pi->Show(); - BRepTools::Read(aShape,str,aBuilder,pi); - pi->EndScope(); -- } else -+ } -+ else { - BRepTools::Read(aShape,str,aBuilder); -+ } - #else -+ (void)indicator; - BRepTools::Read(aShape,str,aBuilder); - #endif - this->_Shape = aShape; -@@ -750,10 +761,13 @@ void TopoShape::exportStep(const char *filename) const - - const Handle(XSControl_TransferWriter)& hTransferWriter = aWriter.WS()->TransferWriter(); - Handle(Transfer_FinderProcess) hFinder = hTransferWriter->FinderProcess(); -+ -+#if OCC_VERSION_HEX < 0x070500 - Handle(Message_ProgressIndicator) pi = new ProgressIndicator(100); - hFinder->SetProgress(pi); - pi->NewScope(100, "Writing STEP file..."); - pi->Show(); -+#endif - - if (aWriter.Transfer(this->_Shape, STEPControl_AsIs) != IFSelect_RetDone) - throw Base::FileException("Error in transferring STEP"); -@@ -767,7 +781,9 @@ void TopoShape::exportStep(const char *filename) const - - if (aWriter.Write(encodeFilename(filename).c_str()) != IFSelect_RetDone) - throw Base::FileException("Writing of STEP failed"); -+#if OCC_VERSION_HEX < 0x070500 - pi->EndScope(); -+#endif - } - catch (Standard_Failure& e) { - throw Base::CADKernelError(e.GetMessageString()); -diff --git a/src/Mod/Part/Gui/TaskCheckGeometry.cpp b/src/Mod/Part/Gui/TaskCheckGeometry.cpp -index 0b74eec02b..b5d6d11ebb 100644 ---- a/src/Mod/Part/Gui/TaskCheckGeometry.cpp -+++ b/src/Mod/Part/Gui/TaskCheckGeometry.cpp -@@ -418,10 +418,12 @@ void TaskCheckGeometryResults::goCheck() - std::vector::iterator it; - ResultEntry *theRoot = new ResultEntry(); - -+#if OCC_VERSION_HEX < 0x070500 - Handle(Message_ProgressIndicator) theProgress = new BOPProgressIndicator(tr("Check geometry"), Gui::getMainWindow()); - theProgress->NewScope("BOP check..."); - #if OCC_VERSION_HEX >= 0x060900 - theProgress->Show(); -+#endif - #endif - - selectedCount = static_cast(selection.size()); -@@ -484,11 +486,18 @@ void TaskCheckGeometryResults::goCheck() - std::string label = "Checking "; - label += feature->Label.getStrValue(); - label += "..."; -+#if OCC_VERSION_HEX < 0x070500 - theProgress->NewScope(label.c_str()); - invalidShapes += goBOPSingleCheck(shape, theRoot, baseName, theProgress); -+#else -+ invalidShapes += goBOPSingleCheck(shape, theRoot, baseName, nullptr); -+#endif -+ -+#if OCC_VERSION_HEX < 0x070500 - theProgress->EndScope(); - if (theProgress->UserBreak()) - break; -+#endif - } - } - } -@@ -613,7 +622,7 @@ int TaskCheckGeometryResults::goBOPSingleCheck(const TopoDS_Shape& shapeIn, Resu - //this is left for another time. - TopoDS_Shape BOPCopy = BRepBuilderAPI_Copy(shapeIn).Shape(); - BOPAlgo_ArgumentAnalyzer BOPCheck; --#if OCC_VERSION_HEX >= 0x060900 -+#if OCC_VERSION_HEX >= 0x060900 && OCC_VERSION_HEX < 0x070500 - BOPCheck.SetProgressIndicator(theProgress); - #else - Q_UNUSED(theProgress); -@@ -961,6 +970,7 @@ TaskCheckGeometryDialog::~TaskCheckGeometryDialog() - - //////////////////////////////////////////////////////////////////////////////////////////////// - -+#if OCC_VERSION_HEX < 0x070500 - BOPProgressIndicator::BOPProgressIndicator (const QString& title, QWidget* parent) - { - steps = 0; -@@ -1023,5 +1033,6 @@ Standard_Boolean BOPProgressIndicator::UserBreak() - - return Standard_False; - } -+#endif - - #include "moc_TaskCheckGeometry.cpp" -diff --git a/src/Mod/Part/Gui/TaskCheckGeometry.h b/src/Mod/Part/Gui/TaskCheckGeometry.h -index e7d7d31271..1cf595bf85 100644 ---- a/src/Mod/Part/Gui/TaskCheckGeometry.h -+++ b/src/Mod/Part/Gui/TaskCheckGeometry.h -@@ -27,6 +27,7 @@ - #include - #include - #include -+#include - #include - #include - #include -@@ -147,6 +148,7 @@ private: - QTextEdit *contentLabel; - }; - -+#if OCC_VERSION_HEX < 0x070500 - class BOPProgressIndicator : public Message_ProgressIndicator - { - public: -@@ -162,7 +164,7 @@ private: - QTime time; - QProgressDialog* myProgress; - }; -- -+#endif - } - - #endif // TASKCHECKGEOMETRY_H --- -2.30.1 - diff --git a/0001-add-missing-std-namespace-to-build-on-Debian-10.patch b/0001-add-missing-std-namespace-to-build-on-Debian-10.patch deleted file mode 100644 index 44337f0..0000000 --- a/0001-add-missing-std-namespace-to-build-on-Debian-10.patch +++ /dev/null @@ -1,37 +0,0 @@ -From b084e4340f6cad03b7182c2ffe87d8e21610e9a3 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Stefan=20Br=C3=BCns?= -Date: Tue, 23 Feb 2021 18:15:05 +0100 -Subject: [PATCH] add missing std:: namespace to build on Debian 10 - ---- - src/Mod/Raytracing/App/RayFeature.cpp | 1 + - src/Mod/TechDraw/App/Geometry.cpp | 1 + - 2 files changed, 2 insertions(+) - -diff --git a/src/Mod/Raytracing/App/RayFeature.cpp b/src/Mod/Raytracing/App/RayFeature.cpp -index cdd2cb6dc1..235a986851 100644 ---- a/src/Mod/Raytracing/App/RayFeature.cpp -+++ b/src/Mod/Raytracing/App/RayFeature.cpp -@@ -36,6 +36,7 @@ - - - using namespace Raytracing; -+using namespace std; - - PROPERTY_SOURCE(Raytracing::RayFeature, Raytracing::RaySegment) - -diff --git a/src/Mod/TechDraw/App/Geometry.cpp b/src/Mod/TechDraw/App/Geometry.cpp -index 123be79795..16e7487eec 100644 ---- a/src/Mod/TechDraw/App/Geometry.cpp -+++ b/src/Mod/TechDraw/App/Geometry.cpp -@@ -75,6 +75,7 @@ - - using namespace TechDrawGeometry; - using namespace TechDraw; -+using namespace std; - - // Collection of Geometric Features - Wire::Wire() --- -2.30.1 - diff --git a/0001-boost-1.73.0-The-practice-of-declaring-the-Bind-plac.patch b/0001-boost-1.73.0-The-practice-of-declaring-the-Bind-plac.patch deleted file mode 100644 index 6377c8a..0000000 --- a/0001-boost-1.73.0-The-practice-of-declaring-the-Bind-plac.patch +++ /dev/null @@ -1,4461 +0,0 @@ -From f32b8ff2e761f8967a25bfc6f7c91dff27ac70f6 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Stefan=20Br=C3=BCns?= -Date: Sat, 19 Sep 2020 03:31:56 +0200 -Subject: [PATCH 1/2] boost 1.73.0: The practice of declaring the Bind - placeholders (_1, _2, ...) in the global namespace is deprecated - ---- - .../salomesmesh/src/SMESH/SMESH_Mesh.cpp | 4 +- - src/App/Application.cpp | 39 +- - src/App/Document.cpp | 2 +- - src/App/DocumentObject.cpp | 7 +- - src/App/DocumentObserver.cpp | 21 +- - src/App/DocumentObserverPython.cpp | 45 +- - src/App/DocumentObserverPython.h | 3 +- - src/App/MergeDocuments.cpp | 7 +- - src/App/PreCompiled.h | 2 +- - src/App/PropertyExpressionEngine.cpp | 2 +- - src/Gui/Action.cpp | 9 +- - src/Gui/Application.cpp | 28 +- - src/Gui/AutoSaver.cpp | 11 +- - src/Gui/CommandView.cpp | 5 +- - src/Gui/DAGView/DAGModel.cpp | 13 +- - src/Gui/DAGView/DAGView.cpp | 10 +- - src/Gui/DlgDisplayPropertiesImp.cpp | 5 +- - src/Gui/Document.cpp | 33 +- - src/Gui/DocumentModel.cpp | 27 +- - src/Gui/DocumentObserver.cpp | 24 +- - src/Gui/DocumentObserverPython.cpp | 21 +- - src/Gui/DocumentObserverPython.h | 2 +- - src/Gui/ExpressionBinding.cpp | 5 +- - src/Gui/GraphvizView.cpp | 9 +- - src/Gui/MDIView.cpp | 5 +- - src/Gui/MainWindow.cpp | 2 - - src/Gui/ManualAlignment.cpp | 7 +- - src/Gui/MergeDocuments.cpp | 7 +- - src/Gui/Placement.cpp | 6 +- - src/Gui/Placement.h | 1 - - src/Gui/PreCompiled.h | 2 +- - src/Gui/ProjectView.cpp | 1 - - src/Gui/PropertyView.cpp | 15 +- - src/Gui/Selection.cpp | 7 +- - src/Gui/TaskView/TaskAppearance.cpp | 5 +- - src/Gui/TaskView/TaskSelectLinkProperty.cpp | 1 - - src/Gui/TaskView/TaskView.cpp | 9 +- - src/Gui/TextDocumentEditorView.cpp | 2 +- - src/Gui/Tree.cpp | 37 +- - src/Gui/ViewProvider.cpp | 2 +- - src/Gui/ViewProviderOrigin.cpp | 1 - - src/Gui/ViewProviderOriginGroup.cpp | 3 - - src/Gui/ViewProviderOriginGroupExtension.cpp | 12 +- - src/Gui/ViewProviderPart.cpp | 2 +- - src/Gui/ViewProviderPythonFeature.cpp | 9 +- - src/Gui/ViewProviderTextDocument.cpp | 2 +- - src/Mod/Assembly/App/PartRef.cpp | 2 +- - .../App/opendcm/core/imp/clustergraph_imp.hpp | 8 +- - .../App/opendcm/module3d/imp/module_imp.hpp | 5 +- - .../App/opendcm/moduleShape3d/generator.hpp | 7 +- - .../App/opendcm/moduleShape3d/module.hpp | 6 +- - .../Assembly/Gui/TaskAssemblyConstraints.cpp | 1 - - src/Mod/Assembly/Gui/Workbench.cpp | 20 +- - src/Mod/Drawing/Gui/TaskOrthoViews.cpp | 7 +- - src/Mod/Fem/Gui/PreCompiled.h | 2 +- - src/Mod/Fem/Gui/ViewProviderAnalysis.cpp | 2 +- - .../Fem/Gui/ViewProviderFemPostFunction.cpp | 5 +- - src/Mod/Inspection/App/InspectionFeature.cpp | 5 +- - src/Mod/Mesh/App/Core/Curvature.cpp | 5 +- - src/Mod/Mesh/Gui/DlgEvaluateMeshImp.cpp | 2 - - src/Mod/Mesh/Gui/MeshEditor.cpp | 5 +- - src/Mod/Mesh/Gui/ViewProvider.cpp | 5 +- - src/Mod/Part/App/PreCompiled.h | 2 +- - src/Mod/Part/Gui/CrossSections.cpp | 5 +- - src/Mod/Part/Gui/DlgBooleanOperation.cpp | 7 +- - src/Mod/Part/Gui/DlgFilletEdges.cpp | 7 +- - src/Mod/Part/Gui/Mirroring.cpp | 1 - - src/Mod/Part/Gui/TaskAttacher.cpp | 7 +- - src/Mod/Part/Gui/TaskFaceColors.cpp | 10 +- - src/Mod/Part/Gui/ViewProviderSpline.cpp | 6 +- - src/Mod/PartDesign/App/Body.cpp | 1 - - src/Mod/PartDesign/App/ShapeBinder.cpp | 5 +- - src/Mod/PartDesign/Gui/PreCompiled.h | 178 +-- - .../PartDesign/Gui/TaskDatumParameters.cpp | 1 - - src/Mod/PartDesign/Gui/TaskHoleParameters.cpp | 4 +- - src/Mod/PartDesign/Gui/TaskHoleParameters.h | 2 +- - .../Gui/TaskPrimitiveParameters.cpp | 1 - - .../Gui/TaskTransformedMessages.cpp | 6 +- - src/Mod/PartDesign/Gui/ViewProviderBody.cpp | 7 +- - src/Mod/PartDesign/Gui/Workbench.cpp | 23 +- - src/Mod/PartDesign/Gui/WorkflowManager.cpp | 9 +- - src/Mod/Path/App/Area.cpp | 3 + - src/Mod/Path/libarea/PythonStuff.cpp | 1082 +++++++++-------- - .../ReverseEngineering/App/ApproxSurface.cpp | 5 +- - src/Mod/Sandbox/App/DocumentProtector.h | 1 - - src/Mod/Sandbox/Gui/Command.cpp | 6 +- - src/Mod/Sandbox/Gui/TaskPanelView.cpp | 15 +- - src/Mod/Sketcher/App/SketchObject.cpp | 10 +- - src/Mod/Sketcher/Gui/TaskDlgEditSketch.cpp | 7 +- - .../Sketcher/Gui/TaskSketcherConstrains.cpp | 2 +- - src/Mod/Sketcher/Gui/TaskSketcherElements.cpp | 2 +- - src/Mod/Sketcher/Gui/TaskSketcherGeneral.cpp | 4 +- - src/Mod/Sketcher/Gui/TaskSketcherMessages.cpp | 8 +- - src/Mod/Sketcher/Gui/ViewProviderSketch.cpp | 7 +- - src/Mod/Spreadsheet/App/PropertySheet.cpp | 9 +- - src/Mod/Spreadsheet/App/Sheet.cpp | 6 +- - src/Mod/Spreadsheet/Gui/SheetModel.cpp | 5 +- - src/Mod/Spreadsheet/Gui/SheetTableView.cpp | 5 +- - src/Mod/Spreadsheet/Gui/SpreadsheetView.cpp | 7 +- - src/Mod/TechDraw/Gui/MDIViewPage.cpp | 5 +- - .../TechDraw/Gui/ViewProviderDrawingView.cpp | 5 +- - src/Mod/TechDraw/Gui/ViewProviderPage.cpp | 5 +- - 102 files changed, 1048 insertions(+), 992 deletions(-) - -diff --git a/src/3rdParty/salomesmesh/src/SMESH/SMESH_Mesh.cpp b/src/3rdParty/salomesmesh/src/SMESH/SMESH_Mesh.cpp -index bb278f827..7ab201cef 100644 ---- a/src/3rdParty/salomesmesh/src/SMESH/SMESH_Mesh.cpp -+++ b/src/3rdParty/salomesmesh/src/SMESH/SMESH_Mesh.cpp -@@ -76,10 +76,10 @@ - - #ifndef WIN32 - #include --#include -+#include - #else - #include --#include -+#include - //#include - #endif - -diff --git a/src/App/Application.cpp b/src/App/Application.cpp -index f02dc5a5e..50dfaf346 100644 ---- a/src/App/Application.cpp -+++ b/src/App/Application.cpp -@@ -121,7 +121,7 @@ - - #include - #include --#include -+#include - #include - #include - #include -@@ -130,6 +130,7 @@ using namespace App; - using namespace std; - using namespace boost; - using namespace boost::program_options; -+namespace bp = boost::placeholders; - - - // scriptings (scripts are build in but can be overridden by command line option) -@@ -425,23 +426,23 @@ Document* Application::newDocument(const char * Name, const char * UserName) - - - // connect the signals to the application for the new document -- _pActiveDoc->signalBeforeChange.connect(boost::bind(&App::Application::slotBeforeChangeDocument, this, _1, _2)); -- _pActiveDoc->signalChanged.connect(boost::bind(&App::Application::slotChangedDocument, this, _1, _2)); -- _pActiveDoc->signalNewObject.connect(boost::bind(&App::Application::slotNewObject, this, _1)); -- _pActiveDoc->signalDeletedObject.connect(boost::bind(&App::Application::slotDeletedObject, this, _1)); -- _pActiveDoc->signalBeforeChangeObject.connect(boost::bind(&App::Application::slotBeforeChangeObject, this, _1, _2)); -- _pActiveDoc->signalChangedObject.connect(boost::bind(&App::Application::slotChangedObject, this, _1, _2)); -- _pActiveDoc->signalRelabelObject.connect(boost::bind(&App::Application::slotRelabelObject, this, _1)); -- _pActiveDoc->signalActivatedObject.connect(boost::bind(&App::Application::slotActivatedObject, this, _1)); -- _pActiveDoc->signalUndo.connect(boost::bind(&App::Application::slotUndoDocument, this, _1)); -- _pActiveDoc->signalRedo.connect(boost::bind(&App::Application::slotRedoDocument, this, _1)); -- _pActiveDoc->signalRecomputedObject.connect(boost::bind(&App::Application::slotRecomputedObject, this, _1)); -- _pActiveDoc->signalRecomputed.connect(boost::bind(&App::Application::slotRecomputed, this, _1)); -- _pActiveDoc->signalOpenTransaction.connect(boost::bind(&App::Application::slotOpenTransaction, this, _1, _2)); -- _pActiveDoc->signalCommitTransaction.connect(boost::bind(&App::Application::slotCommitTransaction, this, _1)); -- _pActiveDoc->signalAbortTransaction.connect(boost::bind(&App::Application::slotAbortTransaction, this, _1)); -- _pActiveDoc->signalStartSave.connect(boost::bind(&App::Application::slotStartSaveDocument, this, _1, _2)); -- _pActiveDoc->signalFinishSave.connect(boost::bind(&App::Application::slotFinishSaveDocument, this, _1, _2)); -+ _pActiveDoc->signalBeforeChange.connect(boost::bind(&App::Application::slotBeforeChangeDocument, this, bp::_1, bp::_2)); -+ _pActiveDoc->signalChanged.connect(boost::bind(&App::Application::slotChangedDocument, this, bp::_1, bp::_2)); -+ _pActiveDoc->signalNewObject.connect(boost::bind(&App::Application::slotNewObject, this, bp::_1)); -+ _pActiveDoc->signalDeletedObject.connect(boost::bind(&App::Application::slotDeletedObject, this, bp::_1)); -+ _pActiveDoc->signalBeforeChangeObject.connect(boost::bind(&App::Application::slotBeforeChangeObject, this, bp::_1, bp::_2)); -+ _pActiveDoc->signalChangedObject.connect(boost::bind(&App::Application::slotChangedObject, this, bp::_1, bp::_2)); -+ _pActiveDoc->signalRelabelObject.connect(boost::bind(&App::Application::slotRelabelObject, this, bp::_1)); -+ _pActiveDoc->signalActivatedObject.connect(boost::bind(&App::Application::slotActivatedObject, this, bp::_1)); -+ _pActiveDoc->signalUndo.connect(boost::bind(&App::Application::slotUndoDocument, this, bp::_1)); -+ _pActiveDoc->signalRedo.connect(boost::bind(&App::Application::slotRedoDocument, this, bp::_1)); -+ _pActiveDoc->signalRecomputedObject.connect(boost::bind(&App::Application::slotRecomputedObject, this, bp::_1)); -+ _pActiveDoc->signalRecomputed.connect(boost::bind(&App::Application::slotRecomputed, this, bp::_1)); -+ _pActiveDoc->signalOpenTransaction.connect(boost::bind(&App::Application::slotOpenTransaction, this, bp::_1, bp::_2)); -+ _pActiveDoc->signalCommitTransaction.connect(boost::bind(&App::Application::slotCommitTransaction, this, bp::_1)); -+ _pActiveDoc->signalAbortTransaction.connect(boost::bind(&App::Application::slotAbortTransaction, this, bp::_1)); -+ _pActiveDoc->signalStartSave.connect(boost::bind(&App::Application::slotStartSaveDocument, this, bp::_1, bp::_2)); -+ _pActiveDoc->signalFinishSave.connect(boost::bind(&App::Application::slotFinishSaveDocument, this, bp::_1, bp::_2)); - - // make sure that the active document is set in case no GUI is up - { -@@ -2691,7 +2692,7 @@ void ObjectLabelObserver::slotRelabelObject(const App::DocumentObject& obj, cons - ObjectLabelObserver::ObjectLabelObserver() : current(0) - { - App::GetApplication().signalChangedObject.connect(boost::bind -- (&ObjectLabelObserver::slotRelabelObject, this, _1, _2)); -+ (&ObjectLabelObserver::slotRelabelObject, this, bp::_1, bp::_2)); - _hPGrp = App::GetApplication().GetUserParameter().GetGroup("BaseApp"); - _hPGrp = _hPGrp->GetGroup("Preferences")->GetGroup("Document"); - } -diff --git a/src/App/Document.cpp b/src/App/Document.cpp -index c4c31562e..75592a790 100644 ---- a/src/App/Document.cpp -+++ b/src/App/Document.cpp -@@ -70,7 +70,7 @@ recompute path. Also enables more complicated dependencies beyond trees. - #include - #endif //USE_OLD_DAG - --#include -+#include - #include - #include - #include -diff --git a/src/App/DocumentObject.cpp b/src/App/DocumentObject.cpp -index 55a1766f2..3c2583c3d 100644 ---- a/src/App/DocumentObject.cpp -+++ b/src/App/DocumentObject.cpp -@@ -38,9 +38,10 @@ - #include "DocumentObjectExtension.h" - #include "GeoFeatureGroupExtension.h" - #include --#include -+#include - - using namespace App; -+namespace bp = boost::placeholders; - - - PROPERTY_SOURCE(App::DocumentObject, App::TransactionalObject) -@@ -627,7 +628,7 @@ void DocumentObject::connectRelabelSignals() - if (!onRelabledObjectConnection.connected()) { - onRelabledObjectConnection = getDocument()->signalRelabelObject - .connect(boost::bind(&PropertyExpressionEngine::slotObjectRenamed, -- &ExpressionEngine, _1)); -+ &ExpressionEngine, bp::_1)); - } - - // Connect to signalDeletedObject, to properly track deletion of other objects -@@ -635,7 +636,7 @@ void DocumentObject::connectRelabelSignals() - if (!onDeletedObjectConnection.connected()) { - onDeletedObjectConnection = getDocument()->signalDeletedObject - .connect(boost::bind(&PropertyExpressionEngine::slotObjectDeleted, -- &ExpressionEngine, _1)); -+ &ExpressionEngine, bp::_1)); - } - - try { -diff --git a/src/App/DocumentObserver.cpp b/src/App/DocumentObserver.cpp -index 53421d386..3e32d321f 100644 ---- a/src/App/DocumentObserver.cpp -+++ b/src/App/DocumentObserver.cpp -@@ -27,7 +27,7 @@ - # include - #endif - --#include -+#include - - #include "Application.h" - #include "Document.h" -@@ -35,6 +35,7 @@ - #include "DocumentObserver.h" - - using namespace App; -+namespace bp = boost::placeholders; - - - DocumentT::DocumentT() -@@ -197,18 +198,18 @@ std::string DocumentObjectT::getObjectPython() const - DocumentObserver::DocumentObserver() : _document(0) - { - this->connectApplicationCreatedDocument = App::GetApplication().signalNewDocument.connect(boost::bind -- (&DocumentObserver::slotCreatedDocument, this, _1)); -+ (&DocumentObserver::slotCreatedDocument, this, bp::_1)); - this->connectApplicationDeletedDocument = App::GetApplication().signalDeleteDocument.connect(boost::bind -- (&DocumentObserver::slotDeletedDocument, this, _1)); -+ (&DocumentObserver::slotDeletedDocument, this, bp::_1)); - } - - DocumentObserver::DocumentObserver(Document* doc) : _document(0) - { - // Connect to application and given document - this->connectApplicationCreatedDocument = App::GetApplication().signalNewDocument.connect(boost::bind -- (&DocumentObserver::slotCreatedDocument, this, _1)); -+ (&DocumentObserver::slotCreatedDocument, this, bp::_1)); - this->connectApplicationDeletedDocument = App::GetApplication().signalDeleteDocument.connect(boost::bind -- (&DocumentObserver::slotDeletedDocument, this, _1)); -+ (&DocumentObserver::slotDeletedDocument, this, bp::_1)); - attachDocument(doc); - } - -@@ -232,15 +233,15 @@ void DocumentObserver::attachDocument(Document* doc) - _document = doc; - - this->connectDocumentCreatedObject = _document->signalNewObject.connect(boost::bind -- (&DocumentObserver::slotCreatedObject, this, _1)); -+ (&DocumentObserver::slotCreatedObject, this, bp::_1)); - this->connectDocumentDeletedObject = _document->signalDeletedObject.connect(boost::bind -- (&DocumentObserver::slotDeletedObject, this, _1)); -+ (&DocumentObserver::slotDeletedObject, this, bp::_1)); - this->connectDocumentChangedObject = _document->signalChangedObject.connect(boost::bind -- (&DocumentObserver::slotChangedObject, this, _1, _2)); -+ (&DocumentObserver::slotChangedObject, this, bp::_1, bp::_2)); - this->connectDocumentRecomputedObject = _document->signalRecomputedObject.connect(boost::bind -- (&DocumentObserver::slotRecomputedObject, this, _1)); -+ (&DocumentObserver::slotRecomputedObject, this, bp::_1)); - this->connectDocumentRecomputed = _document->signalRecomputed.connect(boost::bind -- (&DocumentObserver::slotRecomputedDocument, this, _1)); -+ (&DocumentObserver::slotRecomputedDocument, this, bp::_1)); - } - } - -diff --git a/src/App/DocumentObserverPython.cpp b/src/App/DocumentObserverPython.cpp -index 7d1fa7125..9758c9a9e 100644 ---- a/src/App/DocumentObserverPython.cpp -+++ b/src/App/DocumentObserverPython.cpp -@@ -34,6 +34,7 @@ - #include - - using namespace App; -+namespace bp = boost::placeholders; - - std::vector DocumentObserverPython::_instances; - -@@ -60,54 +61,54 @@ void DocumentObserverPython::removeObserver(const Py::Object& obj) - DocumentObserverPython::DocumentObserverPython(const Py::Object& obj) : inst(obj) - { - this->connectApplicationCreatedDocument = App::GetApplication().signalNewDocument.connect(boost::bind -- (&DocumentObserverPython::slotCreatedDocument, this, _1)); -+ (&DocumentObserverPython::slotCreatedDocument, this, bp::_1)); - this->connectApplicationDeletedDocument = App::GetApplication().signalDeleteDocument.connect(boost::bind -- (&DocumentObserverPython::slotDeletedDocument, this, _1)); -+ (&DocumentObserverPython::slotDeletedDocument, this, bp::_1)); - this->connectApplicationRelabelDocument = App::GetApplication().signalRelabelDocument.connect(boost::bind -- (&DocumentObserverPython::slotRelabelDocument, this, _1)); -+ (&DocumentObserverPython::slotRelabelDocument, this, bp::_1)); - this->connectApplicationActivateDocument = App::GetApplication().signalActiveDocument.connect(boost::bind -- (&DocumentObserverPython::slotActivateDocument, this, _1)); -+ (&DocumentObserverPython::slotActivateDocument, this, bp::_1)); - this->connectApplicationUndoDocument = App::GetApplication().signalUndoDocument.connect(boost::bind -- (&DocumentObserverPython::slotUndoDocument, this, _1)); -+ (&DocumentObserverPython::slotUndoDocument, this, bp::_1)); - this->connectApplicationRedoDocument = App::GetApplication().signalRedoDocument.connect(boost::bind -- (&DocumentObserverPython::slotRedoDocument, this, _1)); -+ (&DocumentObserverPython::slotRedoDocument, this, bp::_1)); - - this->connectDocumentBeforeChange = App::GetApplication().signalBeforeChangeDocument.connect(boost::bind -- (&DocumentObserverPython::slotBeforeChangeDocument, this, _1, _2)); -+ (&DocumentObserverPython::slotBeforeChangeDocument, this, bp::_1, bp::_2)); - this->connectDocumentChanged = App::GetApplication().signalChangedDocument.connect(boost::bind -- (&DocumentObserverPython::slotChangedDocument, this, _1, _2)); -+ (&DocumentObserverPython::slotChangedDocument, this, bp::_1, bp::_2)); - this->connectDocumentCreatedObject = App::GetApplication().signalNewObject.connect(boost::bind -- (&DocumentObserverPython::slotCreatedObject, this, _1)); -+ (&DocumentObserverPython::slotCreatedObject, this, bp::_1)); - this->connectDocumentDeletedObject = App::GetApplication().signalDeletedObject.connect(boost::bind -- (&DocumentObserverPython::slotDeletedObject, this, _1)); -+ (&DocumentObserverPython::slotDeletedObject, this, bp::_1)); - this->connectDocumentBeforeChangeObject = App::GetApplication().signalBeforeChangeObject.connect(boost::bind -- (&DocumentObserverPython::slotBeforeChangeObject, this, _1, _2)); -+ (&DocumentObserverPython::slotBeforeChangeObject, this, bp::_1, bp::_2)); - this->connectDocumentChangedObject = App::GetApplication().signalChangedObject.connect(boost::bind -- (&DocumentObserverPython::slotChangedObject, this, _1, _2)); -+ (&DocumentObserverPython::slotChangedObject, this, bp::_1, bp::_2)); - - this->connectDocumentObjectRecomputed = App::GetApplication().signalObjectRecomputed.connect(boost::bind -- (&DocumentObserverPython::slotRecomputedObject, this, _1)); -+ (&DocumentObserverPython::slotRecomputedObject, this, bp::_1)); - this->connectDocumentRecomputed = App::GetApplication().signalRecomputed.connect(boost::bind -- (&DocumentObserverPython::slotRecomputedDocument, this, _1)); -+ (&DocumentObserverPython::slotRecomputedDocument, this, bp::_1)); - - this->connectDocumentOpenTransaction = App::GetApplication().signalOpenTransaction.connect(boost::bind -- (&DocumentObserverPython::slotOpenTransaction, this, _1, _2)); -+ (&DocumentObserverPython::slotOpenTransaction, this, bp::_1, bp::_2)); - this->connectDocumentCommitTransaction = App::GetApplication().signalCommitTransaction.connect(boost::bind -- (&DocumentObserverPython::slotCommitTransaction, this, _1)); -+ (&DocumentObserverPython::slotCommitTransaction, this, bp::_1)); - this->connectDocumentAbortTransaction = App::GetApplication().signalAbortTransaction.connect(boost::bind -- (&DocumentObserverPython::slotAbortTransaction, this, _1)); -+ (&DocumentObserverPython::slotAbortTransaction, this, bp::_1)); - - this->connectDocumentStartSave = App::GetApplication().signalStartSaveDocument.connect(boost::bind -- (&DocumentObserverPython::slotStartSaveDocument, this, _1, _2)); -+ (&DocumentObserverPython::slotStartSaveDocument, this, bp::_1, bp::_2)); - this->connectDocumentFinishSave = App::GetApplication().signalFinishSaveDocument.connect(boost::bind -- (&DocumentObserverPython::slotFinishSaveDocument, this, _1, _2)); -+ (&DocumentObserverPython::slotFinishSaveDocument, this, bp::_1, bp::_2)); - - this->connectObjectAppendDynamicProperty = App::GetApplication().signalAppendDynamicProperty.connect(boost::bind -- (&DocumentObserverPython::slotAppendDynamicProperty, this, _1)); -+ (&DocumentObserverPython::slotAppendDynamicProperty, this, bp::_1)); - this->connectObjectRemoveDynamicProperty = App::GetApplication().signalRemoveDynamicProperty.connect(boost::bind -- (&DocumentObserverPython::slotRemoveDynamicProperty, this, _1)); -+ (&DocumentObserverPython::slotRemoveDynamicProperty, this, bp::_1)); - this->connectObjectChangePropertyEditor = App::GetApplication().signalChangePropertyEditor.connect(boost::bind -- (&DocumentObserverPython::slotChangePropertyEditor, this, _1)); -+ (&DocumentObserverPython::slotChangePropertyEditor, this, bp::_1)); - } - - DocumentObserverPython::~DocumentObserverPython() -diff --git a/src/App/DocumentObserverPython.h b/src/App/DocumentObserverPython.h -index afff82b45..fa85bfee7 100644 ---- a/src/App/DocumentObserverPython.h -+++ b/src/App/DocumentObserverPython.h -@@ -27,7 +27,8 @@ - #include - - #include --#include -+#include -+#include - - namespace App - { -diff --git a/src/App/MergeDocuments.cpp b/src/App/MergeDocuments.cpp -index 819a7c364..67d88d50b 100644 ---- a/src/App/MergeDocuments.cpp -+++ b/src/App/MergeDocuments.cpp -@@ -23,7 +23,7 @@ - #include "PreCompiled.h" - #ifndef _PreComp_ - # include --# include -+# include - #endif - - #include -@@ -36,6 +36,7 @@ - #include - - using namespace App; -+namespace bp = boost::placeholders; - - namespace App { - -@@ -118,9 +119,9 @@ private: - MergeDocuments::MergeDocuments(App::Document* doc) : guiup(false), verbose(true), stream(0), appdoc(doc) - { - connectExport = doc->signalExportObjects.connect -- (boost::bind(&MergeDocuments::exportObject, this, _1, _2)); -+ (boost::bind(&MergeDocuments::exportObject, this, bp::_1, bp::_2)); - connectImport = doc->signalImportObjects.connect -- (boost::bind(&MergeDocuments::importObject, this, _1, _2)); -+ (boost::bind(&MergeDocuments::importObject, this, bp::_1, bp::_2)); - - QCoreApplication* app = QCoreApplication::instance(); - if (app && app->inherits("QApplication")) { -diff --git a/src/App/PreCompiled.h b/src/App/PreCompiled.h -index 49cba3652..93428b009 100644 ---- a/src/App/PreCompiled.h -+++ b/src/App/PreCompiled.h -@@ -76,7 +76,7 @@ - - // Boost - #include --#include -+#include - #include - - #include -diff --git a/src/App/PropertyExpressionEngine.cpp b/src/App/PropertyExpressionEngine.cpp -index 31f4b34b3..2d0e4e120 100644 ---- a/src/App/PropertyExpressionEngine.cpp -+++ b/src/App/PropertyExpressionEngine.cpp -@@ -33,7 +33,7 @@ - #include "PropertyStandard.h" - #include "PropertyUnits.h" - #include --#include -+#include - #include - #include - -diff --git a/src/Gui/Action.cpp b/src/Gui/Action.cpp -index 3ab26d391..d36dac0e7 100644 ---- a/src/Gui/Action.cpp -+++ b/src/Gui/Action.cpp -@@ -25,7 +25,7 @@ - - #ifndef _PreComp_ - # include --# include -+# include - # include - # include - # include -@@ -54,6 +54,7 @@ - - using namespace Gui; - using namespace Gui::Dialog; -+namespace bp = boost::placeholders; - - /** - * Constructs an action called \a name with parent \a parent. It also stores a pointer -@@ -501,9 +502,9 @@ WorkbenchGroup::WorkbenchGroup ( Command* pcCmd, QObject * parent ) - action->setData(QVariant(i)); // set the index - } - -- Application::Instance->signalActivateWorkbench.connect(boost::bind(&WorkbenchGroup::slotActivateWorkbench, this, _1)); -- Application::Instance->signalAddWorkbench.connect(boost::bind(&WorkbenchGroup::slotAddWorkbench, this, _1)); -- Application::Instance->signalRemoveWorkbench.connect(boost::bind(&WorkbenchGroup::slotRemoveWorkbench, this, _1)); -+ Application::Instance->signalActivateWorkbench.connect(boost::bind(&WorkbenchGroup::slotActivateWorkbench, this, bp::_1)); -+ Application::Instance->signalAddWorkbench.connect(boost::bind(&WorkbenchGroup::slotAddWorkbench, this, bp::_1)); -+ Application::Instance->signalRemoveWorkbench.connect(boost::bind(&WorkbenchGroup::slotRemoveWorkbench, this, bp::_1)); - } - - WorkbenchGroup::~WorkbenchGroup() -diff --git a/src/Gui/Application.cpp b/src/Gui/Application.cpp -index 4d36537fe..ebb99d017 100644 ---- a/src/Gui/Application.cpp -+++ b/src/Gui/Application.cpp -@@ -26,7 +26,7 @@ - #ifndef _PreComp_ - # include "InventorAll.h" - # include --# include -+# include - # include - # include - # include -@@ -131,6 +131,7 @@ - using namespace Gui; - using namespace Gui::DockWnd; - using namespace std; -+namespace bp = boost::placeholders; - - - Application* Application::Instance = 0L; -@@ -286,12 +287,11 @@ Application::Application(bool GUIenabled) - { - //App::GetApplication().Attach(this); - if (GUIenabled) { -- App::GetApplication().signalNewDocument.connect(boost::bind(&Gui::Application::slotNewDocument, this, _1)); -- App::GetApplication().signalDeleteDocument.connect(boost::bind(&Gui::Application::slotDeleteDocument, this, _1)); -- App::GetApplication().signalRenameDocument.connect(boost::bind(&Gui::Application::slotRenameDocument, this, _1)); -- App::GetApplication().signalActiveDocument.connect(boost::bind(&Gui::Application::slotActiveDocument, this, _1)); -- App::GetApplication().signalRelabelDocument.connect(boost::bind(&Gui::Application::slotRelabelDocument, this, _1)); -- -+ App::GetApplication().signalNewDocument.connect(boost::bind(&Gui::Application::slotNewDocument, this, bp::_1)); -+ App::GetApplication().signalDeleteDocument.connect(boost::bind(&Gui::Application::slotDeleteDocument, this, bp::_1)); -+ App::GetApplication().signalRenameDocument.connect(boost::bind(&Gui::Application::slotRenameDocument, this, bp::_1)); -+ App::GetApplication().signalActiveDocument.connect(boost::bind(&Gui::Application::slotActiveDocument, this, bp::_1)); -+ App::GetApplication().signalRelabelDocument.connect(boost::bind(&Gui::Application::slotRelabelDocument, this, bp::_1)); - - // install the last active language - ParameterGrp::handle hPGrp = App::GetApplication().GetUserParameter().GetGroup("BaseApp"); -@@ -677,13 +677,13 @@ void Application::slotNewDocument(const App::Document& Doc) - d->documents[&Doc] = pDoc; - - // connect the signals to the application for the new document -- pDoc->signalNewObject.connect(boost::bind(&Gui::Application::slotNewObject, this, _1)); -- pDoc->signalDeletedObject.connect(boost::bind(&Gui::Application::slotDeletedObject, this, _1)); -- pDoc->signalChangedObject.connect(boost::bind(&Gui::Application::slotChangedObject, this, _1, _2)); -- pDoc->signalRelabelObject.connect(boost::bind(&Gui::Application::slotRelabelObject, this, _1)); -- pDoc->signalActivatedObject.connect(boost::bind(&Gui::Application::slotActivatedObject, this, _1)); -- pDoc->signalInEdit.connect(boost::bind(&Gui::Application::slotInEdit, this, _1)); -- pDoc->signalResetEdit.connect(boost::bind(&Gui::Application::slotResetEdit, this, _1)); -+ pDoc->signalNewObject.connect(boost::bind(&Gui::Application::slotNewObject, this, bp::_1)); -+ pDoc->signalDeletedObject.connect(boost::bind(&Gui::Application::slotDeletedObject, this, bp::_1)); -+ pDoc->signalChangedObject.connect(boost::bind(&Gui::Application::slotChangedObject, this, bp::_1, bp::_2)); -+ pDoc->signalRelabelObject.connect(boost::bind(&Gui::Application::slotRelabelObject, this, bp::_1)); -+ pDoc->signalActivatedObject.connect(boost::bind(&Gui::Application::slotActivatedObject, this, bp::_1)); -+ pDoc->signalInEdit.connect(boost::bind(&Gui::Application::slotInEdit, this, bp::_1)); -+ pDoc->signalResetEdit.connect(boost::bind(&Gui::Application::slotResetEdit, this, bp::_1)); - - signalNewDocument(*pDoc); - pDoc->createView(View3DInventor::getClassTypeId()); -diff --git a/src/Gui/AutoSaver.cpp b/src/Gui/AutoSaver.cpp -index 98f020ee6..ff72b42cc 100644 ---- a/src/Gui/AutoSaver.cpp -+++ b/src/Gui/AutoSaver.cpp -@@ -29,7 +29,7 @@ - # include - # include - # include --# include -+# include - # include - #endif - -@@ -50,14 +50,15 @@ - #include "ViewProvider.h" - - using namespace Gui; -+namespace bp = boost::placeholders; - - AutoSaver* AutoSaver::self = 0; - - AutoSaver::AutoSaver(QObject* parent) - : QObject(parent), timeout(900000), compressed(true) - { -- App::GetApplication().signalNewDocument.connect(boost::bind(&AutoSaver::slotCreateDocument, this, _1)); -- App::GetApplication().signalDeleteDocument.connect(boost::bind(&AutoSaver::slotDeleteDocument, this, _1)); -+ App::GetApplication().signalNewDocument.connect(boost::bind(&AutoSaver::slotCreateDocument, this, bp::_1)); -+ App::GetApplication().signalDeleteDocument.connect(boost::bind(&AutoSaver::slotDeleteDocument, this, bp::_1)); - } - - AutoSaver::~AutoSaver() -@@ -227,9 +228,9 @@ void AutoSaver::timerEvent(QTimerEvent * event) - AutoSaveProperty::AutoSaveProperty(const App::Document* doc) : timerId(-1) - { - documentNew = const_cast(doc)->signalNewObject.connect -- (boost::bind(&AutoSaveProperty::slotNewObject, this, _1)); -+ (boost::bind(&AutoSaveProperty::slotNewObject, this, bp::_1)); - documentMod = const_cast(doc)->signalChangedObject.connect -- (boost::bind(&AutoSaveProperty::slotChangePropertyData, this, _2)); -+ (boost::bind(&AutoSaveProperty::slotChangePropertyData, this, bp::_2)); - } - - AutoSaveProperty::~AutoSaveProperty() -diff --git a/src/Gui/CommandView.cpp b/src/Gui/CommandView.cpp -index ad53be551..a62c54355 100644 ---- a/src/Gui/CommandView.cpp -+++ b/src/Gui/CommandView.cpp -@@ -36,7 +36,7 @@ - # include - # include - # include --# include -+# include - #endif - - #include "Command.h" -@@ -86,6 +86,7 @@ - - using namespace Gui; - using Gui::Dialog::DlgSettingsImageImp; -+namespace bp = boost::placeholders; - - //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - -@@ -573,7 +574,7 @@ StdCmdDrawStyle::StdCmdDrawStyle() - sPixmap = "DrawStyleAsIs"; - eType = Alter3DView; - -- this->getGuiApplication()->signalActivateView.connect(boost::bind(&StdCmdDrawStyle::updateIcon, this, _1)); -+ this->getGuiApplication()->signalActivateView.connect(boost::bind(&StdCmdDrawStyle::updateIcon, this, bp::_1)); - } - - Gui::Action * StdCmdDrawStyle::createAction(void) -diff --git a/src/Gui/DAGView/DAGModel.cpp b/src/Gui/DAGView/DAGModel.cpp -index 31ace8757..e9ec3b26b 100644 ---- a/src/Gui/DAGView/DAGModel.cpp -+++ b/src/Gui/DAGView/DAGModel.cpp -@@ -22,7 +22,7 @@ - - #include "PreCompiled.h" - #ifndef _PreComp_ --#include -+#include - #include - #include - -@@ -62,6 +62,7 @@ - - using namespace Gui; - using namespace DAG; -+namespace bp = boost::placeholders; - - LineEdit::LineEdit(QWidget* parentIn): QLineEdit(parentIn) - { -@@ -143,11 +144,11 @@ Model::Model(QObject *parentIn, const Gui::Document &documentIn) : QGraphicsScen - connect(this->editingFinishedAction, SIGNAL(triggered()), - this, SLOT(editingFinishedSlot())); - -- connectNewObject = documentIn.signalNewObject.connect(boost::bind(&Model::slotNewObject, this, _1)); -- connectDelObject = documentIn.signalDeletedObject.connect(boost::bind(&Model::slotDeleteObject, this, _1)); -- connectChgObject = documentIn.signalChangedObject.connect(boost::bind(&Model::slotChangeObject, this, _1, _2)); -- connectEdtObject = documentIn.signalInEdit.connect(boost::bind(&Model::slotInEdit, this, _1)); -- connectResObject = documentIn.signalResetEdit.connect(boost::bind(&Model::slotResetEdit, this, _1)); -+ connectNewObject = documentIn.signalNewObject.connect(boost::bind(&Model::slotNewObject, this, bp::_1)); -+ connectDelObject = documentIn.signalDeletedObject.connect(boost::bind(&Model::slotDeleteObject, this, bp::_1)); -+ connectChgObject = documentIn.signalChangedObject.connect(boost::bind(&Model::slotChangeObject, this, bp::_1, bp::_2)); -+ connectEdtObject = documentIn.signalInEdit.connect(boost::bind(&Model::slotInEdit, this, bp::_1)); -+ connectResObject = documentIn.signalResetEdit.connect(boost::bind(&Model::slotResetEdit, this, bp::_1)); - } - - Model::~Model() -diff --git a/src/Gui/DAGView/DAGView.cpp b/src/Gui/DAGView/DAGView.cpp -index 501a424a2..1dc3a907f 100644 ---- a/src/Gui/DAGView/DAGView.cpp -+++ b/src/Gui/DAGView/DAGView.cpp -@@ -22,6 +22,7 @@ - - #include "PreCompiled.h" - #ifndef _PreComp_ -+#include - #include - #include - #endif -@@ -39,6 +40,7 @@ - - using namespace Gui; - using namespace DAG; -+namespace bp = boost::placeholders; - - DAG::DockWindow::DockWindow(Gui::Document* gDocumentIn, QWidget* parent): Gui::DockWindow(gDocumentIn, parent) - { -@@ -52,8 +54,8 @@ View::View(QWidget* parentIn): QGraphicsView(parentIn) - { - this->setRenderHint(QPainter::Antialiasing, true); - this->setRenderHint(QPainter::TextAntialiasing, true); -- Application::Instance->signalActiveDocument.connect(boost::bind(&View::slotActiveDocument, this, _1)); -- Application::Instance->signalDeleteDocument.connect(boost::bind(&View::slotDeleteDocument, this, _1)); -+ Application::Instance->signalActiveDocument.connect(boost::bind(&View::slotActiveDocument, this, bp::_1)); -+ Application::Instance->signalDeleteDocument.connect(boost::bind(&View::slotDeleteDocument, this, bp::_1)); - - //just update the dagview when the gui process is idle. - connect(QAbstractEventDispatcher::instance(), SIGNAL(awake()), this, SLOT(awakeSlot())); -@@ -61,8 +63,8 @@ View::View(QWidget* parentIn): QGraphicsView(parentIn) - - View::~View() - { -- Application::Instance->signalActiveDocument.disconnect(boost::bind(&View::slotActiveDocument, this, _1)); -- Application::Instance->signalDeleteDocument.disconnect(boost::bind(&View::slotDeleteDocument, this, _1)); -+ Application::Instance->signalActiveDocument.disconnect(boost::bind(&View::slotActiveDocument, this, bp::_1)); -+ Application::Instance->signalDeleteDocument.disconnect(boost::bind(&View::slotDeleteDocument, this, bp::_1)); - } - - void View::slotActiveDocument(const Document &documentIn) -diff --git a/src/Gui/DlgDisplayPropertiesImp.cpp b/src/Gui/DlgDisplayPropertiesImp.cpp -index eaedaaaf2..a4d2ffdee 100644 ---- a/src/Gui/DlgDisplayPropertiesImp.cpp -+++ b/src/Gui/DlgDisplayPropertiesImp.cpp -@@ -24,7 +24,7 @@ - #include "PreCompiled.h" - #ifndef _PreComp_ - # include --# include -+# include - # include - #endif - -@@ -49,6 +49,7 @@ - - using namespace Gui::Dialog; - using namespace std; -+namespace bp = boost::placeholders; - - - /* TRANSLATOR Gui::Dialog::DlgDisplayPropertiesImp */ -@@ -96,7 +97,7 @@ DlgDisplayPropertiesImp::DlgDisplayPropertiesImp( QWidget* parent, Qt::WindowFla - - this->connectChangedObject = - Gui::Application::Instance->signalChangedObject.connect(boost::bind -- (&DlgDisplayPropertiesImp::slotChangedObject, this, _1, _2)); -+ (&DlgDisplayPropertiesImp::slotChangedObject, this, bp::_1, bp::_2)); - } - - /** -diff --git a/src/Gui/Document.cpp b/src/Gui/Document.cpp -index 92493af1b..76570134c 100644 ---- a/src/Gui/Document.cpp -+++ b/src/Gui/Document.cpp -@@ -33,7 +33,7 @@ - # include - # include - # include --# include -+# include - # include - # include - #endif -@@ -68,6 +68,7 @@ - #include "Thumbnail.h" - - using namespace Gui; -+namespace bp = boost::placeholders; - - namespace Gui { - -@@ -132,40 +133,40 @@ Document::Document(App::Document* pcDocument,Application * app) - - // Setup the connections - d->connectNewObject = pcDocument->signalNewObject.connect -- (boost::bind(&Gui::Document::slotNewObject, this, _1)); -+ (boost::bind(&Gui::Document::slotNewObject, this, bp::_1)); - d->connectDelObject = pcDocument->signalDeletedObject.connect -- (boost::bind(&Gui::Document::slotDeletedObject, this, _1)); -+ (boost::bind(&Gui::Document::slotDeletedObject, this, bp::_1)); - d->connectCngObject = pcDocument->signalChangedObject.connect -- (boost::bind(&Gui::Document::slotChangedObject, this, _1, _2)); -+ (boost::bind(&Gui::Document::slotChangedObject, this, bp::_1, bp::_2)); - d->connectRenObject = pcDocument->signalRelabelObject.connect -- (boost::bind(&Gui::Document::slotRelabelObject, this, _1)); -+ (boost::bind(&Gui::Document::slotRelabelObject, this, bp::_1)); - d->connectActObject = pcDocument->signalActivatedObject.connect -- (boost::bind(&Gui::Document::slotActivatedObject, this, _1)); -+ (boost::bind(&Gui::Document::slotActivatedObject, this, bp::_1)); - d->connectActObjectBlocker = boost::signals2::shared_connection_block - (d->connectActObject, false); - d->connectSaveDocument = pcDocument->signalSaveDocument.connect -- (boost::bind(&Gui::Document::Save, this, _1)); -+ (boost::bind(&Gui::Document::Save, this, bp::_1)); - d->connectRestDocument = pcDocument->signalRestoreDocument.connect -- (boost::bind(&Gui::Document::Restore, this, _1)); -+ (boost::bind(&Gui::Document::Restore, this, bp::_1)); - d->connectStartLoadDocument = App::GetApplication().signalStartRestoreDocument.connect -- (boost::bind(&Gui::Document::slotStartRestoreDocument, this, _1)); -+ (boost::bind(&Gui::Document::slotStartRestoreDocument, this, bp::_1)); - d->connectFinishLoadDocument = App::GetApplication().signalFinishRestoreDocument.connect -- (boost::bind(&Gui::Document::slotFinishRestoreDocument, this, _1)); -+ (boost::bind(&Gui::Document::slotFinishRestoreDocument, this, bp::_1)); - - d->connectExportObjects = pcDocument->signalExportViewObjects.connect -- (boost::bind(&Gui::Document::exportObjects, this, _1, _2)); -+ (boost::bind(&Gui::Document::exportObjects, this, bp::_1, bp::_2)); - d->connectImportObjects = pcDocument->signalImportViewObjects.connect -- (boost::bind(&Gui::Document::importObjects, this, _1, _2, _3)); -+ (boost::bind(&Gui::Document::importObjects, this, bp::_1, bp::_2, bp::_3)); - - d->connectUndoDocument = pcDocument->signalUndo.connect -- (boost::bind(&Gui::Document::slotUndoDocument, this, _1)); -+ (boost::bind(&Gui::Document::slotUndoDocument, this, bp::_1)); - d->connectRedoDocument = pcDocument->signalRedo.connect -- (boost::bind(&Gui::Document::slotRedoDocument, this, _1)); -+ (boost::bind(&Gui::Document::slotRedoDocument, this, bp::_1)); - - d->connectTransactionAppend = pcDocument->signalTransactionAppend.connect -- (boost::bind(&Gui::Document::slotTransactionAppend, this, _1, _2)); -+ (boost::bind(&Gui::Document::slotTransactionAppend, this, bp::_1, bp::_2)); - d->connectTransactionRemove = pcDocument->signalTransactionRemove.connect -- (boost::bind(&Gui::Document::slotTransactionRemove, this, _1, _2)); -+ (boost::bind(&Gui::Document::slotTransactionRemove, this, bp::_1, bp::_2)); - // pointer to the python class - // NOTE: As this Python object doesn't get returned to the interpreter we - // mustn't increment it (Werner Jan-12-2006) -diff --git a/src/Gui/DocumentModel.cpp b/src/Gui/DocumentModel.cpp -index 4ec20c140..f9e206787 100644 ---- a/src/Gui/DocumentModel.cpp -+++ b/src/Gui/DocumentModel.cpp -@@ -27,7 +27,7 @@ - # include - # include - # include --# include -+# include - #endif - - #include -@@ -42,6 +42,7 @@ - #include - - using namespace Gui; -+namespace bp = boost::placeholders; - - namespace Gui { - // forward declaration -@@ -367,11 +368,11 @@ DocumentModel::DocumentModel(QObject* parent) - } - - // Setup connections -- Application::Instance->signalNewDocument.connect(boost::bind(&DocumentModel::slotNewDocument, this, _1)); -- Application::Instance->signalDeleteDocument.connect(boost::bind(&DocumentModel::slotDeleteDocument, this, _1)); -- Application::Instance->signalRenameDocument.connect(boost::bind(&DocumentModel::slotRenameDocument, this, _1)); -- Application::Instance->signalActiveDocument.connect(boost::bind(&DocumentModel::slotActiveDocument, this, _1)); -- Application::Instance->signalRelabelDocument.connect(boost::bind(&DocumentModel::slotRelabelDocument, this, _1)); -+ Application::Instance->signalNewDocument.connect(boost::bind(&DocumentModel::slotNewDocument, this, bp::_1)); -+ Application::Instance->signalDeleteDocument.connect(boost::bind(&DocumentModel::slotDeleteDocument, this, bp::_1)); -+ Application::Instance->signalRenameDocument.connect(boost::bind(&DocumentModel::slotRenameDocument, this, bp::_1)); -+ Application::Instance->signalActiveDocument.connect(boost::bind(&DocumentModel::slotActiveDocument, this, bp::_1)); -+ Application::Instance->signalRelabelDocument.connect(boost::bind(&DocumentModel::slotRelabelDocument, this, bp::_1)); - } - - DocumentModel::~DocumentModel() -@@ -381,13 +382,13 @@ DocumentModel::~DocumentModel() - - void DocumentModel::slotNewDocument(const Gui::Document& Doc) - { -- Doc.signalNewObject.connect(boost::bind(&DocumentModel::slotNewObject, this, _1)); -- Doc.signalDeletedObject.connect(boost::bind(&DocumentModel::slotDeleteObject, this, _1)); -- Doc.signalChangedObject.connect(boost::bind(&DocumentModel::slotChangeObject, this, _1, _2)); -- Doc.signalRelabelObject.connect(boost::bind(&DocumentModel::slotRenameObject, this, _1)); -- Doc.signalActivatedObject.connect(boost::bind(&DocumentModel::slotActiveObject, this, _1)); -- Doc.signalInEdit.connect(boost::bind(&DocumentModel::slotInEdit, this, _1)); -- Doc.signalResetEdit.connect(boost::bind(&DocumentModel::slotResetEdit, this, _1)); -+ Doc.signalNewObject.connect(boost::bind(&DocumentModel::slotNewObject, this, bp::_1)); -+ Doc.signalDeletedObject.connect(boost::bind(&DocumentModel::slotDeleteObject, this, bp::_1)); -+ Doc.signalChangedObject.connect(boost::bind(&DocumentModel::slotChangeObject, this, bp::_1, bp::_2)); -+ Doc.signalRelabelObject.connect(boost::bind(&DocumentModel::slotRenameObject, this, bp::_1)); -+ Doc.signalActivatedObject.connect(boost::bind(&DocumentModel::slotActiveObject, this, bp::_1)); -+ Doc.signalInEdit.connect(boost::bind(&DocumentModel::slotInEdit, this, bp::_1)); -+ Doc.signalResetEdit.connect(boost::bind(&DocumentModel::slotResetEdit, this, bp::_1)); - - QModelIndex parent = createIndex(0,0,d->rootItem); - int count_docs = d->rootItem->childCount(); -diff --git a/src/Gui/DocumentObserver.cpp b/src/Gui/DocumentObserver.cpp -index 7de3ccf92..d51030a2e 100644 ---- a/src/Gui/DocumentObserver.cpp -+++ b/src/Gui/DocumentObserver.cpp -@@ -25,10 +25,9 @@ - - #ifndef _PreComp_ - # include -+# include - #endif - --#include -- - #include "Application.h" - #include "Document.h" - #include "ViewProviderDocumentObject.h" -@@ -36,6 +35,7 @@ - #include - - using namespace Gui; -+namespace bp = boost::placeholders; - - - DocumentT::DocumentT() -@@ -215,25 +215,25 @@ void DocumentObserver::attachDocument(Document* doc) - return; - - this->connectDocumentCreatedObject = doc->signalNewObject.connect(boost::bind -- (&DocumentObserver::slotCreatedObject, this, _1)); -+ (&DocumentObserver::slotCreatedObject, this, bp::_1)); - this->connectDocumentDeletedObject = doc->signalDeletedObject.connect(boost::bind -- (&DocumentObserver::slotDeletedObject, this, _1)); -+ (&DocumentObserver::slotDeletedObject, this, bp::_1)); - this->connectDocumentChangedObject = doc->signalChangedObject.connect(boost::bind -- (&DocumentObserver::slotChangedObject, this, _1, _2)); -+ (&DocumentObserver::slotChangedObject, this, bp::_1, bp::_2)); - this->connectDocumentRelabelObject = doc->signalRelabelObject.connect(boost::bind -- (&DocumentObserver::slotRelabelObject, this, _1)); -+ (&DocumentObserver::slotRelabelObject, this, bp::_1)); - this->connectDocumentActivateObject = doc->signalActivatedObject.connect(boost::bind -- (&DocumentObserver::slotActivatedObject, this, _1)); -+ (&DocumentObserver::slotActivatedObject, this, bp::_1)); - this->connectDocumentEditObject = doc->signalInEdit.connect(boost::bind -- (&DocumentObserver::slotEnterEditObject, this, _1)); -+ (&DocumentObserver::slotEnterEditObject, this, bp::_1)); - this->connectDocumentResetObject = doc->signalResetEdit.connect(boost::bind -- (&DocumentObserver::slotResetEditObject, this, _1)); -+ (&DocumentObserver::slotResetEditObject, this, bp::_1)); - this->connectDocumentUndo = doc->signalUndoDocument.connect(boost::bind -- (&DocumentObserver::slotUndoDocument, this, _1)); -+ (&DocumentObserver::slotUndoDocument, this, bp::_1)); - this->connectDocumentRedo = doc->signalRedoDocument.connect(boost::bind -- (&DocumentObserver::slotRedoDocument, this, _1)); -+ (&DocumentObserver::slotRedoDocument, this, bp::_1)); - this->connectDocumentDelete = doc->signalDeleteDocument.connect(boost::bind -- (&DocumentObserver::slotDeleteDocument, this, _1)); -+ (&DocumentObserver::slotDeleteDocument, this, bp::_1)); - } - - void DocumentObserver::detachDocument() -diff --git a/src/Gui/DocumentObserverPython.cpp b/src/Gui/DocumentObserverPython.cpp -index ddcb8ae0b..cfa622bf1 100644 ---- a/src/Gui/DocumentObserverPython.cpp -+++ b/src/Gui/DocumentObserverPython.cpp -@@ -35,6 +35,7 @@ - #include - - using namespace Gui; -+namespace bp = boost::placeholders; - - std::vector DocumentObserverPython::_instances; - -@@ -61,27 +62,27 @@ void DocumentObserverPython::removeObserver(const Py::Object& obj) - DocumentObserverPython::DocumentObserverPython(const Py::Object& obj) : inst(obj) - { - this->connectApplicationCreatedDocument = Gui::Application::Instance->signalNewDocument.connect(boost::bind -- (&DocumentObserverPython::slotCreatedDocument, this, _1)); -+ (&DocumentObserverPython::slotCreatedDocument, this, bp::_1)); - this->connectApplicationDeletedDocument = Gui::Application::Instance->signalDeleteDocument.connect(boost::bind -- (&DocumentObserverPython::slotDeletedDocument, this, _1)); -+ (&DocumentObserverPython::slotDeletedDocument, this, bp::_1)); - this->connectApplicationRelabelDocument = Gui::Application::Instance->signalRelabelDocument.connect(boost::bind -- (&DocumentObserverPython::slotRelabelDocument, this, _1)); -+ (&DocumentObserverPython::slotRelabelDocument, this, bp::_1)); - this->connectApplicationRenameDocument = Gui::Application::Instance->signalRenameDocument.connect(boost::bind -- (&DocumentObserverPython::slotRelabelDocument, this, _1)); -+ (&DocumentObserverPython::slotRelabelDocument, this, bp::_1)); - this->connectApplicationActivateDocument = Gui::Application::Instance->signalActiveDocument.connect(boost::bind -- (&DocumentObserverPython::slotActivateDocument, this, _1)); -+ (&DocumentObserverPython::slotActivateDocument, this, bp::_1)); - - this->connectDocumentCreatedObject = Gui::Application::Instance->signalNewObject.connect(boost::bind -- (&DocumentObserverPython::slotCreatedObject, this, _1)); -+ (&DocumentObserverPython::slotCreatedObject, this, bp::_1)); - this->connectDocumentDeletedObject = Gui::Application::Instance->signalDeletedObject.connect(boost::bind -- (&DocumentObserverPython::slotDeletedObject, this, _1)); -+ (&DocumentObserverPython::slotDeletedObject, this, bp::_1)); - this->connectDocumentChangedObject = Gui::Application::Instance->signalChangedObject.connect(boost::bind -- (&DocumentObserverPython::slotChangedObject, this, _1, _2)); -+ (&DocumentObserverPython::slotChangedObject, this, bp::_1, bp::_2)); - - this->connectDocumentObjectInEdit = Gui::Application::Instance->signalInEdit.connect(boost::bind -- (&DocumentObserverPython::slotInEdit, this, _1)); -+ (&DocumentObserverPython::slotInEdit, this, bp::_1)); - this->connectDocumentObjectResetEdit = Gui::Application::Instance->signalResetEdit.connect(boost::bind -- (&DocumentObserverPython::slotResetEdit, this, _1)); -+ (&DocumentObserverPython::slotResetEdit, this, bp::_1)); - - } - -diff --git a/src/Gui/DocumentObserverPython.h b/src/Gui/DocumentObserverPython.h -index ca3318a79..71a2e7f25 100644 ---- a/src/Gui/DocumentObserverPython.h -+++ b/src/Gui/DocumentObserverPython.h -@@ -27,7 +27,7 @@ - #include - - #include --#include -+#include - - namespace Gui - { -diff --git a/src/Gui/ExpressionBinding.cpp b/src/Gui/ExpressionBinding.cpp -index 1bd8bbaa8..47233bccc 100644 ---- a/src/Gui/ExpressionBinding.cpp -+++ b/src/Gui/ExpressionBinding.cpp -@@ -32,10 +32,11 @@ - #include - #include - #include --#include -+#include - - using namespace Gui; - using namespace App; -+namespace bp = boost::placeholders; - - ExpressionBinding::ExpressionBinding() - : iconLabel(0) -@@ -83,7 +84,7 @@ void ExpressionBinding::bind(const App::ObjectIdentifier &_path) - - //connect to be informed about changes - DocumentObject * docObj = path.getDocumentObject(); -- connection = docObj->ExpressionEngine.expressionChanged.connect(boost::bind(&ExpressionBinding::expressionChange, this, _1)); -+ connection = docObj->ExpressionEngine.expressionChanged.connect(boost::bind(&ExpressionBinding::expressionChange, this, bp::_1)); - } - - void ExpressionBinding::bind(const Property &prop) -diff --git a/src/Gui/GraphvizView.cpp b/src/Gui/GraphvizView.cpp -index afffc6244..62e69ef85 100644 ---- a/src/Gui/GraphvizView.cpp -+++ b/src/Gui/GraphvizView.cpp -@@ -37,7 +37,7 @@ - # include - # include - # include --# include -+# include - #endif - #include "GraphicsViewZoom.h" - #include "FileDialog.h" -@@ -50,6 +50,7 @@ - #include - - using namespace Gui; -+namespace bp = boost::placeholders; - - namespace Gui { - -@@ -187,9 +188,9 @@ GraphvizView::GraphvizView(App::Document & _doc, QWidget* parent) - connect(thread, SIGNAL(svgFileRead(const QByteArray &)), this, SLOT(svgFileRead(const QByteArray &))); - - // Connect signal from document -- recomputeConnection = _doc.signalRecomputed.connect(boost::bind(&GraphvizView::updateSvgItem, this, _1)); -- undoConnection = _doc.signalUndo.connect(boost::bind(&GraphvizView::updateSvgItem, this, _1)); -- redoConnection = _doc.signalRedo.connect(boost::bind(&GraphvizView::updateSvgItem, this, _1)); -+ recomputeConnection = _doc.signalRecomputed.connect(boost::bind(&GraphvizView::updateSvgItem, this, bp::_1)); -+ undoConnection = _doc.signalUndo.connect(boost::bind(&GraphvizView::updateSvgItem, this, bp::_1)); -+ redoConnection = _doc.signalRedo.connect(boost::bind(&GraphvizView::updateSvgItem, this, bp::_1)); - - updateSvgItem(_doc); - } -diff --git a/src/Gui/MDIView.cpp b/src/Gui/MDIView.cpp -index 6d8fbcc5f..364a2ea29 100644 ---- a/src/Gui/MDIView.cpp -+++ b/src/Gui/MDIView.cpp -@@ -25,7 +25,7 @@ - - #ifndef _PreComp_ - # include --# include -+# include - # include - # include - # include -@@ -43,6 +43,7 @@ - #include "ViewProviderDocumentObject.h" - - using namespace Gui; -+namespace bp = boost::placeholders; - - TYPESYSTEM_SOURCE_ABSTRACT(Gui::MDIView,Gui::BaseView); - -@@ -55,7 +56,7 @@ MDIView::MDIView(Gui::Document* pcDocument,QWidget* parent, Qt::WindowFlags wfla - if (pcDocument) - { - connectDelObject = pcDocument->signalDeletedObject.connect -- (boost::bind(&ActiveObjectList::objectDeleted, &ActiveObjects, _1)); -+ (boost::bind(&ActiveObjectList::objectDeleted, &ActiveObjects, bp::_1)); - assert(connectDelObject.connected()); - } - } -diff --git a/src/Gui/MainWindow.cpp b/src/Gui/MainWindow.cpp -index 2ce27c3b1..d78b34858 100644 ---- a/src/Gui/MainWindow.cpp -+++ b/src/Gui/MainWindow.cpp -@@ -51,8 +51,6 @@ - # include - #endif - --#include -- - // FreeCAD Base header - #include - #include -diff --git a/src/Gui/ManualAlignment.cpp b/src/Gui/ManualAlignment.cpp -index 8ae2323f0..4ea40f542 100644 ---- a/src/Gui/ManualAlignment.cpp -+++ b/src/Gui/ManualAlignment.cpp -@@ -47,9 +47,9 @@ - # include - # include - # include -+# include - #endif - --#include - - #include - #include -@@ -70,6 +70,7 @@ - - - using namespace Gui; -+namespace bp = boost::placeholders; - - AlignmentGroup::AlignmentGroup() - { -@@ -643,7 +644,7 @@ ManualAlignment::ManualAlignment() - { - // connect with the application's signal for deletion of documents - this->connectApplicationDeletedDocument = Gui::Application::Instance->signalDeleteDocument -- .connect(boost::bind(&ManualAlignment::slotDeletedDocument, this, _1)); -+ .connect(boost::bind(&ManualAlignment::slotDeletedDocument, this, bp::_1)); - - // setup sensor connection - d->sensorCam1 = new SoNodeSensor(Private::syncCameraCB, this); -@@ -837,7 +838,7 @@ void ManualAlignment::startAlignment(Base::Type mousemodel) - if (this->connectDocumentDeletedObject.connected()) - this->connectDocumentDeletedObject.disconnect(); - this->connectDocumentDeletedObject = myDocument->signalDeletedObject.connect(boost::bind -- (&ManualAlignment::slotDeletedObject, this, _1)); -+ (&ManualAlignment::slotDeletedObject, this, bp::_1)); - - continueAlignment(); - } -diff --git a/src/Gui/MergeDocuments.cpp b/src/Gui/MergeDocuments.cpp -index 93316f4fa..8d870a8ae 100644 ---- a/src/Gui/MergeDocuments.cpp -+++ b/src/Gui/MergeDocuments.cpp -@@ -23,7 +23,7 @@ - #include "PreCompiled.h" - #ifndef _PreComp_ - # include --# include -+# include - #endif - #include "MergeDocuments.h" - #include -@@ -36,6 +36,7 @@ - #include - - using namespace Gui; -+namespace bp = boost::placeholders; - - namespace Gui { - -@@ -118,9 +119,9 @@ private: - MergeDocuments::MergeDocuments(App::Document* doc) : stream(0), appdoc(doc) - { - connectExport = doc->signalExportObjects.connect -- (boost::bind(&MergeDocuments::exportObject, this, _1, _2)); -+ (boost::bind(&MergeDocuments::exportObject, this, bp::_1, bp::_2)); - connectImport = doc->signalImportObjects.connect -- (boost::bind(&MergeDocuments::importObject, this, _1, _2)); -+ (boost::bind(&MergeDocuments::importObject, this, bp::_1, bp::_2)); - document = Gui::Application::Instance->getDocument(doc); - } - -diff --git a/src/Gui/Placement.cpp b/src/Gui/Placement.cpp -index da9449969..a9f0d95c8 100644 ---- a/src/Gui/Placement.cpp -+++ b/src/Gui/Placement.cpp -@@ -22,10 +22,13 @@ - - - #include "PreCompiled.h" -+#ifndef _PreComp_ - #include - #include - #include - #include -+#include -+#endif - - #include "Placement.h" - #include "ui_Placement.h" -@@ -44,6 +47,7 @@ - #include - - using namespace Gui::Dialog; -+namespace bp = boost::placeholders; - - namespace Gui { namespace Dialog { - class find_placement -@@ -115,7 +119,7 @@ Placement::Placement(QWidget* parent, Qt::WindowFlags fl) - connect(signalMapper, SIGNAL(mapped(int)), - this, SLOT(onPlacementChanged(int))); - connectAct = Application::Instance->signalActiveDocument.connect -- (boost::bind(&Placement::slotActiveDocument, this, _1)); -+ (boost::bind(&Placement::slotActiveDocument, this, bp::_1)); - App::Document* activeDoc = App::GetApplication().getActiveDocument(); - if (activeDoc) documents.insert(activeDoc->getName()); - -diff --git a/src/Gui/Placement.h b/src/Gui/Placement.h -index b2b3ef61e..f1a58cb38 100644 ---- a/src/Gui/Placement.h -+++ b/src/Gui/Placement.h -@@ -30,7 +30,6 @@ - #include - - #include --#include - - class QSignalMapper; - -diff --git a/src/Gui/PreCompiled.h b/src/Gui/PreCompiled.h -index 536e538d6..783b7cbe7 100644 ---- a/src/Gui/PreCompiled.h -+++ b/src/Gui/PreCompiled.h -@@ -76,7 +76,7 @@ - - // Boost - #include --#include -+#include - #include - #include - #include -diff --git a/src/Gui/ProjectView.cpp b/src/Gui/ProjectView.cpp -index bbef326fd..e4cfdfc52 100644 ---- a/src/Gui/ProjectView.cpp -+++ b/src/Gui/ProjectView.cpp -@@ -24,7 +24,6 @@ - #include "PreCompiled.h" - - #ifndef _PreComp_ --# include - # include - # include - # include -diff --git a/src/Gui/PropertyView.cpp b/src/Gui/PropertyView.cpp -index fed192f12..acb88e484 100644 ---- a/src/Gui/PropertyView.cpp -+++ b/src/Gui/PropertyView.cpp -@@ -26,9 +26,9 @@ - # include - # include - # include -+# include - #endif - --#include - - /// Here the FreeCAD includes sorted by Base,App,Gui...... - #include -@@ -51,6 +51,7 @@ using namespace std; - using namespace Gui; - using namespace Gui::DockWnd; - using namespace Gui::PropertyEditor; -+namespace bp = boost::placeholders; - - - /* TRANSLATOR Gui::PropertyView */ -@@ -97,22 +98,22 @@ PropertyView::PropertyView(QWidget *parent) - - this->connectPropData = - App::GetApplication().signalChangedObject.connect(boost::bind -- (&PropertyView::slotChangePropertyData, this, _1, _2)); -+ (&PropertyView::slotChangePropertyData, this, bp::_1, bp::_2)); - this->connectPropView = - Gui::Application::Instance->signalChangedObject.connect(boost::bind -- (&PropertyView::slotChangePropertyView, this, _1, _2)); -+ (&PropertyView::slotChangePropertyView, this, bp::_1, bp::_2)); - this->connectPropAppend = - App::GetApplication().signalAppendDynamicProperty.connect(boost::bind -- (&PropertyView::slotAppendDynamicProperty, this, _1)); -+ (&PropertyView::slotAppendDynamicProperty, this, bp::_1)); - this->connectPropRemove = - App::GetApplication().signalRemoveDynamicProperty.connect(boost::bind -- (&PropertyView::slotRemoveDynamicProperty, this, _1)); -+ (&PropertyView::slotRemoveDynamicProperty, this, bp::_1)); - this->connectPropChange = - App::GetApplication().signalChangePropertyEditor.connect(boost::bind -- (&PropertyView::slotChangePropertyEditor, this, _1)); -+ (&PropertyView::slotChangePropertyEditor, this, bp::_1)); - this->connectActiveDoc = - Application::Instance->signalActiveDocument.connect(boost::bind -- (&PropertyView::slotActiveDocument, this, _1)); -+ (&PropertyView::slotActiveDocument, this, bp::_1)); - } - - PropertyView::~PropertyView() -diff --git a/src/Gui/Selection.cpp b/src/Gui/Selection.cpp -index 44b6b7e58..4a9d19e8d 100644 ---- a/src/Gui/Selection.cpp -+++ b/src/Gui/Selection.cpp -@@ -26,7 +26,7 @@ - #ifndef _PreComp_ - # include - # include --# include -+# include - # include - # include - # include -@@ -52,6 +52,7 @@ FC_LOG_LEVEL_INIT("Selection",false,true,true) - - using namespace Gui; - using namespace std; -+namespace bp = boost::placeholders; - - SelectionObserver::SelectionObserver() : blockSelection(false) - { -@@ -82,7 +83,7 @@ void SelectionObserver::attachSelection() - { - if (!connectSelection.connected()) { - connectSelection = Selection().signalSelectionChanged.connect(boost::bind -- (&SelectionObserver::_onSelectionChanged, this, _1)); -+ (&SelectionObserver::_onSelectionChanged, this, bp::_1)); - } - } - -@@ -1026,7 +1027,7 @@ SelectionSingleton::SelectionSingleton() - hy = 0; - hz = 0; - ActiveGate = 0; -- App::GetApplication().signalDeletedObject.connect(boost::bind(&Gui::SelectionSingleton::slotDeletedObject, this, _1)); -+ App::GetApplication().signalDeletedObject.connect(boost::bind(&Gui::SelectionSingleton::slotDeletedObject, this, bp::_1)); - CurrentPreselection.Type = SelectionChanges::ClrSelection; - CurrentPreselection.pDocName = 0; - CurrentPreselection.pObjectName = 0; -diff --git a/src/Gui/TaskView/TaskAppearance.cpp b/src/Gui/TaskView/TaskAppearance.cpp -index 976f70713..450df1f56 100644 ---- a/src/Gui/TaskView/TaskAppearance.cpp -+++ b/src/Gui/TaskView/TaskAppearance.cpp -@@ -25,7 +25,7 @@ - - #ifndef _PreComp_ - # include --# include -+# include - #endif - - #include "ui_TaskAppearance.h" -@@ -38,6 +38,7 @@ - #include - - using namespace Gui::TaskView; -+namespace bp = boost::placeholders; - - /* TRANSLATOR Gui::TaskView::TaskAppearance */ - -@@ -57,7 +58,7 @@ TaskAppearance::TaskAppearance(QWidget *parent) - - this->connectChangedObject = - Gui::Application::Instance->signalChangedObject.connect(boost::bind -- (&TaskAppearance::slotChangedObject, this, _1, _2)); -+ (&TaskAppearance::slotChangedObject, this, bp::_1, bp::_2)); - } - - TaskAppearance::~TaskAppearance() -diff --git a/src/Gui/TaskView/TaskSelectLinkProperty.cpp b/src/Gui/TaskView/TaskSelectLinkProperty.cpp -index 62722df24..8d2faae0e 100644 ---- a/src/Gui/TaskView/TaskSelectLinkProperty.cpp -+++ b/src/Gui/TaskView/TaskSelectLinkProperty.cpp -@@ -25,7 +25,6 @@ - - #ifndef _PreComp_ - # include --# include - #endif - - #include "ui_TaskSelectLinkProperty.h" -diff --git a/src/Gui/TaskView/TaskView.cpp b/src/Gui/TaskView/TaskView.cpp -index 2a85b4147..1d18ce781 100644 ---- a/src/Gui/TaskView/TaskView.cpp -+++ b/src/Gui/TaskView/TaskView.cpp -@@ -24,7 +24,7 @@ - #include "PreCompiled.h" - - #ifndef _PreComp_ --# include -+# include - # include - # include - # include -@@ -52,6 +52,7 @@ - #endif - - using namespace Gui::TaskView; -+namespace bp = boost::placeholders; - - //************************************************************************** - //************************************************************************** -@@ -397,16 +398,16 @@ TaskView::TaskView(QWidget *parent) - - connectApplicationActiveDocument = - App::GetApplication().signalActiveDocument.connect -- (boost::bind(&Gui::TaskView::TaskView::slotActiveDocument, this, _1)); -+ (boost::bind(&Gui::TaskView::TaskView::slotActiveDocument, this, bp::_1)); - connectApplicationDeleteDocument = - App::GetApplication().signalDeletedDocument.connect - (boost::bind(&Gui::TaskView::TaskView::slotDeletedDocument, this)); - connectApplicationUndoDocument = - App::GetApplication().signalUndoDocument.connect -- (boost::bind(&Gui::TaskView::TaskView::slotUndoDocument, this, _1)); -+ (boost::bind(&Gui::TaskView::TaskView::slotUndoDocument, this, bp::_1)); - connectApplicationRedoDocument = - App::GetApplication().signalRedoDocument.connect -- (boost::bind(&Gui::TaskView::TaskView::slotRedoDocument, this, _1)); -+ (boost::bind(&Gui::TaskView::TaskView::slotRedoDocument, this, bp::_1)); - } - - TaskView::~TaskView() -diff --git a/src/Gui/TextDocumentEditorView.cpp b/src/Gui/TextDocumentEditorView.cpp -index 771114e62..c92daf224 100644 ---- a/src/Gui/TextDocumentEditorView.cpp -+++ b/src/Gui/TextDocumentEditorView.cpp -@@ -24,7 +24,7 @@ - #include "PreCompiled.h" - - #include --#include -+#include - #include - #include - #include -diff --git a/src/Gui/Tree.cpp b/src/Gui/Tree.cpp -index e3cbf44ef..3ebfa8ec0 100644 ---- a/src/Gui/Tree.cpp -+++ b/src/Gui/Tree.cpp -@@ -24,7 +24,7 @@ - #include "PreCompiled.h" - - #ifndef _PreComp_ --# include -+# include - # include - # include - # include -@@ -59,6 +59,7 @@ - #include "Widgets.h" - - using namespace Gui; -+namespace bp = boost::placeholders; - - QPixmap* TreeWidget::documentPixmap = 0; - const int TreeWidget::DocumentType = 1000; -@@ -115,11 +116,11 @@ TreeWidget::TreeWidget(QWidget* parent) - this, SLOT(onSearchObjects())); - - // Setup connections -- connectNewDocument = Application::Instance->signalNewDocument.connect(boost::bind(&TreeWidget::slotNewDocument, this, _1)); -- connectDelDocument = Application::Instance->signalDeleteDocument.connect(boost::bind(&TreeWidget::slotDeleteDocument, this, _1)); -- connectRenDocument = Application::Instance->signalRenameDocument.connect(boost::bind(&TreeWidget::slotRenameDocument, this, _1)); -- connectActDocument = Application::Instance->signalActiveDocument.connect(boost::bind(&TreeWidget::slotActiveDocument, this, _1)); -- connectRelDocument = Application::Instance->signalRelabelDocument.connect(boost::bind(&TreeWidget::slotRelabelDocument, this, _1)); -+ connectNewDocument = Application::Instance->signalNewDocument.connect(boost::bind(&TreeWidget::slotNewDocument, this, bp::_1)); -+ connectDelDocument = Application::Instance->signalDeleteDocument.connect(boost::bind(&TreeWidget::slotDeleteDocument, this, bp::_1)); -+ connectRenDocument = Application::Instance->signalRenameDocument.connect(boost::bind(&TreeWidget::slotRenameDocument, this, bp::_1)); -+ connectActDocument = Application::Instance->signalActiveDocument.connect(boost::bind(&TreeWidget::slotActiveDocument, this, bp::_1)); -+ connectRelDocument = Application::Instance->signalRelabelDocument.connect(boost::bind(&TreeWidget::slotRelabelDocument, this, bp::_1)); - - QStringList labels; - labels << tr("Labels & Attributes"); -@@ -1208,16 +1209,16 @@ DocumentItem::DocumentItem(const Gui::Document* doc, QTreeWidgetItem * parent) - : QTreeWidgetItem(parent, TreeWidget::DocumentType), pDocument(doc) - { - // Setup connections -- connectNewObject = doc->signalNewObject.connect(boost::bind(&DocumentItem::slotNewObject, this, _1)); -- connectDelObject = doc->signalDeletedObject.connect(boost::bind(&DocumentItem::slotDeleteObject, this, _1)); -- connectChgObject = doc->signalChangedObject.connect(boost::bind(&DocumentItem::slotChangeObject, this, _1)); -- connectRenObject = doc->signalRelabelObject.connect(boost::bind(&DocumentItem::slotRenameObject, this, _1)); -- connectActObject = doc->signalActivatedObject.connect(boost::bind(&DocumentItem::slotActiveObject, this, _1)); -- connectEdtObject = doc->signalInEdit.connect(boost::bind(&DocumentItem::slotInEdit, this, _1)); -- connectResObject = doc->signalResetEdit.connect(boost::bind(&DocumentItem::slotResetEdit, this, _1)); -- connectHltObject = doc->signalHighlightObject.connect(boost::bind(&DocumentItem::slotHighlightObject, this, _1,_2,_3)); -- connectExpObject = doc->signalExpandObject.connect(boost::bind(&DocumentItem::slotExpandObject, this, _1,_2)); -- connectScrObject = doc->signalScrollToObject.connect(boost::bind(&DocumentItem::slotScrollToObject, this, _1)); -+ connectNewObject = doc->signalNewObject.connect(boost::bind(&DocumentItem::slotNewObject, this, bp::_1)); -+ connectDelObject = doc->signalDeletedObject.connect(boost::bind(&DocumentItem::slotDeleteObject, this, bp::_1)); -+ connectChgObject = doc->signalChangedObject.connect(boost::bind(&DocumentItem::slotChangeObject, this, bp::_1)); -+ connectRenObject = doc->signalRelabelObject.connect(boost::bind(&DocumentItem::slotRenameObject, this, bp::_1)); -+ connectActObject = doc->signalActivatedObject.connect(boost::bind(&DocumentItem::slotActiveObject, this, bp::_1)); -+ connectEdtObject = doc->signalInEdit.connect(boost::bind(&DocumentItem::slotInEdit, this, bp::_1)); -+ connectResObject = doc->signalResetEdit.connect(boost::bind(&DocumentItem::slotResetEdit, this, bp::_1)); -+ connectHltObject = doc->signalHighlightObject.connect(boost::bind(&DocumentItem::slotHighlightObject, this, bp::_1,bp::_2,bp::_3)); -+ connectExpObject = doc->signalExpandObject.connect(boost::bind(&DocumentItem::slotExpandObject, this, bp::_1,bp::_2)); -+ connectScrObject = doc->signalScrollToObject.connect(boost::bind(&DocumentItem::slotScrollToObject, this, bp::_1)); - - setFlags(Qt::ItemIsEnabled/*|Qt::ItemIsEditable*/); - } -@@ -1812,8 +1813,8 @@ DocumentObjectItem::DocumentObjectItem(Gui::ViewProviderDocumentObject* pcViewPr - setFlags(flags()|Qt::ItemIsEditable); - // Setup connections - connectIcon = pcViewProvider->signalChangeIcon.connect(boost::bind(&DocumentObjectItem::slotChangeIcon, this)); -- connectTool = pcViewProvider->signalChangeToolTip.connect(boost::bind(&DocumentObjectItem::slotChangeToolTip, this, _1)); -- connectStat = pcViewProvider->signalChangeStatusTip.connect(boost::bind(&DocumentObjectItem::slotChangeStatusTip, this, _1)); -+ connectTool = pcViewProvider->signalChangeToolTip.connect(boost::bind(&DocumentObjectItem::slotChangeToolTip, this, bp::_1)); -+ connectStat = pcViewProvider->signalChangeStatusTip.connect(boost::bind(&DocumentObjectItem::slotChangeStatusTip, this, bp::_1)); - myselves->insert(this); - } - -diff --git a/src/Gui/ViewProvider.cpp b/src/Gui/ViewProvider.cpp -index de33ebe77..c3c514c47 100644 ---- a/src/Gui/ViewProvider.cpp -+++ b/src/Gui/ViewProvider.cpp -@@ -36,6 +36,7 @@ - # include - # include - # include -+# include - #endif - - /// Here the FreeCAD includes sorted by Base,App,Gui...... -@@ -55,7 +56,6 @@ - #include "SoFCDB.h" - #include "ViewProviderExtension.h" - --#include - - FC_LOG_LEVEL_INIT("ViewProvider",true,true) - -diff --git a/src/Gui/ViewProviderOrigin.cpp b/src/Gui/ViewProviderOrigin.cpp -index 7bce98c61..635d6d632 100644 ---- a/src/Gui/ViewProviderOrigin.cpp -+++ b/src/Gui/ViewProviderOrigin.cpp -@@ -29,7 +29,6 @@ - # include - # include - # include --# include - #endif - - -diff --git a/src/Gui/ViewProviderOriginGroup.cpp b/src/Gui/ViewProviderOriginGroup.cpp -index 264d54c0e..b16459c6e 100644 ---- a/src/Gui/ViewProviderOriginGroup.cpp -+++ b/src/Gui/ViewProviderOriginGroup.cpp -@@ -23,9 +23,6 @@ - #include "PreCompiled.h" - - #ifndef _PreComp_ --# include --# include --# include - #endif - - #include -diff --git a/src/Gui/ViewProviderOriginGroupExtension.cpp b/src/Gui/ViewProviderOriginGroupExtension.cpp -index 02577a025..15da22558 100644 ---- a/src/Gui/ViewProviderOriginGroupExtension.cpp -+++ b/src/Gui/ViewProviderOriginGroupExtension.cpp -@@ -25,6 +25,9 @@ - #include "PreCompiled.h" - - #ifndef _PreComp_ -+#include -+#include -+#include - #endif - - #include "ViewProviderOriginGroupExtension.h" -@@ -39,11 +42,10 @@ - #include - #include - #include --#include --#include --#include - - using namespace Gui; -+namespace bp = boost::placeholders; -+ - - EXTENSION_PROPERTY_SOURCE(Gui::ViewProviderOriginGroupExtension, Gui::ViewProviderGeoFeatureGroupExtension) - -@@ -97,10 +99,10 @@ void ViewProviderOriginGroupExtension::extensionAttach(App::DocumentObject *pcOb - assert ( gdoc ); - - connectChangedObjectApp = adoc->signalChangedObject.connect ( -- boost::bind ( &ViewProviderOriginGroupExtension::slotChangedObjectApp, this, _1) ); -+ boost::bind ( &ViewProviderOriginGroupExtension::slotChangedObjectApp, this, bp::_1) ); - - connectChangedObjectGui = gdoc->signalChangedObject.connect ( -- boost::bind ( &ViewProviderOriginGroupExtension::slotChangedObjectGui, this, _1) ); -+ boost::bind ( &ViewProviderOriginGroupExtension::slotChangedObjectGui, this, bp::_1) ); - } - - void ViewProviderOriginGroupExtension::extensionUpdateData( const App::Property* prop ) { -diff --git a/src/Gui/ViewProviderPart.cpp b/src/Gui/ViewProviderPart.cpp -index d59f10b49..252939936 100644 ---- a/src/Gui/ViewProviderPart.cpp -+++ b/src/Gui/ViewProviderPart.cpp -@@ -27,7 +27,7 @@ - # include - # include - # include --# include -+# include - #endif - - #include -diff --git a/src/Gui/ViewProviderPythonFeature.cpp b/src/Gui/ViewProviderPythonFeature.cpp -index 58891dd32..fbed4720c 100644 ---- a/src/Gui/ViewProviderPythonFeature.cpp -+++ b/src/Gui/ViewProviderPythonFeature.cpp -@@ -30,7 +30,7 @@ - # include - # include - # include --# include -+# include - # include - # include - # include -@@ -66,6 +66,7 @@ - - - using namespace Gui; -+namespace bp = boost::placeholders; - - // #0003564: Python objects: updateData calls to proxy instance that should have been deleted - // See https://forum.freecadweb.org/viewtopic.php?f=22&t=30429&p=252429#p252429 -@@ -210,11 +211,11 @@ void ViewProviderPythonFeatureObserver::slotDeleteObject(const Gui::ViewProvider - ViewProviderPythonFeatureObserver::ViewProviderPythonFeatureObserver() - { - Gui::Application::Instance->signalDeletedObject.connect(boost::bind -- (&ViewProviderPythonFeatureObserver::slotDeleteObject, this, _1)); -+ (&ViewProviderPythonFeatureObserver::slotDeleteObject, this, bp::_1)); - Gui::Application::Instance->signalNewObject.connect(boost::bind -- (&ViewProviderPythonFeatureObserver::slotAppendObject, this, _1)); -+ (&ViewProviderPythonFeatureObserver::slotAppendObject, this, bp::_1)); - Gui::Application::Instance->signalDeleteDocument.connect(boost::bind -- (&ViewProviderPythonFeatureObserver::slotDeleteDocument, this, _1)); -+ (&ViewProviderPythonFeatureObserver::slotDeleteDocument, this, bp::_1)); - } - - ViewProviderPythonFeatureObserver::~ViewProviderPythonFeatureObserver() -diff --git a/src/Gui/ViewProviderTextDocument.cpp b/src/Gui/ViewProviderTextDocument.cpp -index 19133c650..b5db02a6b 100644 ---- a/src/Gui/ViewProviderTextDocument.cpp -+++ b/src/Gui/ViewProviderTextDocument.cpp -@@ -26,7 +26,7 @@ - #ifndef _PreComp_ - # include - # include --# include -+# include - #endif - - #include -diff --git a/src/Mod/Assembly/App/PartRef.cpp b/src/Mod/Assembly/App/PartRef.cpp -index f3cf79600..033c4e9b7 100644 ---- a/src/Mod/Assembly/App/PartRef.cpp -+++ b/src/Mod/Assembly/App/PartRef.cpp -@@ -148,7 +148,7 @@ void PartRef::ensureInitialisation() { - else { - m_part = solver->createPart(ass->m_downstream_placement*Placement.getValue(), Uid.getValueStr()); - } -- m_part->connectSignal(boost::bind(&PartRef::setCalculatedPlacement, this, _1)); -+ m_part->connectSignal(boost::bind(&PartRef::setCalculatedPlacement, this, bp::_1)); - }; - } - -diff --git a/src/Mod/Assembly/App/opendcm/core/imp/clustergraph_imp.hpp b/src/Mod/Assembly/App/opendcm/core/imp/clustergraph_imp.hpp -index 678e14e83..c9cbba253 100644 ---- a/src/Mod/Assembly/App/opendcm/core/imp/clustergraph_imp.hpp -+++ b/src/Mod/Assembly/App/opendcm/core/imp/clustergraph_imp.hpp -@@ -27,7 +27,9 @@ - #include - #include - --#include -+#include -+ -+namespace bp = boost::placeholders; - - namespace dcm { - -@@ -686,7 +688,7 @@ void ClusterGraph::downstreamRemo - re.push_back(* (it.first)); - }; - -- std::for_each(re.begin(), re.end(), boost::bind(&ClusterGraph::simpleRemoveEdge, this, _1)); -+ std::for_each(re.begin(), re.end(), boost::bind(&ClusterGraph::simpleRemoveEdge, this, bp::_1)); - - //if we have the real vertex here and not only a containing cluster we can delete it - if(!isCluster(res.first)) { -@@ -751,7 +753,7 @@ template - void ClusterGraph::removeEdge(LocalEdge id, Functor& f) { - - std::vector& vec = fusion::at_c<1> ((*this) [id]); -- std::for_each(vec.begin(), vec.end(), boost::bind (boost::ref(apply_remove_prediacte (f, -1)), _1)); -+ std::for_each(vec.begin(), vec.end(), boost::bind (boost::ref(apply_remove_prediacte (f, -1)), bp::_1)); - boost::remove_edge(id, *this); - }; - -diff --git a/src/Mod/Assembly/App/opendcm/module3d/imp/module_imp.hpp b/src/Mod/Assembly/App/opendcm/module3d/imp/module_imp.hpp -index 983b3ab09..ac93f0a88 100644 ---- a/src/Mod/Assembly/App/opendcm/module3d/imp/module_imp.hpp -+++ b/src/Mod/Assembly/App/opendcm/module3d/imp/module_imp.hpp -@@ -22,10 +22,11 @@ - - #include "../module.hpp" - --#include -+#include - - #include "constraint3d_imp.hpp" - #include "geometry3d_imp.hpp" -+namespace bp = boost::placeholders; - - namespace dcm { - -@@ -112,7 +113,7 @@ void Module3D::type::inheriter_base::removeGeometry3D(Geom g) - g->template emitSignal(g); - - //remove the vertex from graph and emit all edges that get removed with the functor -- boost::function functor = boost::bind(&inheriter_base::apply_edge_remove, this, _1); -+ boost::function functor = boost::bind(&inheriter_base::apply_edge_remove, this, bp::_1); - m_this->m_cluster->removeVertex(v, functor); - m_this->erase(g); - }; -diff --git a/src/Mod/Assembly/App/opendcm/moduleShape3d/generator.hpp b/src/Mod/Assembly/App/opendcm/moduleShape3d/generator.hpp -index 38eb3b8d3..100bce8f8 100644 ---- a/src/Mod/Assembly/App/opendcm/moduleShape3d/generator.hpp -+++ b/src/Mod/Assembly/App/opendcm/moduleShape3d/generator.hpp -@@ -28,7 +28,8 @@ - #include "defines.hpp" - - #include --#include -+#include -+namespace bp = boost::placeholders; - - namespace dcm { - -@@ -159,7 +160,7 @@ struct segment3D { - base::append(g1); - g1->template linkTo(base::m_shape,0); - g1->template setProperty(line); -- g1->template connectSignal(boost::bind(&base::Shape3D::recalc, base::m_shape, _1)); -+ g1->template connectSignal(boost::bind(&base::Shape3D::recalc, base::m_shape, bp::_1)); - - //we have a segment, lets link the two points to it - boost::shared_ptr g2 = base::m_system->createGeometry3D(); -@@ -205,7 +206,7 @@ struct segment3D { - base::append(g3); - g3->template linkTo(base::m_shape,0); - g3->template setProperty(line); -- g3->template connectSignal(boost::bind(&base::Shape3D::recalc, base::m_shape, _1)); -+ g3->template connectSignal(boost::bind(&base::Shape3D::recalc, base::m_shape, bp::_1)); - - //link the points to our new segment - g1->template linkTo(base::m_shape, 0); -diff --git a/src/Mod/Assembly/App/opendcm/moduleShape3d/module.hpp b/src/Mod/Assembly/App/opendcm/moduleShape3d/module.hpp -index 34a7da953..e42111a7d 100644 ---- a/src/Mod/Assembly/App/opendcm/moduleShape3d/module.hpp -+++ b/src/Mod/Assembly/App/opendcm/moduleShape3d/module.hpp -@@ -572,7 +572,7 @@ boost::shared_ptr - ModuleShape3D::type::Shape3D_base::append(boost::shared_ptr g) { - - g->template setProperty(true); -- Connection c = g->template connectSignal(boost::bind(static_cast)>(&Shape3D_base::remove) , this, _1)); -+ Connection c = g->template connectSignal(boost::bind(static_cast)>(&Shape3D_base::remove) , this, bp::_1)); - m_geometries.push_back(fusion::make_vector(g,c)); - - return ObjBase::shared_from_this(); -@@ -585,7 +585,7 @@ template - boost::shared_ptr - ModuleShape3D::type::Shape3D_base::append(boost::shared_ptr g) { - -- Connection c = g->template connectSignal(boost::bind(static_cast)>(&Shape3D_base::remove) , this, _1)); -+ Connection c = g->template connectSignal(boost::bind(static_cast)>(&Shape3D_base::remove) , this, bp::_1)); - m_shapes.push_back(fusion::make_vector(g,c)); - - return ObjBase::shared_from_this(); -@@ -597,7 +597,7 @@ template - boost::shared_ptr - ModuleShape3D::type::Shape3D_base::append(boost::shared_ptr g) { - -- Connection c = g->template connectSignal(boost::bind(static_cast)>(&Shape3D_base::remove) , this, _1)); -+ Connection c = g->template connectSignal(boost::bind(static_cast)>(&Shape3D_base::remove) , this, bp::_1)); - m_constraints.push_back(fusion::make_vector(g,c)); - - return ObjBase::shared_from_this(); -diff --git a/src/Mod/Assembly/Gui/TaskAssemblyConstraints.cpp b/src/Mod/Assembly/Gui/TaskAssemblyConstraints.cpp -index 1ab6005f6..fdead6c04 100644 ---- a/src/Mod/Assembly/Gui/TaskAssemblyConstraints.cpp -+++ b/src/Mod/Assembly/Gui/TaskAssemblyConstraints.cpp -@@ -42,7 +42,6 @@ - #include - #include - #include --#include - - using namespace AssemblyGui; - using namespace Gui::TaskView; -diff --git a/src/Mod/Assembly/Gui/Workbench.cpp b/src/Mod/Assembly/Gui/Workbench.cpp -index b93dc6f6d..c751ae1eb 100644 ---- a/src/Mod/Assembly/Gui/Workbench.cpp -+++ b/src/Mod/Assembly/Gui/Workbench.cpp -@@ -25,7 +25,7 @@ - - #ifndef _PreComp_ - # include --# include -+# include - - #endif - -@@ -39,7 +39,7 @@ - #include "Workbench.h" - - using namespace AssemblyGui; -- -+namespace bp = boost::placeholders; - - - -@@ -202,10 +202,10 @@ void Workbench::activated() - //} - - // Let us be notified when a document is activated, so that we can update the ActivePartObject -- Gui::Application::Instance->signalActiveDocument.connect(boost::bind(&Workbench::slotActiveDocument, this, _1)); -- App::GetApplication().signalNewDocument.connect(boost::bind(&Workbench::slotNewDocument, this, _1)); -- App::GetApplication().signalFinishRestoreDocument.connect(boost::bind(&Workbench::slotFinishRestoreDocument, this, _1)); -- App::GetApplication().signalDeleteDocument.connect(boost::bind(&Workbench::slotDeleteDocument, this, _1)); -+ Gui::Application::Instance->signalActiveDocument.connect(boost::bind(&Workbench::slotActiveDocument, this, bp::_1)); -+ App::GetApplication().signalNewDocument.connect(boost::bind(&Workbench::slotNewDocument, this, bp::_1)); -+ App::GetApplication().signalFinishRestoreDocument.connect(boost::bind(&Workbench::slotFinishRestoreDocument, this, bp::_1)); -+ App::GetApplication().signalDeleteDocument.connect(boost::bind(&Workbench::slotDeleteDocument, this, bp::_1)); - - - Gui::Control().showModelView(); -@@ -216,10 +216,10 @@ void Workbench::deactivated() - Gui::Command::doCommand(Gui::Command::Doc,"AssemblyGui.setActiveAssembly(None)"); - - // Disconnect all document signals... -- Gui::Application::Instance->signalActiveDocument.disconnect(boost::bind(&Workbench::slotActiveDocument, this, _1)); -- App::GetApplication().signalNewDocument.disconnect(boost::bind(&Workbench::slotNewDocument, this, _1)); -- App::GetApplication().signalFinishRestoreDocument.disconnect(boost::bind(&Workbench::slotFinishRestoreDocument, this, _1)); -- App::GetApplication().signalDeleteDocument.disconnect(boost::bind(&Workbench::slotDeleteDocument, this, _1)); -+ Gui::Application::Instance->signalActiveDocument.disconnect(boost::bind(&Workbench::slotActiveDocument, this, bp::_1)); -+ App::GetApplication().signalNewDocument.disconnect(boost::bind(&Workbench::slotNewDocument, this, bp::_1)); -+ App::GetApplication().signalFinishRestoreDocument.disconnect(boost::bind(&Workbench::slotFinishRestoreDocument, this, bp::_1)); -+ App::GetApplication().signalDeleteDocument.disconnect(boost::bind(&Workbench::slotDeleteDocument, this, bp::_1)); - - Gui::Workbench::deactivated(); - removeTaskWatcher(); -diff --git a/src/Mod/Drawing/Gui/TaskOrthoViews.cpp b/src/Mod/Drawing/Gui/TaskOrthoViews.cpp -index e1c90e27a..bd4289eae 100644 ---- a/src/Mod/Drawing/Gui/TaskOrthoViews.cpp -+++ b/src/Mod/Drawing/Gui/TaskOrthoViews.cpp -@@ -35,12 +35,13 @@ - #include - #include - --#include -+#include - - - using namespace Gui; - using namespace DrawingGui; - using namespace std; -+namespace bp = boost::placeholders; - - - #ifndef PI -@@ -304,9 +305,9 @@ OrthoViews::OrthoViews(App::Document* doc, const char * pagename, const char * p - num_gaps_x = num_gaps_y = 0; - - this->connectDocumentDeletedObject = doc->signalDeletedObject.connect(boost::bind -- (&OrthoViews::slotDeletedObject, this, _1)); -+ (&OrthoViews::slotDeletedObject, this, bp::_1)); - this->connectApplicationDeletedDocument = App::GetApplication().signalDeleteDocument.connect(boost::bind -- (&OrthoViews::slotDeletedDocument, this, _1)); -+ (&OrthoViews::slotDeletedDocument, this, bp::_1)); - } - - OrthoViews::~OrthoViews() -diff --git a/src/Mod/Fem/Gui/PreCompiled.h b/src/Mod/Fem/Gui/PreCompiled.h -index 94309cd4c..a096ff504 100644 ---- a/src/Mod/Fem/Gui/PreCompiled.h -+++ b/src/Mod/Fem/Gui/PreCompiled.h -@@ -64,7 +64,7 @@ - #include - - // boost --#include -+#include - - #ifdef FC_OS_WIN32 - # include -diff --git a/src/Mod/Fem/Gui/ViewProviderAnalysis.cpp b/src/Mod/Fem/Gui/ViewProviderAnalysis.cpp -index f062ad772..d1e9e8335 100644 ---- a/src/Mod/Fem/Gui/ViewProviderAnalysis.cpp -+++ b/src/Mod/Fem/Gui/ViewProviderAnalysis.cpp -@@ -25,7 +25,7 @@ - - #ifndef _PreComp_ - # include --# include -+# include - # include - # include - #endif -diff --git a/src/Mod/Fem/Gui/ViewProviderFemPostFunction.cpp b/src/Mod/Fem/Gui/ViewProviderFemPostFunction.cpp -index 91b615aa4..06b40ee8c 100644 ---- a/src/Mod/Fem/Gui/ViewProviderFemPostFunction.cpp -+++ b/src/Mod/Fem/Gui/ViewProviderFemPostFunction.cpp -@@ -60,19 +60,20 @@ - #include - #include - --#include -+#include - #include - - #include "ui_PlaneWidget.h" - #include "ui_SphereWidget.h" - - using namespace FemGui; -+namespace bp = boost::placeholders; - - void FunctionWidget::setViewProvider(ViewProviderFemPostFunction* view) { - - m_view = view; - m_object = static_cast(view->getObject()); -- m_connection = m_object->getDocument()->signalChangedObject.connect(boost::bind(&FunctionWidget::onObjectsChanged, this, _1, _2)); -+ m_connection = m_object->getDocument()->signalChangedObject.connect(boost::bind(&FunctionWidget::onObjectsChanged, this, bp::_1, bp::_2)); - } - - void FunctionWidget::onObjectsChanged(const App::DocumentObject& obj, const App::Property& p) { -diff --git a/src/Mod/Inspection/App/InspectionFeature.cpp b/src/Mod/Inspection/App/InspectionFeature.cpp -index aac0006ba..0bcf55ae0 100644 ---- a/src/Mod/Inspection/App/InspectionFeature.cpp -+++ b/src/Mod/Inspection/App/InspectionFeature.cpp -@@ -35,7 +35,7 @@ - #include - #include - --#include -+#include - - #include - #include -@@ -58,6 +58,7 @@ - - - using namespace Inspection; -+namespace bp = boost::placeholders; - - InspectActualMesh::InspectActualMesh(const Mesh::MeshObject& rMesh) : _iter(rMesh.getKernel()) - { -@@ -750,7 +751,7 @@ App::DocumentObjectExecReturn* Feature::execute(void) - std::generate(index.begin(), index.end(), Base::iotaGen(0)); - DistanceInspection check(this->SearchRadius.getValue(), actual, inspectNominal); - QFuture future = QtConcurrent::mapped -- (index, boost::bind(&DistanceInspection::mapped, &check, _1)); -+ (index, boost::bind(&DistanceInspection::mapped, &check, bp::_1)); - //future.waitForFinished(); // blocks the GUI - Base::FutureWatcherProgress progress("Inspecting...", actual->countPoints()); - QFutureWatcher watcher; -diff --git a/src/Mod/Mesh/App/Core/Curvature.cpp b/src/Mod/Mesh/App/Core/Curvature.cpp -index a517bd5ed..20d374a86 100644 ---- a/src/Mod/Mesh/App/Core/Curvature.cpp -+++ b/src/Mod/Mesh/App/Core/Curvature.cpp -@@ -28,7 +28,7 @@ - #include - #include - #include --#include -+#include - - //#define OPTIMIZE_CURVATURE - #ifdef OPTIMIZE_CURVATURE -@@ -48,6 +48,7 @@ - #include - - using namespace MeshCore; -+namespace bp = boost::placeholders; - - MeshCurvature::MeshCurvature(const MeshKernel& kernel) - : myKernel(kernel), myMinPoints(20), myRadius(0.5f) -@@ -79,7 +80,7 @@ void MeshCurvature::ComputePerFace(bool parallel) - } - else { - QFuture future = QtConcurrent::mapped -- (mySegment, boost::bind(&FacetCurvature::Compute, &face, _1)); -+ (mySegment, boost::bind(&FacetCurvature::Compute, &face, bp::_1)); - QFutureWatcher watcher; - watcher.setFuture(future); - watcher.waitForFinished(); -diff --git a/src/Mod/Mesh/Gui/DlgEvaluateMeshImp.cpp b/src/Mod/Mesh/Gui/DlgEvaluateMeshImp.cpp -index 79a6e0204..1d1e984d1 100644 ---- a/src/Mod/Mesh/Gui/DlgEvaluateMeshImp.cpp -+++ b/src/Mod/Mesh/Gui/DlgEvaluateMeshImp.cpp -@@ -31,8 +31,6 @@ - #include "ui_DlgEvaluateMesh.h" - #include "DlgEvaluateSettings.h" - --#include -- - #include - #include - #include -diff --git a/src/Mod/Mesh/Gui/MeshEditor.cpp b/src/Mod/Mesh/Gui/MeshEditor.cpp -index 35efd14ed..efe66a503 100644 ---- a/src/Mod/Mesh/Gui/MeshEditor.cpp -+++ b/src/Mod/Mesh/Gui/MeshEditor.cpp -@@ -45,7 +45,7 @@ - # include - # include - # include --# include -+# include - #endif - - #include "MeshEditor.h" -@@ -61,6 +61,7 @@ - #include - - using namespace MeshGui; -+namespace bp = boost::placeholders; - - PROPERTY_SOURCE(MeshGui::ViewProviderFace, Gui::ViewProviderDocumentObject) - -@@ -458,7 +459,7 @@ void MeshFillHole::startEditing(MeshGui::ViewProviderMesh* vp) - viewer->addEventCallback(SoEvent::getClassTypeId(), - MeshFillHole::fileHoleCallback, this); - myConnection = App::GetApplication().signalChangedObject.connect( -- boost::bind(&MeshFillHole::slotChangedObject, this, _1, _2)); -+ boost::bind(&MeshFillHole::slotChangedObject, this, bp::_1, bp::_2)); - - myBoundariesRoot->removeAllChildren(); - myBoundariesRoot->addChild(viewer->getHeadlight()); -diff --git a/src/Mod/Mesh/Gui/ViewProvider.cpp b/src/Mod/Mesh/Gui/ViewProvider.cpp -index d425f1017..ed4fea19d 100644 ---- a/src/Mod/Mesh/Gui/ViewProvider.cpp -+++ b/src/Mod/Mesh/Gui/ViewProvider.cpp -@@ -95,7 +95,7 @@ - #include - #include - #include --#include -+#include - - #include "ViewProvider.h" - #include "SoFCIndexedFaceSet.h" -@@ -103,6 +103,7 @@ - - - using namespace MeshGui; -+namespace bp = boost::placeholders; - - using Mesh::Feature; - using MeshCore::MeshKernel; -@@ -708,7 +709,7 @@ void ViewProviderMesh::setupContextMenu(QMenu* menu, QObject* receiver, const ch - QAction* act = menu->addAction(QObject::tr("Display components")); - act->setCheckable(true); - act->setChecked(pcMatBinding->value.getValue() == SoMaterialBinding::PER_FACE); -- func->toggle(act, boost::bind(&ViewProviderMesh::setHighlightedComponents, this, _1)); -+ func->toggle(act, boost::bind(&ViewProviderMesh::setHighlightedComponents, this, bp::_1)); - } - - bool ViewProviderMesh::setEdit(int ModNum) -diff --git a/src/Mod/Part/App/PreCompiled.h b/src/Mod/Part/App/PreCompiled.h -index 9d21862fa..b0d06f58a 100644 ---- a/src/Mod/Part/App/PreCompiled.h -+++ b/src/Mod/Part/App/PreCompiled.h -@@ -64,7 +64,7 @@ - - // Boost - #include --#include -+#include - - #include - #include -diff --git a/src/Mod/Part/Gui/CrossSections.cpp b/src/Mod/Part/Gui/CrossSections.cpp -index b28d86995..b4fff085f 100644 ---- a/src/Mod/Part/Gui/CrossSections.cpp -+++ b/src/Mod/Part/Gui/CrossSections.cpp -@@ -36,7 +36,7 @@ - # include - # include - # include --# include -+# include - # include - # include - # include -@@ -61,6 +61,7 @@ - #include - - using namespace PartGui; -+namespace bp = boost::placeholders; - #undef CS_FUTURE // multi-threading causes some problems - - namespace PartGui { -@@ -218,7 +219,7 @@ void CrossSections::apply() - for (std::vector::iterator it = obj.begin(); it != obj.end(); ++it) { - Part::CrossSection cs(a,b,c,static_cast(*it)->Shape.getValue()); - QFuture< std::list > future = QtConcurrent::mapped -- (d, boost::bind(&Part::CrossSection::section, &cs, _1)); -+ (d, boost::bind(&Part::CrossSection::section, &cs, bp::_1)); - future.waitForFinished(); - QFuture< std::list >::const_iterator ft; - TopoDS_Compound comp; -diff --git a/src/Mod/Part/Gui/DlgBooleanOperation.cpp b/src/Mod/Part/Gui/DlgBooleanOperation.cpp -index 9df2d3899..edd3cd06b 100644 ---- a/src/Mod/Part/Gui/DlgBooleanOperation.cpp -+++ b/src/Mod/Part/Gui/DlgBooleanOperation.cpp -@@ -27,7 +27,7 @@ - # include - # include - # include --# include -+# include - #endif - - #include "DlgBooleanOperation.h" -@@ -47,6 +47,7 @@ - #include - - using namespace PartGui; -+namespace bp = boost::placeholders; - - namespace PartGui { - class BooleanOperationItem : public QTreeWidgetItem -@@ -89,9 +90,9 @@ DlgBooleanOperation::DlgBooleanOperation(QWidget* parent) - connect(ui->secondShape, SIGNAL(currentItemChanged(QTreeWidgetItem*, QTreeWidgetItem*)), - this, SLOT(currentItemChanged(QTreeWidgetItem*, QTreeWidgetItem*))); - this->connectNewObject = App::GetApplication().signalNewObject.connect(boost::bind -- (&DlgBooleanOperation::slotCreatedObject, this, _1)); -+ (&DlgBooleanOperation::slotCreatedObject, this, bp::_1)); - this->connectModObject = App::GetApplication().signalChangedObject.connect(boost::bind -- (&DlgBooleanOperation::slotChangedObject, this, _1, _2)); -+ (&DlgBooleanOperation::slotChangedObject, this, bp::_1, bp::_2)); - findShapes(); - } - -diff --git a/src/Mod/Part/Gui/DlgFilletEdges.cpp b/src/Mod/Part/Gui/DlgFilletEdges.cpp -index 138ccd386..5085446d0 100644 ---- a/src/Mod/Part/Gui/DlgFilletEdges.cpp -+++ b/src/Mod/Part/Gui/DlgFilletEdges.cpp -@@ -43,7 +43,7 @@ - # include - # include - # include --# include -+# include - # include - # include - # include -@@ -75,6 +75,7 @@ - #include - - using namespace PartGui; -+namespace bp = boost::placeholders; - - FilletRadiusDelegate::FilletRadiusDelegate(QObject *parent) : QItemDelegate(parent) - { -@@ -245,9 +246,9 @@ DlgFilletEdges::DlgFilletEdges(FilletType type, Part::FilletBase* fillet, QWidge - - d->fillet = fillet; - d->connectApplicationDeletedObject = App::GetApplication().signalDeletedObject -- .connect(boost::bind(&DlgFilletEdges::onDeleteObject, this, _1)); -+ .connect(boost::bind(&DlgFilletEdges::onDeleteObject, this, bp::_1)); - d->connectApplicationDeletedDocument = App::GetApplication().signalDeleteDocument -- .connect(boost::bind(&DlgFilletEdges::onDeleteDocument, this, _1)); -+ .connect(boost::bind(&DlgFilletEdges::onDeleteDocument, this, bp::_1)); - // set tree view with three columns - QStandardItemModel* model = new FilletRadiusModel(this); - connect(model, SIGNAL(toggleCheckState(const QModelIndex&)), -diff --git a/src/Mod/Part/Gui/Mirroring.cpp b/src/Mod/Part/Gui/Mirroring.cpp -index 535507cbf..94beb847b 100644 ---- a/src/Mod/Part/Gui/Mirroring.cpp -+++ b/src/Mod/Part/Gui/Mirroring.cpp -@@ -28,7 +28,6 @@ - # include - # include - # include --# include - # include - # include - # include -diff --git a/src/Mod/Part/Gui/TaskAttacher.cpp b/src/Mod/Part/Gui/TaskAttacher.cpp -index e2bfe4415..c1a1799c4 100644 ---- a/src/Mod/Part/Gui/TaskAttacher.cpp -+++ b/src/Mod/Part/Gui/TaskAttacher.cpp -@@ -30,7 +30,7 @@ - # include - # include - # include --# include -+# include - #endif - - #include -@@ -61,6 +61,7 @@ - using namespace PartGui; - using namespace Gui; - using namespace Attacher; -+namespace bp = boost::placeholders; - - /* TRANSLATOR PartDesignGui::TaskAttacher */ - -@@ -208,8 +209,8 @@ TaskAttacher::TaskAttacher(Gui::ViewProviderDocumentObject *ViewProvider,QWidget - updatePreview(); - - // connect object deletion with slot -- auto bnd1 = boost::bind(&TaskAttacher::objectDeleted, this, _1); -- auto bnd2 = boost::bind(&TaskAttacher::documentDeleted, this, _1); -+ auto bnd1 = boost::bind(&TaskAttacher::objectDeleted, this, bp::_1); -+ auto bnd2 = boost::bind(&TaskAttacher::documentDeleted, this, bp::_1); - Gui::Document* document = Gui::Application::Instance->getDocument(ViewProvider->getObject()->getDocument()); - connectDelObject = document->signalDeletedObject.connect(bnd1); - connectDelDocument = document->signalDeleteDocument.connect(bnd2); -diff --git a/src/Mod/Part/Gui/TaskFaceColors.cpp b/src/Mod/Part/Gui/TaskFaceColors.cpp -index 23f5e162b..677c66807 100644 ---- a/src/Mod/Part/Gui/TaskFaceColors.cpp -+++ b/src/Mod/Part/Gui/TaskFaceColors.cpp -@@ -43,11 +43,10 @@ - # include - # include - # include -+# include -+# include - #endif - --#include --#include -- - #include "ui_TaskFaceColors.h" - #include "TaskFaceColors.h" - #include "ViewProviderExt.h" -@@ -69,6 +68,7 @@ - - - using namespace PartGui; -+namespace bp = boost::placeholders; - - namespace PartGui { - class FaceSelection : public Gui::SelectionFilterGate -@@ -274,9 +274,9 @@ FaceColors::FaceColors(ViewProviderPartExt* vp, QWidget* parent) - Gui::Selection().addSelectionGate(gate); - - d->connectDelDoc = Gui::Application::Instance->signalDeleteDocument.connect(boost::bind -- (&FaceColors::slotDeleteDocument, this, _1)); -+ (&FaceColors::slotDeleteDocument, this, bp::_1)); - d->connectDelObj = Gui::Application::Instance->signalDeletedObject.connect(boost::bind -- (&FaceColors::slotDeleteObject, this, _1)); -+ (&FaceColors::slotDeleteObject, this, bp::_1)); - } - - FaceColors::~FaceColors() -diff --git a/src/Mod/Part/Gui/ViewProviderSpline.cpp b/src/Mod/Part/Gui/ViewProviderSpline.cpp -index b83aaf8b8..c0fcd09d8 100644 ---- a/src/Mod/Part/Gui/ViewProviderSpline.cpp -+++ b/src/Mod/Part/Gui/ViewProviderSpline.cpp -@@ -45,10 +45,9 @@ - # include - # include - # include -+# include - #endif - --#include -- - - #include - #include -@@ -58,6 +57,7 @@ - - - using namespace PartGui; -+namespace bp = boost::placeholders; - - - PROPERTY_SOURCE(PartGui::ViewProviderSpline, PartGui::ViewProviderPartExt) -@@ -81,7 +81,7 @@ void ViewProviderSpline::setupContextMenu(QMenu* menu, QObject* receiver, const - QAction* act = menu->addAction(QObject::tr("Show control points")); - act->setCheckable(true); - act->setChecked(ControlPoints.getValue()); -- func->toggle(act, boost::bind(&ViewProviderSpline::toggleControlPoints, this, _1)); -+ func->toggle(act, boost::bind(&ViewProviderSpline::toggleControlPoints, this, bp::_1)); - } - - void ViewProviderSpline::toggleControlPoints(bool on) -diff --git a/src/Mod/PartDesign/App/Body.cpp b/src/Mod/PartDesign/App/Body.cpp -index 849ccd381..d5f021acd 100644 ---- a/src/Mod/PartDesign/App/Body.cpp -+++ b/src/Mod/PartDesign/App/Body.cpp -@@ -24,7 +24,6 @@ - #include "PreCompiled.h" - - #ifndef _PreComp_ --#include - #endif - - #include -diff --git a/src/Mod/PartDesign/App/ShapeBinder.cpp b/src/Mod/PartDesign/App/ShapeBinder.cpp -index a5fb4482f..ac1bf017c 100644 ---- a/src/Mod/PartDesign/App/ShapeBinder.cpp -+++ b/src/Mod/PartDesign/App/ShapeBinder.cpp -@@ -24,7 +24,7 @@ - #include "PreCompiled.h" - #ifndef _PreComp_ - #include --#include -+#include - #include - #include - #endif -@@ -39,6 +39,7 @@ - #endif - - using namespace PartDesign; -+namespace bp = boost::placeholders; - - // ============================================================================ - -@@ -183,7 +184,7 @@ void ShapeBinder::onSettingDocument() - App::Document* document = getDocument(); - if (document) { - this->connectDocumentChangedObject = document->signalChangedObject.connect(boost::bind -- (&ShapeBinder::slotChangedObject, this, _1, _2)); -+ (&ShapeBinder::slotChangedObject, this, bp::_1, bp::_2)); - } - } - -diff --git a/src/Mod/PartDesign/Gui/PreCompiled.h b/src/Mod/PartDesign/Gui/PreCompiled.h -index 4fd34892a..ebc357bc7 100644 ---- a/src/Mod/PartDesign/Gui/PreCompiled.h -+++ b/src/Mod/PartDesign/Gui/PreCompiled.h -@@ -1,91 +1,91 @@ --/*************************************************************************** -- * Copyright (c) 2008 Jürgen Riegel (juergen.riegel@web.de) * -- * * -- * This file is part of the FreeCAD CAx development system. * -- * * -- * This library is free software; you can redistribute it and/or * -- * modify it under the terms of the GNU Library General Public * -- * License as published by the Free Software Foundation; either * -- * version 2 of the License, or (at your option) any later version. * -- * * -- * This library is distributed in the hope that it will be useful, * -- * but WITHOUT ANY WARRANTY; without even the implied warranty of * -- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * -- * GNU Library General Public License for more details. * -- * * -- * You should have received a copy of the GNU Library General Public * -- * License along with this library; see the file COPYING.LIB. If not, * -- * write to the Free Software Foundation, Inc., 59 Temple Place, * -- * Suite 330, Boston, MA 02111-1307, USA * -- * * -- ***************************************************************************/ -- -- --#ifndef __PRECOMPILED_GUI__ --#define __PRECOMPILED_GUI__ -- --#include -- --// Importing of App classes --#ifdef FC_OS_WIN32 --# define PartDesignExport __declspec(dllimport) --# define PartDesignGuiExport __declspec(dllexport) --# define PartExport __declspec(dllimport) --# define PartGuiExport __declspec(dllimport) --# define SketcherExport __declspec(dllimport) --# define SketcherGuiExport __declspec(dllimport) --#else // for Linux --# define PartDesignExport --# define PartDesignGuiExport --# define PartExport --# define PartGuiExport --# define SketcherExport --# define SketcherGuiExport --#endif -- -- --#ifdef _MSC_VER --# pragma warning(disable : 4005) --#endif -- --#ifdef _PreComp_ -+/*************************************************************************** -+ * Copyright (c) 2008 Jürgen Riegel (juergen.riegel@web.de) * -+ * * -+ * This file is part of the FreeCAD CAx development system. * -+ * * -+ * This library is free software; you can redistribute it and/or * -+ * modify it under the terms of the GNU Library General Public * -+ * License as published by the Free Software Foundation; either * -+ * version 2 of the License, or (at your option) any later version. * -+ * * -+ * This library is distributed in the hope that it will be useful, * -+ * but WITHOUT ANY WARRANTY; without even the implied warranty of * -+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * -+ * GNU Library General Public License for more details. * -+ * * -+ * You should have received a copy of the GNU Library General Public * -+ * License along with this library; see the file COPYING.LIB. If not, * -+ * write to the Free Software Foundation, Inc., 59 Temple Place, * -+ * Suite 330, Boston, MA 02111-1307, USA * -+ * * -+ ***************************************************************************/ -+ -+ -+#ifndef __PRECOMPILED_GUI__ -+#define __PRECOMPILED_GUI__ -+ -+#include -+ -+// Importing of App classes -+#ifdef FC_OS_WIN32 -+# define PartDesignExport __declspec(dllimport) -+# define PartDesignGuiExport __declspec(dllexport) -+# define PartExport __declspec(dllimport) -+# define PartGuiExport __declspec(dllimport) -+# define SketcherExport __declspec(dllimport) -+# define SketcherGuiExport __declspec(dllimport) -+#else // for Linux -+# define PartDesignExport -+# define PartDesignGuiExport -+# define PartExport -+# define PartGuiExport -+# define SketcherExport -+# define SketcherGuiExport -+#endif -+ -+ -+#ifdef _MSC_VER -+# pragma warning(disable : 4005) -+#endif -+ -+#ifdef _PreComp_ - - // Python --#include -- --// standard --#include --#include --#include -- --// OCC --#include -- --// STL --#include --#include --#include --#include --#include --#include --#include --#include --#include -- --#ifdef FC_OS_WIN32 --# include --#endif -- -- --// Qt Toolkit --#ifndef __Qt4All__ --# include --#endif -- --// Inventor --#ifndef __InventorAll__ --# include --#endif -- --#endif // _PreComp_ --#endif // __PRECOMPILED_GUI__ -+#include -+ -+// standard -+#include -+#include -+#include -+ -+// OCC -+#include -+ -+// STL -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+ -+#ifdef FC_OS_WIN32 -+# include -+#endif -+ -+ -+// Qt Toolkit -+#ifndef __Qt4All__ -+# include -+#endif -+ -+// Inventor -+#ifndef __InventorAll__ -+# include -+#endif -+ -+#endif // _PreComp_ -+#endif // __PRECOMPILED_GUI__ -diff --git a/src/Mod/PartDesign/Gui/TaskDatumParameters.cpp b/src/Mod/PartDesign/Gui/TaskDatumParameters.cpp -index 7d7d5e46d..bd41f8f93 100644 ---- a/src/Mod/PartDesign/Gui/TaskDatumParameters.cpp -+++ b/src/Mod/PartDesign/Gui/TaskDatumParameters.cpp -@@ -30,7 +30,6 @@ - # include - # include - # include --# include - #endif - - #include -diff --git a/src/Mod/PartDesign/Gui/TaskHoleParameters.cpp b/src/Mod/PartDesign/Gui/TaskHoleParameters.cpp -index 61b67f6b7..87069dd0b 100644 ---- a/src/Mod/PartDesign/Gui/TaskHoleParameters.cpp -+++ b/src/Mod/PartDesign/Gui/TaskHoleParameters.cpp -@@ -24,6 +24,7 @@ - #include "PreCompiled.h" - - #ifndef _PreComp_ -+# include - #endif - - #include "ui_TaskHoleParameters.h" -@@ -41,6 +42,7 @@ - - using namespace PartDesignGui; - using namespace Gui; -+namespace bp = boost::placeholders; - - /* TRANSLATOR PartDesignGui::TaskHoleParameters */ - -@@ -115,7 +117,7 @@ TaskHoleParameters::TaskHoleParameters(ViewProviderHole *HoleView, QWidget *pare - ui->DrillPointAngle->bind(pcHole->DrillPointAngle); - ui->TaperedAngle->bind(pcHole->TaperedAngle); - -- connectPropChanged = App::GetApplication().signalChangePropertyEditor.connect(boost::bind(&TaskHoleParameters::changedObject, this, _1)); -+ connectPropChanged = App::GetApplication().signalChangePropertyEditor.connect(boost::bind(&TaskHoleParameters::changedObject, this, bp::_1)); - - this->groupLayout()->addWidget(proxy); - } -diff --git a/src/Mod/PartDesign/Gui/TaskHoleParameters.h b/src/Mod/PartDesign/Gui/TaskHoleParameters.h -index 7a00c9fd6..d3d2e166a 100644 ---- a/src/Mod/PartDesign/Gui/TaskHoleParameters.h -+++ b/src/Mod/PartDesign/Gui/TaskHoleParameters.h -@@ -28,7 +28,7 @@ - #include - #include - #include --#include -+#include - - #include "TaskSketchBasedParameters.h" - #include "ViewProviderHole.h" -diff --git a/src/Mod/PartDesign/Gui/TaskPrimitiveParameters.cpp b/src/Mod/PartDesign/Gui/TaskPrimitiveParameters.cpp -index 083c910b5..c482636b0 100644 ---- a/src/Mod/PartDesign/Gui/TaskPrimitiveParameters.cpp -+++ b/src/Mod/PartDesign/Gui/TaskPrimitiveParameters.cpp -@@ -47,7 +47,6 @@ - #include - #include - #include --#include - - using namespace PartDesignGui; - -diff --git a/src/Mod/PartDesign/Gui/TaskTransformedMessages.cpp b/src/Mod/PartDesign/Gui/TaskTransformedMessages.cpp -index 91b84e538..836dd5ca5 100644 ---- a/src/Mod/PartDesign/Gui/TaskTransformedMessages.cpp -+++ b/src/Mod/PartDesign/Gui/TaskTransformedMessages.cpp -@@ -24,6 +24,7 @@ - #include "PreCompiled.h" - - #ifndef _PreComp_ -+# include - #endif - - #include "ui_TaskTransformedMessages.h" -@@ -32,12 +33,11 @@ - #include - #include - --#include -- - #include "ViewProviderTransformed.h" - - using namespace PartDesignGui; - using namespace Gui::TaskView; -+namespace bp = boost::placeholders; - - TaskTransformedMessages::TaskTransformedMessages(ViewProviderTransformed *transformedView_) - : TaskBox(Gui::BitmapFactory().pixmap("document-new"),tr("Transformed feature messages"),true, 0), -@@ -54,7 +54,7 @@ TaskTransformedMessages::TaskTransformedMessages(ViewProviderTransformed *transf - - this->groupLayout()->addWidget(proxy); - -- connectionDiagnosis = transformedView->signalDiagnosis.connect(boost::bind(&PartDesignGui::TaskTransformedMessages::slotDiagnosis, this,_1)); -+ connectionDiagnosis = transformedView->signalDiagnosis.connect(boost::bind(&PartDesignGui::TaskTransformedMessages::slotDiagnosis, this, bp::_1)); - } - - TaskTransformedMessages::~TaskTransformedMessages() -diff --git a/src/Mod/PartDesign/Gui/ViewProviderBody.cpp b/src/Mod/PartDesign/Gui/ViewProviderBody.cpp -index 54923f62d..841ee7639 100644 ---- a/src/Mod/PartDesign/Gui/ViewProviderBody.cpp -+++ b/src/Mod/PartDesign/Gui/ViewProviderBody.cpp -@@ -24,7 +24,7 @@ - #include "PreCompiled.h" - - #ifndef _PreComp_ --# include -+# include - # include - # include - # include -@@ -60,6 +60,7 @@ - #include - - using namespace PartDesignGui; -+namespace bp = boost::placeholders; - - const char* PartDesignGui::ViewProviderBody::BodyModeEnum[] = {"Through","Tip",NULL}; - -@@ -96,10 +97,10 @@ void ViewProviderBody::attach(App::DocumentObject *pcFeat) - assert ( gdoc ); - - connectChangedObjectApp = adoc->signalChangedObject.connect ( -- boost::bind ( &ViewProviderBody::slotChangedObjectApp, this, _1, _2) ); -+ boost::bind ( &ViewProviderBody::slotChangedObjectApp, this, bp::_1, bp::_2) ); - - connectChangedObjectGui = gdoc->signalChangedObject.connect ( -- boost::bind ( &ViewProviderBody::slotChangedObjectGui, this, _1, _2) ); -+ boost::bind ( &ViewProviderBody::slotChangedObjectGui, this, bp::_1, bp::_2) ); - } - - // TODO on activating the body switch to the "Through" mode (2015-09-05, Fat-Zer) -diff --git a/src/Mod/PartDesign/Gui/Workbench.cpp b/src/Mod/PartDesign/Gui/Workbench.cpp -index 1d606ebc5..472f8141c 100644 ---- a/src/Mod/PartDesign/Gui/Workbench.cpp -+++ b/src/Mod/PartDesign/Gui/Workbench.cpp -@@ -24,7 +24,7 @@ - #include "PreCompiled.h" - - #ifndef _PreComp_ --# include -+# include - # include - #endif - -@@ -46,6 +46,7 @@ - #include "WorkflowManager.h" - - using namespace PartDesignGui; -+namespace bp = boost::placeholders; - - #if 0 // needed for Qt's lupdate utility - qApp->translate("Workbench", "Part Design"); -@@ -427,22 +428,22 @@ void Workbench::activated() - Gui::Control().showTaskView(); - - // Let us be notified when a document is activated, so that we can update the ActivePartObject -- Gui::Application::Instance->signalActiveDocument.connect(boost::bind(&Workbench::slotActiveDocument, this, _1)); -- App::GetApplication().signalNewDocument.connect(boost::bind(&Workbench::slotNewDocument, this, _1)); -- App::GetApplication().signalFinishRestoreDocument.connect(boost::bind(&Workbench::slotFinishRestoreDocument, this, _1)); -- App::GetApplication().signalDeleteDocument.connect(boost::bind(&Workbench::slotDeleteDocument, this, _1)); -+ Gui::Application::Instance->signalActiveDocument.connect(boost::bind(&Workbench::slotActiveDocument, this, bp::_1)); -+ App::GetApplication().signalNewDocument.connect(boost::bind(&Workbench::slotNewDocument, this, bp::_1)); -+ App::GetApplication().signalFinishRestoreDocument.connect(boost::bind(&Workbench::slotFinishRestoreDocument, this, bp::_1)); -+ App::GetApplication().signalDeleteDocument.connect(boost::bind(&Workbench::slotDeleteDocument, this, bp::_1)); - // Watch out for objects being added to the active document, so that we can add them to the body -- //App::GetApplication().signalNewObject.connect(boost::bind(&Workbench::slotNewObject, this, _1)); -+ //App::GetApplication().signalNewObject.connect(boost::bind(&Workbench::slotNewObject, this, bp::_1)); - } - - void Workbench::deactivated() - { - // Let us be notified when a document is activated, so that we can update the ActivePartObject -- Gui::Application::Instance->signalActiveDocument.disconnect(boost::bind(&Workbench::slotActiveDocument, this, _1)); -- App::GetApplication().signalNewDocument.disconnect(boost::bind(&Workbench::slotNewDocument, this, _1)); -- App::GetApplication().signalFinishRestoreDocument.disconnect(boost::bind(&Workbench::slotFinishRestoreDocument, this, _1)); -- App::GetApplication().signalDeleteDocument.disconnect(boost::bind(&Workbench::slotDeleteDocument, this, _1)); -- //App::GetApplication().signalNewObject.disconnect(boost::bind(&Workbench::slotNewObject, this, _1)); -+ Gui::Application::Instance->signalActiveDocument.disconnect(boost::bind(&Workbench::slotActiveDocument, this, bp::_1)); -+ App::GetApplication().signalNewDocument.disconnect(boost::bind(&Workbench::slotNewDocument, this, bp::_1)); -+ App::GetApplication().signalFinishRestoreDocument.disconnect(boost::bind(&Workbench::slotFinishRestoreDocument, this, bp::_1)); -+ App::GetApplication().signalDeleteDocument.disconnect(boost::bind(&Workbench::slotDeleteDocument, this, bp::_1)); -+ //App::GetApplication().signalNewObject.disconnect(boost::bind(&Workbench::slotNewObject, this, bp::_1)); - - removeTaskWatcher(); - // reset the active Body -diff --git a/src/Mod/PartDesign/Gui/WorkflowManager.cpp b/src/Mod/PartDesign/Gui/WorkflowManager.cpp -index fadd74f8e..279c8783f 100644 ---- a/src/Mod/PartDesign/Gui/WorkflowManager.cpp -+++ b/src/Mod/PartDesign/Gui/WorkflowManager.cpp -@@ -26,7 +26,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #endif -@@ -43,6 +43,7 @@ - - - using namespace PartDesignGui; -+namespace bp = boost::placeholders; - - - WorkflowManager * WorkflowManager::_instance = nullptr; -@@ -55,11 +56,11 @@ WorkflowManager::WorkflowManager() { - } - - connectNewDocument = App::GetApplication().signalNewDocument.connect( -- boost::bind( &WorkflowManager::slotNewDocument, this, _1 ) ); -+ boost::bind( &WorkflowManager::slotNewDocument, this, bp::_1 ) ); - connectFinishRestoreDocument = App::GetApplication().signalFinishRestoreDocument.connect( -- boost::bind( &WorkflowManager::slotFinishRestoreDocument, this, _1 ) ); -+ boost::bind( &WorkflowManager::slotFinishRestoreDocument, this, bp::_1 ) ); - connectDeleteDocument = App::GetApplication().signalDeleteDocument.connect( -- boost::bind( &WorkflowManager::slotDeleteDocument, this, _1 ) ); -+ boost::bind( &WorkflowManager::slotDeleteDocument, this, bp::_1 ) ); - } - - WorkflowManager::~WorkflowManager() { -diff --git a/src/Mod/Path/App/Area.cpp b/src/Mod/Path/App/Area.cpp -index 154085c89..68de68405 100644 ---- a/src/Mod/Path/App/Area.cpp -+++ b/src/Mod/Path/App/Area.cpp -@@ -21,6 +21,9 @@ - ****************************************************************************/ - #include "PreCompiled.h" - -+// From Boost 1.75 on the geometry component requires C++14 -+#define BOOST_GEOMETRY_DISABLE_DEPRECATED_03_WARNING -+ - #ifndef _PreComp_ - # include - #endif -diff --git a/src/Mod/Path/libarea/PythonStuff.cpp b/src/Mod/Path/libarea/PythonStuff.cpp -index ce6811bd2..ad1518fc9 100644 ---- a/src/Mod/Path/libarea/PythonStuff.cpp -+++ b/src/Mod/Path/libarea/PythonStuff.cpp -@@ -1,540 +1,542 @@ --// PythonStuff.cpp --// Copyright 2011, Dan Heeks --// This program is released under the BSD license. See the file COPYING for details. -- --#include "PythonStuff.h" -- --#include "Area.h" --#include "Point.h" --#include "AreaDxf.h" --#include "kurve/geometry.h" --#include "Adaptive.hpp" -- --#if defined (_POSIX_C_SOURCE) --# undef _POSIX_C_SOURCE --#endif -- --#if defined (_XOPEN_SOURCE) --# undef _XOPEN_SOURCE --#endif -- --#if _DEBUG --#undef _DEBUG --#include --#define _DEBUG --#else --#include --#endif -- --#if defined(__GNUG__) && !defined(__clang__) --#pragma implementation --#endif -- --#include --#include --#include --#include --#include --#include --#include --#include -- -- --#include "clipper.hpp" --using namespace ClipperLib; -- -- --namespace bp = boost::python; -- --boost::python::list getVertices(const CCurve& curve) { -- boost::python::list vlist; -- BOOST_FOREACH(const CVertex& vertex, curve.m_vertices) { -- vlist.append(vertex); -- } -- return vlist; --} -- --boost::python::list getCurves(const CArea& area) { -- boost::python::list clist; -- BOOST_FOREACH(const CCurve& curve, area.m_curves) { -- clist.append(curve); -- } -- return clist; --} -- --boost::python::tuple transformed_point(const geoff_geometry::Matrix &matrix, double x, double y, double z) --{ -- geoff_geometry::Point3d p(x,y,z); -- p = p.Transform(matrix); -- -- return bp::make_tuple(p.x,p.y,p.z); --} -- --static void print_curve(const CCurve& c) --{ -- std::size_t nvertices = c.m_vertices.size(); --#if defined SIZEOF_SIZE_T && SIZEOF_SIZE_T == 4 -- printf("number of vertices = %d\n", nvertices); --#else -- printf("number of vertices = %lu\n", nvertices); --#endif -- int i = 0; -- for(std::list::const_iterator It = c.m_vertices.begin(); It != c.m_vertices.end(); It++, i++) -- { -- const CVertex& vertex = *It; -- printf("vertex %d type = %d, x = %g, y = %g", i+1, vertex.m_type, vertex.m_p.x / CArea::get_units(), vertex.m_p.y / CArea::get_units()); -- if(vertex.m_type)printf(", xc = %g, yc = %g", vertex.m_c.x / CArea::get_units(), vertex.m_c.y / CArea::get_units()); -- printf("\n"); -- } --} -- --static void print_area(const CArea &a) --{ -- for(std::list::const_iterator It = a.m_curves.begin(); It != a.m_curves.end(); It++) -- { -- const CCurve& curve = *It; -- print_curve(curve); -- } --} -- --static unsigned int num_vertices(const CCurve& curve) --{ -- return static_cast(curve.m_vertices.size()); --} -- --static CVertex FirstVertex(const CCurve& curve) --{ -- return curve.m_vertices.front(); --} -- --static CVertex LastVertex(const CCurve& curve) --{ -- return curve.m_vertices.back(); --} -- --static void set_units(double units) --{ -- CArea::set_units(units); --} -- --static double get_units() --{ -- return CArea::get_units(); --} -- --static bool holes_linked() --{ -- return CArea::HolesLinked(); --} -- --static CArea AreaFromDxf(const char* filepath) --{ -- CArea area; -- AreaDxfRead dxf(&area, filepath); -- dxf.DoRead(); -- return area; --} -- --static void append_point(CCurve& c, const Point& p) --{ -- c.m_vertices.push_back(CVertex(p)); --} -- --static boost::python::tuple nearest_point_to_curve(CCurve& c1, const CCurve& c2) --{ -- double dist; -- Point p = c1.NearestPoint(c2, &dist); -- -- return bp::make_tuple(p, dist); --} -- --boost::python::list MakePocketToolpath(const CArea& a, double tool_radius, double extra_offset, double stepover, bool from_center, bool use_zig_zag, double zig_angle) --{ -- std::list toolpath; -- -- CAreaPocketParams params(tool_radius, extra_offset, stepover, from_center, use_zig_zag ? ZigZagPocketMode : SpiralPocketMode, zig_angle); -- a.SplitAndMakePocketToolpath(toolpath, params); -- -- boost::python::list clist; -- BOOST_FOREACH(const CCurve& c, toolpath) { -- clist.append(c); -- } -- return clist; --} -- --boost::python::list SplitArea(const CArea& a) --{ -- std::list areas; -- a.Split(areas); -- -- boost::python::list alist; -- BOOST_FOREACH(const CArea& a, areas) { -- alist.append(a); -- } -- return alist; --} -- --void dxfArea(CArea& area, const char* /*str*/) --{ -- area = CArea(); --} -- --boost::python::list getCurveSpans(const CCurve& c) --{ -- boost::python::list span_list; -- const Point *prev_p = NULL; -- -- for(std::list::const_iterator VIt = c.m_vertices.begin(); VIt != c.m_vertices.end(); VIt++) -- { -- const CVertex& vertex = *VIt; -- -- if(prev_p) -- { -- span_list.append(Span(*prev_p, vertex)); -- } -- prev_p = &(vertex.m_p); -- } -- -- return span_list; --} -- --Span getFirstCurveSpan(const CCurve& c) --{ -- if(c.m_vertices.size() < 2)return Span(); -- -- std::list::const_iterator VIt = c.m_vertices.begin(); -- const Point &p = (*VIt).m_p; -- VIt++; -- return Span(p, *VIt, true); --} -- --Span getLastCurveSpan(const CCurve& c) --{ -- if(c.m_vertices.size() < 2)return Span(); -- -- std::list::const_reverse_iterator VIt = c.m_vertices.rbegin(); -- const CVertex &v = (*VIt); -- VIt++; -- -- return Span((*VIt).m_p, v, c.m_vertices.size() == 2); --} -- --bp::tuple TangentialArc(const Point &p0, const Point &p1, const Point &v0) --{ -- Point c; -- int dir; -- tangential_arc(p0, p1, v0, c, dir); -- -- return bp::make_tuple(c, dir); --} -- --boost::python::list spanIntersect(const Span& span1, const Span& span2) { -- boost::python::list plist; -- std::list pts; -- span1.Intersect(span2, pts); -- BOOST_FOREACH(const Point& p, pts) { -- plist.append(p); -- } -- return plist; --} -- --//Matrix(boost::python::list &l){} --boost::shared_ptr matrix_constructor(const boost::python::list& lst) { -- double m[16] = {1,0,0,0,0,1,0,0, 0,0,1,0, 0,0,0,1}; -- -- boost::python::ssize_t n = boost::python::len(lst); -- int j = 0; -- for(boost::python::ssize_t i=0;i(elem.attr("__float__")()); -- j++; -- if(j>=16)break; -- } -- -- return boost::shared_ptr( new geoff_geometry::Matrix(m) ); --} -- --boost::python::list InsideCurves(const CArea& a, const CCurve& curve) { -- boost::python::list plist; -- -- std::list curves_inside; -- a.InsideCurves(curve, curves_inside); -- BOOST_FOREACH(const CCurve& c, curves_inside) { -- plist.append(c); -- } -- return plist; --} -- --boost::python::list CurveIntersections(const CCurve& c1, const CCurve& c2) { -- boost::python::list plist; -- -- std::list pts; -- c1.CurveIntersections(c2, pts); -- BOOST_FOREACH(const Point& p, pts) { -- plist.append(p); -- } -- return plist; --} -- --boost::python::list AreaIntersections(const CArea& a, const CCurve& c2) { -- boost::python::list plist; -- -- std::list pts; -- a.CurveIntersections(c2, pts); -- BOOST_FOREACH(const Point& p, pts) { -- plist.append(p); -- } -- return plist; --} -- --double AreaGetArea(const CArea& a) --{ -- return a.GetArea(); --} -- -- -- --// Adaptive2d.Execute wrapper --bp::list AdaptiveExecute(AdaptivePath::Adaptive2d& ada,const boost::python::list &stock_paths, const boost::python::list &in_paths, boost::python::object progressCallbackFn) { -- bp::list out_list; -- -- // convert stock paths -- AdaptivePath::DPaths stock_dpaths; -- for(bp::ssize_t i=0;i(stock_paths[i]); -- AdaptivePath::DPath dpath; -- for(bp::ssize_t j=0;j(in_path[j]); -- dpath.push_back(pair(bp::extract(in_point[0]),bp::extract(in_point[1]))); -- } -- stock_dpaths.push_back(dpath); -- } -- -- // convert inputs -- AdaptivePath::DPaths dpaths; -- for(bp::ssize_t i=0;i(in_paths[i]); -- AdaptivePath::DPath dpath; -- for(bp::ssize_t j=0;j(in_path[j]); -- dpath.push_back(pair(bp::extract(in_point[0]),bp::extract(in_point[1]))); -- } -- dpaths.push_back(dpath); -- } -- // Execute with callback -- std::list result=ada.Execute(stock_dpaths,dpaths,[progressCallbackFn](AdaptivePath::TPaths tp)->bool { -- bp::list out_paths; -- for(const auto & in_pair : tp) { -- bp::list path; -- for(const auto & in_pt : in_pair.second) { -- path.append(bp::make_tuple(in_pt.first,in_pt.second)); -- } -- out_paths.append(bp::make_tuple(in_pair.first,path)); -- } -- return bp::extract(progressCallbackFn(out_paths)); -- }); -- // convert outputs back -- BOOST_FOREACH(const auto & res, result) { -- out_list.append(res); -- } -- return out_list; --} -- -- // Converts a std::pair instance to a Python tuple. -- template -- struct std_pair_to_tuple -- { -- static PyObject* convert(std::pair const& p) -- { -- return boost::python::incref( -- boost::python::make_tuple(p.first, p.second).ptr()); -- } -- static PyTypeObject const *get_pytype () { -- return &PyTuple_Type; -- } -- }; -- -- boost::python::list AdaptiveOutput_AdaptivePaths(const AdaptivePath::AdaptiveOutput &ado) { -- bp::list olist; -- for(auto & ap : ado.AdaptivePaths) { -- bp::list op; -- for(auto & pt : ap.second) { -- op.append(bp::make_tuple(pt.first, pt.second)); -- } -- olist.append(bp::make_tuple(ap.first, op)); -- } -- return olist; -- } -- -- --BOOST_PYTHON_MODULE(area) { -- bp::class_("Point") -- .def(bp::init()) -- .def(bp::init()) -- .def(bp::other() * bp::self) -- .def(bp::self * bp::other()) -- .def(bp::self / bp::other()) -- .def(bp::self * bp::other()) -- .def(bp::self - bp::other()) -- .def(bp::self + bp::other()) -- .def(bp::self ^ bp::other()) -- .def(bp::self == bp::other()) -- .def(bp::self != bp::other()) -- .def(-bp::self) -- .def(~bp::self) -- .def("dist", &Point::dist) -- .def("length", &Point::length) -- .def("normalize", &Point::normalize) -- .def("Rotate", static_cast< void (Point::*)(double, double) >(&Point::Rotate)) -- .def("Rotate", static_cast< void (Point::*)(double) >(&Point::Rotate)) -- .def_readwrite("x", &Point::x) -- .def_readwrite("y", &Point::y) -- .def("Transform", &Point::Transform) -- ; -- -- bp::class_("Vertex") -- .def(bp::init()) -- .def(bp::init()) -- .def(bp::init()) -- .def(bp::init()) -- .def_readwrite("type", &CVertex::m_type) -- .def_readwrite("p", &CVertex::m_p) -- .def_readwrite("c", &CVertex::m_c) -- .def_readwrite("user_data", &CVertex::m_user_data) -- ; -- -- bp::class_("Span") -- .def(bp::init()) -- .def(bp::init()) -- .def("NearestPoint", static_cast< Point (Span::*)(const Point& p)const >(&Span::NearestPoint)) -- .def("NearestPoint", static_cast< Point (Span::*)(const Span& p, double *d)const >(&Span::NearestPoint)) -- .def("GetBox", &Span::GetBox) -- .def("IncludedAngle", &Span::IncludedAngle) -- .def("GetArea", &Span::GetArea) -- .def("On", &Span::On) -- .def("MidPerim", &Span::MidPerim) -- .def("MidParam", &Span::MidParam) -- .def("Length", &Span::Length) -- .def("GetVector", &Span::GetVector) -- .def("Intersect", &spanIntersect) -- .def_readwrite("p", &Span::m_p) -- .def_readwrite("v", &Span::m_v) -- ; -- -- bp::class_("Curve") -- .def(bp::init()) -- .def("getVertices", &getVertices) -- .def("append",&CCurve::append) -- .def("append",&append_point) -- .def("text", &print_curve) -- .def("NearestPoint", static_cast< Point (CCurve::*)(const Point& p)const >(&CCurve::NearestPoint)) -- .def("NearestPoint", &nearest_point_to_curve) -- .def("Reverse", &CCurve::Reverse) -- .def("getNumVertices", &num_vertices) -- .def("FirstVertex", &FirstVertex) -- .def("LastVertex", &LastVertex) -- .def("GetArea", &CCurve::GetArea) -- .def("IsClockwise", &CCurve::IsClockwise) -- .def("IsClosed", &CCurve::IsClosed) -- .def("ChangeStart",&CCurve::ChangeStart) -- .def("ChangeEnd",&CCurve::ChangeEnd) -- .def("Offset",&CCurve::Offset) -- .def("OffsetForward",&CCurve::OffsetForward) -- .def("GetSpans",&getCurveSpans) -- .def("GetFirstSpan",&getFirstCurveSpan) -- .def("GetLastSpan",&getLastCurveSpan) -- .def("Break",&CCurve::Break) -- .def("Perim",&CCurve::Perim) -- .def("PerimToPoint",&CCurve::PerimToPoint) -- .def("PointToPerim",&CCurve::PointToPerim) -- .def("FitArcs",&CCurve::FitArcs) -- .def("UnFitArcs",&CCurve::UnFitArcs) -- .def("Intersections",&CurveIntersections) -- ; -- -- bp::class_("Box") -- .def(bp::init()) -- .def("MinX", &CBox2D::MinX) -- .def("MaxX", &CBox2D::MaxX) -- .def("MinY", &CBox2D::MinY) -- .def("MaxY", &CBox2D::MaxY) -- ; -- -- bp::class_("Area") -- .def(bp::init()) -- .def("getCurves", &getCurves) -- .def("append",&CArea::append) -- .def("Subtract",&CArea::Subtract) -- .def("Intersect",&CArea::Intersect) -- .def("Union",&CArea::Union) -- .def("Offset",&CArea::Offset) -- .def("FitArcs",&CArea::FitArcs) -- .def("text", &print_area) -- .def("num_curves", &CArea::num_curves) -- .def("NearestPoint", &CArea::NearestPoint) -- .def("GetBox", &CArea::GetBox) -- .def("Reorder", &CArea::Reorder) -- .def("MakePocketToolpath", &MakePocketToolpath) -- .def("Split", &SplitArea) -- .def("InsideCurves", &InsideCurves) -- .def("Thicken", &CArea::Thicken) -- .def("Intersections",&AreaIntersections) -- .def("GetArea",&AreaGetArea) -- ; -- -- bp::class_ > ("Matrix") -- .def(bp::init()) -- .def("__init__", bp::make_constructor(&matrix_constructor)) -- .def("TransformedPoint", &transformed_point) -- .def("Multiply", &geoff_geometry::Matrix::Multiply) -- ; -- -- bp::def("set_units", set_units); -- bp::def("get_units", get_units); -- bp::def("holes_linked", holes_linked); -- bp::def("AreaFromDxf", AreaFromDxf); -- bp::def("TangentialArc", TangentialArc); -- -- -- using namespace AdaptivePath; -- -- boost::python::to_python_converter, std_pair_to_tuple,true>(); -- -- -- bp::enum_("AdaptiveMotionType") -- .value("Cutting", MotionType::mtCutting) -- .value("LinkClear", MotionType::mtLinkClear) -- .value("LinkNotClear", MotionType::mtLinkNotClear) -- .value("LinkClearAtPrevPass", MotionType::mtLinkClearAtPrevPass); -- -- bp::enum_("AdaptiveOperationType") -- .value("ClearingInside", OperationType::otClearingInside) -- .value("ClearingOutside", OperationType::otClearingOutside) -- .value("ProfilingInside", OperationType::otProfilingInside) -- .value("ProfilingOutside", OperationType::otProfilingOutside); -- -- bp::class_ ("AdaptiveOutput") -- .def(bp::init<>()) -- .add_property("HelixCenterPoint", bp::make_getter(&AdaptiveOutput::HelixCenterPoint, bp::return_value_policy())) -- .add_property("StartPoint", bp::make_getter(&AdaptiveOutput::StartPoint, bp::return_value_policy())) -- .add_property("AdaptivePaths", &AdaptiveOutput_AdaptivePaths) -- .def_readonly("ReturnMotionType",&AdaptiveOutput::ReturnMotionType); -- -- bp::class_("Adaptive2d") -- .def(bp::init<>()) -- .def("Execute",&AdaptiveExecute) -- .def_readwrite("stepOverFactor", &Adaptive2d::stepOverFactor) -- .def_readwrite("toolDiameter", &Adaptive2d::toolDiameter) -- .def_readwrite("stockToLeave", &Adaptive2d::stockToLeave) -- .def_readwrite("helixRampDiameter", &Adaptive2d::helixRampDiameter) -- .def_readwrite("forceInsideOut", &Adaptive2d::forceInsideOut) -- //.def_readwrite("polyTreeNestingLimit", &Adaptive2d::polyTreeNestingLimit) -- .def_readwrite("tolerance", &Adaptive2d::tolerance) -- .def_readwrite("keepToolDownDistRatio", &Adaptive2d::keepToolDownDistRatio) -- .def_readwrite("opType", &Adaptive2d::opType); -- -- --} -- -- -- -+// PythonStuff.cpp -+// Copyright 2011, Dan Heeks -+// This program is released under the BSD license. See the file COPYING for details. -+ -+#include "PythonStuff.h" -+ -+#include "Area.h" -+#include "Point.h" -+#include "AreaDxf.h" -+#include "kurve/geometry.h" -+#include "Adaptive.hpp" -+ -+#if defined (_POSIX_C_SOURCE) -+# undef _POSIX_C_SOURCE -+#endif -+ -+#if defined (_XOPEN_SOURCE) -+# undef _XOPEN_SOURCE -+#endif -+ -+#if _DEBUG -+#undef _DEBUG -+#include -+#define _DEBUG -+#else -+#include -+#endif -+ -+#if defined(__GNUG__) && !defined(__clang__) -+#pragma implementation -+#endif -+ -+#define BOOST_BIND_GLOBAL_PLACEHOLDERS -+ -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+ -+ -+#include "clipper.hpp" -+using namespace ClipperLib; -+ -+ -+namespace bp = boost::python; -+ -+boost::python::list getVertices(const CCurve& curve) { -+ boost::python::list vlist; -+ BOOST_FOREACH(const CVertex& vertex, curve.m_vertices) { -+ vlist.append(vertex); -+ } -+ return vlist; -+} -+ -+boost::python::list getCurves(const CArea& area) { -+ boost::python::list clist; -+ BOOST_FOREACH(const CCurve& curve, area.m_curves) { -+ clist.append(curve); -+ } -+ return clist; -+} -+ -+boost::python::tuple transformed_point(const geoff_geometry::Matrix &matrix, double x, double y, double z) -+{ -+ geoff_geometry::Point3d p(x,y,z); -+ p = p.Transform(matrix); -+ -+ return bp::make_tuple(p.x,p.y,p.z); -+} -+ -+static void print_curve(const CCurve& c) -+{ -+ std::size_t nvertices = c.m_vertices.size(); -+#if defined SIZEOF_SIZE_T && SIZEOF_SIZE_T == 4 -+ printf("number of vertices = %d\n", nvertices); -+#else -+ printf("number of vertices = %lu\n", nvertices); -+#endif -+ int i = 0; -+ for(std::list::const_iterator It = c.m_vertices.begin(); It != c.m_vertices.end(); It++, i++) -+ { -+ const CVertex& vertex = *It; -+ printf("vertex %d type = %d, x = %g, y = %g", i+1, vertex.m_type, vertex.m_p.x / CArea::get_units(), vertex.m_p.y / CArea::get_units()); -+ if(vertex.m_type)printf(", xc = %g, yc = %g", vertex.m_c.x / CArea::get_units(), vertex.m_c.y / CArea::get_units()); -+ printf("\n"); -+ } -+} -+ -+static void print_area(const CArea &a) -+{ -+ for(std::list::const_iterator It = a.m_curves.begin(); It != a.m_curves.end(); It++) -+ { -+ const CCurve& curve = *It; -+ print_curve(curve); -+ } -+} -+ -+static unsigned int num_vertices(const CCurve& curve) -+{ -+ return static_cast(curve.m_vertices.size()); -+} -+ -+static CVertex FirstVertex(const CCurve& curve) -+{ -+ return curve.m_vertices.front(); -+} -+ -+static CVertex LastVertex(const CCurve& curve) -+{ -+ return curve.m_vertices.back(); -+} -+ -+static void set_units(double units) -+{ -+ CArea::set_units(units); -+} -+ -+static double get_units() -+{ -+ return CArea::get_units(); -+} -+ -+static bool holes_linked() -+{ -+ return CArea::HolesLinked(); -+} -+ -+static CArea AreaFromDxf(const char* filepath) -+{ -+ CArea area; -+ AreaDxfRead dxf(&area, filepath); -+ dxf.DoRead(); -+ return area; -+} -+ -+static void append_point(CCurve& c, const Point& p) -+{ -+ c.m_vertices.push_back(CVertex(p)); -+} -+ -+static boost::python::tuple nearest_point_to_curve(CCurve& c1, const CCurve& c2) -+{ -+ double dist; -+ Point p = c1.NearestPoint(c2, &dist); -+ -+ return bp::make_tuple(p, dist); -+} -+ -+boost::python::list MakePocketToolpath(const CArea& a, double tool_radius, double extra_offset, double stepover, bool from_center, bool use_zig_zag, double zig_angle) -+{ -+ std::list toolpath; -+ -+ CAreaPocketParams params(tool_radius, extra_offset, stepover, from_center, use_zig_zag ? ZigZagPocketMode : SpiralPocketMode, zig_angle); -+ a.SplitAndMakePocketToolpath(toolpath, params); -+ -+ boost::python::list clist; -+ BOOST_FOREACH(const CCurve& c, toolpath) { -+ clist.append(c); -+ } -+ return clist; -+} -+ -+boost::python::list SplitArea(const CArea& a) -+{ -+ std::list areas; -+ a.Split(areas); -+ -+ boost::python::list alist; -+ BOOST_FOREACH(const CArea& a, areas) { -+ alist.append(a); -+ } -+ return alist; -+} -+ -+void dxfArea(CArea& area, const char* /*str*/) -+{ -+ area = CArea(); -+} -+ -+boost::python::list getCurveSpans(const CCurve& c) -+{ -+ boost::python::list span_list; -+ const Point *prev_p = NULL; -+ -+ for(std::list::const_iterator VIt = c.m_vertices.begin(); VIt != c.m_vertices.end(); VIt++) -+ { -+ const CVertex& vertex = *VIt; -+ -+ if(prev_p) -+ { -+ span_list.append(Span(*prev_p, vertex)); -+ } -+ prev_p = &(vertex.m_p); -+ } -+ -+ return span_list; -+} -+ -+Span getFirstCurveSpan(const CCurve& c) -+{ -+ if(c.m_vertices.size() < 2)return Span(); -+ -+ std::list::const_iterator VIt = c.m_vertices.begin(); -+ const Point &p = (*VIt).m_p; -+ VIt++; -+ return Span(p, *VIt, true); -+} -+ -+Span getLastCurveSpan(const CCurve& c) -+{ -+ if(c.m_vertices.size() < 2)return Span(); -+ -+ std::list::const_reverse_iterator VIt = c.m_vertices.rbegin(); -+ const CVertex &v = (*VIt); -+ VIt++; -+ -+ return Span((*VIt).m_p, v, c.m_vertices.size() == 2); -+} -+ -+bp::tuple TangentialArc(const Point &p0, const Point &p1, const Point &v0) -+{ -+ Point c; -+ int dir; -+ tangential_arc(p0, p1, v0, c, dir); -+ -+ return bp::make_tuple(c, dir); -+} -+ -+boost::python::list spanIntersect(const Span& span1, const Span& span2) { -+ boost::python::list plist; -+ std::list pts; -+ span1.Intersect(span2, pts); -+ BOOST_FOREACH(const Point& p, pts) { -+ plist.append(p); -+ } -+ return plist; -+} -+ -+//Matrix(boost::python::list &l){} -+boost::shared_ptr matrix_constructor(const boost::python::list& lst) { -+ double m[16] = {1,0,0,0,0,1,0,0, 0,0,1,0, 0,0,0,1}; -+ -+ boost::python::ssize_t n = boost::python::len(lst); -+ int j = 0; -+ for(boost::python::ssize_t i=0;i(elem.attr("__float__")()); -+ j++; -+ if(j>=16)break; -+ } -+ -+ return boost::shared_ptr( new geoff_geometry::Matrix(m) ); -+} -+ -+boost::python::list InsideCurves(const CArea& a, const CCurve& curve) { -+ boost::python::list plist; -+ -+ std::list curves_inside; -+ a.InsideCurves(curve, curves_inside); -+ BOOST_FOREACH(const CCurve& c, curves_inside) { -+ plist.append(c); -+ } -+ return plist; -+} -+ -+boost::python::list CurveIntersections(const CCurve& c1, const CCurve& c2) { -+ boost::python::list plist; -+ -+ std::list pts; -+ c1.CurveIntersections(c2, pts); -+ BOOST_FOREACH(const Point& p, pts) { -+ plist.append(p); -+ } -+ return plist; -+} -+ -+boost::python::list AreaIntersections(const CArea& a, const CCurve& c2) { -+ boost::python::list plist; -+ -+ std::list pts; -+ a.CurveIntersections(c2, pts); -+ BOOST_FOREACH(const Point& p, pts) { -+ plist.append(p); -+ } -+ return plist; -+} -+ -+double AreaGetArea(const CArea& a) -+{ -+ return a.GetArea(); -+} -+ -+ -+ -+// Adaptive2d.Execute wrapper -+bp::list AdaptiveExecute(AdaptivePath::Adaptive2d& ada,const boost::python::list &stock_paths, const boost::python::list &in_paths, boost::python::object progressCallbackFn) { -+ bp::list out_list; -+ -+ // convert stock paths -+ AdaptivePath::DPaths stock_dpaths; -+ for(bp::ssize_t i=0;i(stock_paths[i]); -+ AdaptivePath::DPath dpath; -+ for(bp::ssize_t j=0;j(in_path[j]); -+ dpath.push_back(pair(bp::extract(in_point[0]),bp::extract(in_point[1]))); -+ } -+ stock_dpaths.push_back(dpath); -+ } -+ -+ // convert inputs -+ AdaptivePath::DPaths dpaths; -+ for(bp::ssize_t i=0;i(in_paths[i]); -+ AdaptivePath::DPath dpath; -+ for(bp::ssize_t j=0;j(in_path[j]); -+ dpath.push_back(pair(bp::extract(in_point[0]),bp::extract(in_point[1]))); -+ } -+ dpaths.push_back(dpath); -+ } -+ // Execute with callback -+ std::list result=ada.Execute(stock_dpaths,dpaths,[progressCallbackFn](AdaptivePath::TPaths tp)->bool { -+ bp::list out_paths; -+ for(const auto & in_pair : tp) { -+ bp::list path; -+ for(const auto & in_pt : in_pair.second) { -+ path.append(bp::make_tuple(in_pt.first,in_pt.second)); -+ } -+ out_paths.append(bp::make_tuple(in_pair.first,path)); -+ } -+ return bp::extract(progressCallbackFn(out_paths)); -+ }); -+ // convert outputs back -+ BOOST_FOREACH(const auto & res, result) { -+ out_list.append(res); -+ } -+ return out_list; -+} -+ -+ // Converts a std::pair instance to a Python tuple. -+ template -+ struct std_pair_to_tuple -+ { -+ static PyObject* convert(std::pair const& p) -+ { -+ return boost::python::incref( -+ boost::python::make_tuple(p.first, p.second).ptr()); -+ } -+ static PyTypeObject const *get_pytype () { -+ return &PyTuple_Type; -+ } -+ }; -+ -+ boost::python::list AdaptiveOutput_AdaptivePaths(const AdaptivePath::AdaptiveOutput &ado) { -+ bp::list olist; -+ for(auto & ap : ado.AdaptivePaths) { -+ bp::list op; -+ for(auto & pt : ap.second) { -+ op.append(bp::make_tuple(pt.first, pt.second)); -+ } -+ olist.append(bp::make_tuple(ap.first, op)); -+ } -+ return olist; -+ } -+ -+ -+BOOST_PYTHON_MODULE(area) { -+ bp::class_("Point") -+ .def(bp::init()) -+ .def(bp::init()) -+ .def(bp::other() * bp::self) -+ .def(bp::self * bp::other()) -+ .def(bp::self / bp::other()) -+ .def(bp::self * bp::other()) -+ .def(bp::self - bp::other()) -+ .def(bp::self + bp::other()) -+ .def(bp::self ^ bp::other()) -+ .def(bp::self == bp::other()) -+ .def(bp::self != bp::other()) -+ .def(-bp::self) -+ .def(~bp::self) -+ .def("dist", &Point::dist) -+ .def("length", &Point::length) -+ .def("normalize", &Point::normalize) -+ .def("Rotate", static_cast< void (Point::*)(double, double) >(&Point::Rotate)) -+ .def("Rotate", static_cast< void (Point::*)(double) >(&Point::Rotate)) -+ .def_readwrite("x", &Point::x) -+ .def_readwrite("y", &Point::y) -+ .def("Transform", &Point::Transform) -+ ; -+ -+ bp::class_("Vertex") -+ .def(bp::init()) -+ .def(bp::init()) -+ .def(bp::init()) -+ .def(bp::init()) -+ .def_readwrite("type", &CVertex::m_type) -+ .def_readwrite("p", &CVertex::m_p) -+ .def_readwrite("c", &CVertex::m_c) -+ .def_readwrite("user_data", &CVertex::m_user_data) -+ ; -+ -+ bp::class_("Span") -+ .def(bp::init()) -+ .def(bp::init()) -+ .def("NearestPoint", static_cast< Point (Span::*)(const Point& p)const >(&Span::NearestPoint)) -+ .def("NearestPoint", static_cast< Point (Span::*)(const Span& p, double *d)const >(&Span::NearestPoint)) -+ .def("GetBox", &Span::GetBox) -+ .def("IncludedAngle", &Span::IncludedAngle) -+ .def("GetArea", &Span::GetArea) -+ .def("On", &Span::On) -+ .def("MidPerim", &Span::MidPerim) -+ .def("MidParam", &Span::MidParam) -+ .def("Length", &Span::Length) -+ .def("GetVector", &Span::GetVector) -+ .def("Intersect", &spanIntersect) -+ .def_readwrite("p", &Span::m_p) -+ .def_readwrite("v", &Span::m_v) -+ ; -+ -+ bp::class_("Curve") -+ .def(bp::init()) -+ .def("getVertices", &getVertices) -+ .def("append",&CCurve::append) -+ .def("append",&append_point) -+ .def("text", &print_curve) -+ .def("NearestPoint", static_cast< Point (CCurve::*)(const Point& p)const >(&CCurve::NearestPoint)) -+ .def("NearestPoint", &nearest_point_to_curve) -+ .def("Reverse", &CCurve::Reverse) -+ .def("getNumVertices", &num_vertices) -+ .def("FirstVertex", &FirstVertex) -+ .def("LastVertex", &LastVertex) -+ .def("GetArea", &CCurve::GetArea) -+ .def("IsClockwise", &CCurve::IsClockwise) -+ .def("IsClosed", &CCurve::IsClosed) -+ .def("ChangeStart",&CCurve::ChangeStart) -+ .def("ChangeEnd",&CCurve::ChangeEnd) -+ .def("Offset",&CCurve::Offset) -+ .def("OffsetForward",&CCurve::OffsetForward) -+ .def("GetSpans",&getCurveSpans) -+ .def("GetFirstSpan",&getFirstCurveSpan) -+ .def("GetLastSpan",&getLastCurveSpan) -+ .def("Break",&CCurve::Break) -+ .def("Perim",&CCurve::Perim) -+ .def("PerimToPoint",&CCurve::PerimToPoint) -+ .def("PointToPerim",&CCurve::PointToPerim) -+ .def("FitArcs",&CCurve::FitArcs) -+ .def("UnFitArcs",&CCurve::UnFitArcs) -+ .def("Intersections",&CurveIntersections) -+ ; -+ -+ bp::class_("Box") -+ .def(bp::init()) -+ .def("MinX", &CBox2D::MinX) -+ .def("MaxX", &CBox2D::MaxX) -+ .def("MinY", &CBox2D::MinY) -+ .def("MaxY", &CBox2D::MaxY) -+ ; -+ -+ bp::class_("Area") -+ .def(bp::init()) -+ .def("getCurves", &getCurves) -+ .def("append",&CArea::append) -+ .def("Subtract",&CArea::Subtract) -+ .def("Intersect",&CArea::Intersect) -+ .def("Union",&CArea::Union) -+ .def("Offset",&CArea::Offset) -+ .def("FitArcs",&CArea::FitArcs) -+ .def("text", &print_area) -+ .def("num_curves", &CArea::num_curves) -+ .def("NearestPoint", &CArea::NearestPoint) -+ .def("GetBox", &CArea::GetBox) -+ .def("Reorder", &CArea::Reorder) -+ .def("MakePocketToolpath", &MakePocketToolpath) -+ .def("Split", &SplitArea) -+ .def("InsideCurves", &InsideCurves) -+ .def("Thicken", &CArea::Thicken) -+ .def("Intersections",&AreaIntersections) -+ .def("GetArea",&AreaGetArea) -+ ; -+ -+ bp::class_ > ("Matrix") -+ .def(bp::init()) -+ .def("__init__", bp::make_constructor(&matrix_constructor)) -+ .def("TransformedPoint", &transformed_point) -+ .def("Multiply", &geoff_geometry::Matrix::Multiply) -+ ; -+ -+ bp::def("set_units", set_units); -+ bp::def("get_units", get_units); -+ bp::def("holes_linked", holes_linked); -+ bp::def("AreaFromDxf", AreaFromDxf); -+ bp::def("TangentialArc", TangentialArc); -+ -+ -+ using namespace AdaptivePath; -+ -+ boost::python::to_python_converter, std_pair_to_tuple,true>(); -+ -+ -+ bp::enum_("AdaptiveMotionType") -+ .value("Cutting", MotionType::mtCutting) -+ .value("LinkClear", MotionType::mtLinkClear) -+ .value("LinkNotClear", MotionType::mtLinkNotClear) -+ .value("LinkClearAtPrevPass", MotionType::mtLinkClearAtPrevPass); -+ -+ bp::enum_("AdaptiveOperationType") -+ .value("ClearingInside", OperationType::otClearingInside) -+ .value("ClearingOutside", OperationType::otClearingOutside) -+ .value("ProfilingInside", OperationType::otProfilingInside) -+ .value("ProfilingOutside", OperationType::otProfilingOutside); -+ -+ bp::class_ ("AdaptiveOutput") -+ .def(bp::init<>()) -+ .add_property("HelixCenterPoint", bp::make_getter(&AdaptiveOutput::HelixCenterPoint, bp::return_value_policy())) -+ .add_property("StartPoint", bp::make_getter(&AdaptiveOutput::StartPoint, bp::return_value_policy())) -+ .add_property("AdaptivePaths", &AdaptiveOutput_AdaptivePaths) -+ .def_readonly("ReturnMotionType",&AdaptiveOutput::ReturnMotionType); -+ -+ bp::class_("Adaptive2d") -+ .def(bp::init<>()) -+ .def("Execute",&AdaptiveExecute) -+ .def_readwrite("stepOverFactor", &Adaptive2d::stepOverFactor) -+ .def_readwrite("toolDiameter", &Adaptive2d::toolDiameter) -+ .def_readwrite("stockToLeave", &Adaptive2d::stockToLeave) -+ .def_readwrite("helixRampDiameter", &Adaptive2d::helixRampDiameter) -+ .def_readwrite("forceInsideOut", &Adaptive2d::forceInsideOut) -+ //.def_readwrite("polyTreeNestingLimit", &Adaptive2d::polyTreeNestingLimit) -+ .def_readwrite("tolerance", &Adaptive2d::tolerance) -+ .def_readwrite("keepToolDownDistRatio", &Adaptive2d::keepToolDownDistRatio) -+ .def_readwrite("opType", &Adaptive2d::opType); -+ -+ -+} -+ -+ -+ -diff --git a/src/Mod/ReverseEngineering/App/ApproxSurface.cpp b/src/Mod/ReverseEngineering/App/ApproxSurface.cpp -index 171859ab5..c49de5e0a 100644 ---- a/src/Mod/ReverseEngineering/App/ApproxSurface.cpp -+++ b/src/Mod/ReverseEngineering/App/ApproxSurface.cpp -@@ -30,7 +30,7 @@ - #include - #include - #include --#include -+#include - - #include - #include -@@ -40,6 +40,7 @@ - #include "ApproxSurface.h" - - using namespace Reen; -+namespace bp = boost::placeholders; - - // SplineBasisfunction - -@@ -1090,7 +1091,7 @@ bool BSplineParameterCorrection::SolveWithSmoothing(double fWeight) - std::generate(columns.begin(), columns.end(), Base::iotaGen(0)); - ScalarProduct scalar(M); - QFuture< std::vector > future = QtConcurrent::mapped -- (columns, boost::bind(&ScalarProduct::multiply, &scalar, _1)); -+ (columns, boost::bind(&ScalarProduct::multiply, &scalar, bp::_1)); - QFutureWatcher< std::vector > watcher; - watcher.setFuture(future); - watcher.waitForFinished(); -diff --git a/src/Mod/Sandbox/App/DocumentProtector.h b/src/Mod/Sandbox/App/DocumentProtector.h -index 603b92932..f44aebdb5 100644 ---- a/src/Mod/Sandbox/App/DocumentProtector.h -+++ b/src/Mod/Sandbox/App/DocumentProtector.h -@@ -25,7 +25,6 @@ - #define SANDBOX_DOCUMENTPROTECTOR_H - - #include --#include - #include - - namespace App { -diff --git a/src/Mod/Sandbox/Gui/Command.cpp b/src/Mod/Sandbox/Gui/Command.cpp -index 67db11a1e..81158c70b 100644 ---- a/src/Mod/Sandbox/Gui/Command.cpp -+++ b/src/Mod/Sandbox/Gui/Command.cpp -@@ -56,7 +56,7 @@ - # if BOOST_VERSION >= 104100 - # include - # endif --# include -+# include - # include - #endif - -@@ -81,6 +81,8 @@ - #include "GLGraphicsView.h" - #include "TaskPanelView.h" - -+namespace bp = boost::placeholders; -+ - DEF_STD_CMD(CmdSandboxDocumentThread); - - CmdSandboxDocumentThread::CmdSandboxDocumentThread() -@@ -829,7 +831,7 @@ void CmdSandboxMeshTestJob::activated(int) - Base::Console().Message("Mesh test (step %d)...\n",iteration++); - MeshTestJob meshJob; - QFuture mesh_future = QtConcurrent::mapped -- (mesh_groups, boost::bind(&MeshTestJob::run, &meshJob, _1)); -+ (mesh_groups, boost::bind(&MeshTestJob::run, &meshJob, bp::_1)); - - // keep it responsive during computation - QFutureWatcher mesh_watcher; -diff --git a/src/Mod/Sandbox/Gui/TaskPanelView.cpp b/src/Mod/Sandbox/Gui/TaskPanelView.cpp -index 92f709608..ad2e78b1a 100644 ---- a/src/Mod/Sandbox/Gui/TaskPanelView.cpp -+++ b/src/Mod/Sandbox/Gui/TaskPanelView.cpp -@@ -25,7 +25,7 @@ - - /// Here the FreeCAD includes sorted by Base,App,Gui...... - --#include -+#include - #include - #include - #include -@@ -55,6 +55,7 @@ - - - using namespace SandboxGui; -+namespace bp = boost::placeholders; - - - #if defined(QSINT_ACTIONPANEL) -@@ -557,27 +558,27 @@ TaskPanelView::TaskPanelView(QWidget *parent) - - QAction* defaultAction = new QAction(this); - connect(ui->rbDefaultScheme, SIGNAL(toggled(bool)), defaultAction, SIGNAL(toggled(bool))); -- func->toggle(defaultAction, boost::bind(&TaskPanelView::on_rbDefaultScheme_toggled, this, _1)); -+ func->toggle(defaultAction, boost::bind(&TaskPanelView::on_rbDefaultScheme_toggled, this, bp::_1)); - - QAction* xpBlueAction = new QAction(this); - connect(ui->rbXPBlueScheme, SIGNAL(toggled(bool)), xpBlueAction, SIGNAL(toggled(bool))); -- func->toggle(xpBlueAction, boost::bind(&TaskPanelView::on_rbXPBlueScheme_toggled, this, _1)); -+ func->toggle(xpBlueAction, boost::bind(&TaskPanelView::on_rbXPBlueScheme_toggled, this, bp::_1)); - - QAction* xpBlue2Action = new QAction(this); - connect(ui->rbXPBlue2Scheme, SIGNAL(toggled(bool)), xpBlue2Action, SIGNAL(toggled(bool))); -- func->toggle(xpBlue2Action, boost::bind(&TaskPanelView::on_rbXPBlue2Scheme_toggled, this, _1)); -+ func->toggle(xpBlue2Action, boost::bind(&TaskPanelView::on_rbXPBlue2Scheme_toggled, this, bp::_1)); - - QAction* vistaAction = new QAction(this); - connect(ui->rbVistaScheme, SIGNAL(toggled(bool)), vistaAction, SIGNAL(toggled(bool))); -- func->toggle(vistaAction, boost::bind(&TaskPanelView::on_rbVistaScheme_toggled, this, _1)); -+ func->toggle(vistaAction, boost::bind(&TaskPanelView::on_rbVistaScheme_toggled, this, bp::_1)); - - QAction* macAction = new QAction(this); - connect(ui->rbMacScheme, SIGNAL(toggled(bool)), macAction, SIGNAL(toggled(bool))); -- func->toggle(macAction, boost::bind(&TaskPanelView::on_rbMacScheme_toggled, this, _1)); -+ func->toggle(macAction, boost::bind(&TaskPanelView::on_rbMacScheme_toggled, this, bp::_1)); - - QAction* androidAction = new QAction(this); - connect(ui->rbAndroidScheme, SIGNAL(toggled(bool)), androidAction, SIGNAL(toggled(bool))); -- func->toggle(androidAction, boost::bind(&TaskPanelView::on_rbAndroidScheme_toggled, this, _1)); -+ func->toggle(androidAction, boost::bind(&TaskPanelView::on_rbAndroidScheme_toggled, this, bp::_1)); - } - #else - setWindowTitle(QLatin1String("Task View")); -diff --git a/src/Mod/Sketcher/App/SketchObject.cpp b/src/Mod/Sketcher/App/SketchObject.cpp -index 8f022455a..20f664e37 100644 ---- a/src/Mod/Sketcher/App/SketchObject.cpp -+++ b/src/Mod/Sketcher/App/SketchObject.cpp -@@ -58,11 +58,10 @@ - # include - # include - # include -+# include - //# include - #endif - --#include -- - #include - #include - #include -@@ -88,6 +87,7 @@ - - using namespace Sketcher; - using namespace Base; -+namespace bp = boost::placeholders; - - const int GeoEnum::RtPnt = -1; - const int GeoEnum::HAxis = -1; -@@ -132,10 +132,10 @@ SketchObject::SketchObject() - - noRecomputes=false; - -- ExpressionEngine.setValidator(boost::bind(&Sketcher::SketchObject::validateExpression, this, _1, _2)); -+ ExpressionEngine.setValidator(boost::bind(&Sketcher::SketchObject::validateExpression, this, bp::_1, bp::_2)); - -- constraintsRemovedConn = Constraints.signalConstraintsRemoved.connect(boost::bind(&Sketcher::SketchObject::constraintsRemoved, this, _1)); -- constraintsRenamedConn = Constraints.signalConstraintsRenamed.connect(boost::bind(&Sketcher::SketchObject::constraintsRenamed, this, _1)); -+ constraintsRemovedConn = Constraints.signalConstraintsRemoved.connect(boost::bind(&Sketcher::SketchObject::constraintsRemoved, this, bp::_1)); -+ constraintsRenamedConn = Constraints.signalConstraintsRenamed.connect(boost::bind(&Sketcher::SketchObject::constraintsRenamed, this, bp::_1)); - - analyser = new SketchAnalysis(this); - } -diff --git a/src/Mod/Sketcher/Gui/TaskDlgEditSketch.cpp b/src/Mod/Sketcher/Gui/TaskDlgEditSketch.cpp -index abfa954a2..6679422a3 100644 ---- a/src/Mod/Sketcher/Gui/TaskDlgEditSketch.cpp -+++ b/src/Mod/Sketcher/Gui/TaskDlgEditSketch.cpp -@@ -24,7 +24,7 @@ - #include "PreCompiled.h" - - #ifndef _PreComp_ --# include -+# include - #endif - - #include "TaskDlgEditSketch.h" -@@ -32,6 +32,7 @@ - #include - - using namespace SketcherGui; -+namespace bp = boost::placeholders; - - - //************************************************************************** -@@ -74,9 +75,9 @@ TaskDlgEditSketch::TaskDlgEditSketch(ViewProviderSketch *sketchView) - - App::Document* document = sketchView->getObject()->getDocument(); - connectUndoDocument = -- document->signalUndo.connect(boost::bind(&TaskDlgEditSketch::slotUndoDocument, this, _1)); -+ document->signalUndo.connect(boost::bind(&TaskDlgEditSketch::slotUndoDocument, this, bp::_1)); - connectRedoDocument = -- document->signalRedo.connect(boost::bind(&TaskDlgEditSketch::slotRedoDocument, this, _1)); -+ document->signalRedo.connect(boost::bind(&TaskDlgEditSketch::slotRedoDocument, this, bp::_1)); - } - - TaskDlgEditSketch::~TaskDlgEditSketch() -diff --git a/src/Mod/Sketcher/Gui/TaskSketcherConstrains.cpp b/src/Mod/Sketcher/Gui/TaskSketcherConstrains.cpp -index 7eeeae6c5..e8a3ef8f6 100644 ---- a/src/Mod/Sketcher/Gui/TaskSketcherConstrains.cpp -+++ b/src/Mod/Sketcher/Gui/TaskSketcherConstrains.cpp -@@ -33,6 +33,7 @@ - # include - # include - # include -+# include - #endif - - #include "TaskSketcherConstrains.h" -@@ -50,7 +51,6 @@ - #include - #include - #include --#include - #include - #include - #include -diff --git a/src/Mod/Sketcher/Gui/TaskSketcherElements.cpp b/src/Mod/Sketcher/Gui/TaskSketcherElements.cpp -index 692a66d82..9f411838d 100644 ---- a/src/Mod/Sketcher/Gui/TaskSketcherElements.cpp -+++ b/src/Mod/Sketcher/Gui/TaskSketcherElements.cpp -@@ -29,6 +29,7 @@ - # include - # include - # include -+# include - #endif - - #include "TaskSketcherElements.h" -@@ -48,7 +49,6 @@ - #include - #include - #include --#include - #include - - using namespace SketcherGui; -diff --git a/src/Mod/Sketcher/Gui/TaskSketcherGeneral.cpp b/src/Mod/Sketcher/Gui/TaskSketcherGeneral.cpp -index 8b0e88478..58f832e23 100644 ---- a/src/Mod/Sketcher/Gui/TaskSketcherGeneral.cpp -+++ b/src/Mod/Sketcher/Gui/TaskSketcherGeneral.cpp -@@ -24,6 +24,7 @@ - #include "PreCompiled.h" - - #ifndef _PreComp_ -+#include - #endif - - #include "ui_TaskSketcherGeneral.h" -@@ -40,6 +41,7 @@ - - using namespace SketcherGui; - using namespace Gui::TaskView; -+namespace bp = boost::placeholders; - - SketcherGeneralWidget::SketcherGeneralWidget(QWidget *parent) - : QWidget(parent), ui(new Ui_TaskSketcherGeneral) -@@ -233,7 +235,7 @@ TaskSketcherGeneral::TaskSketcherGeneral(ViewProviderSketch *sketchView) - - Gui::Application* app = Gui::Application::Instance; - changedSketchView = app->signalChangedObject.connect(boost::bind -- (&TaskSketcherGeneral::onChangedSketchView, this, _1, _2)); -+ (&TaskSketcherGeneral::onChangedSketchView, this, bp::_1, bp::_2)); - } - - TaskSketcherGeneral::~TaskSketcherGeneral() -diff --git a/src/Mod/Sketcher/Gui/TaskSketcherMessages.cpp b/src/Mod/Sketcher/Gui/TaskSketcherMessages.cpp -index f51f126f3..8a77c8f92 100644 ---- a/src/Mod/Sketcher/Gui/TaskSketcherMessages.cpp -+++ b/src/Mod/Sketcher/Gui/TaskSketcherMessages.cpp -@@ -24,6 +24,7 @@ - #include "PreCompiled.h" - - #ifndef _PreComp_ -+# include - #endif - - #include "ui_TaskSketcherMessages.h" -@@ -36,14 +37,13 @@ - #include - #include - --#include -- - #include - - #include "ViewProviderSketch.h" - - using namespace SketcherGui; - using namespace Gui::TaskView; -+namespace bp = boost::placeholders; - - TaskSketcherMessages::TaskSketcherMessages(ViewProviderSketch *sketchView) - : TaskBox(Gui::BitmapFactory().pixmap("document-new"),tr("Solver messages"),true, 0) -@@ -57,8 +57,8 @@ TaskSketcherMessages::TaskSketcherMessages(ViewProviderSketch *sketchView) - - this->groupLayout()->addWidget(proxy); - -- connectionSetUp = sketchView->signalSetUp.connect(boost::bind(&SketcherGui::TaskSketcherMessages::slotSetUp, this,_1)); -- connectionSolved = sketchView->signalSolved.connect(boost::bind(&SketcherGui::TaskSketcherMessages::slotSolved, this,_1)); -+ connectionSetUp = sketchView->signalSetUp.connect(boost::bind(&SketcherGui::TaskSketcherMessages::slotSetUp, this, bp::_1)); -+ connectionSolved = sketchView->signalSolved.connect(boost::bind(&SketcherGui::TaskSketcherMessages::slotSolved, this, bp::_1)); - - ui->labelConstrainStatus->setOpenExternalLinks(false); - -diff --git a/src/Mod/Sketcher/Gui/ViewProviderSketch.cpp b/src/Mod/Sketcher/Gui/ViewProviderSketch.cpp -index 05ea71cb6..a63c2ca56 100644 ---- a/src/Mod/Sketcher/Gui/ViewProviderSketch.cpp -+++ b/src/Mod/Sketcher/Gui/ViewProviderSketch.cpp -@@ -73,7 +73,7 @@ - #endif - - #ifndef _PreComp_ --# include -+# include - #endif - - #include -@@ -134,6 +134,7 @@ - - using namespace SketcherGui; - using namespace Sketcher; -+namespace bp = boost::placeholders; - - SbColor ViewProviderSketch::VertexColor (1.0f,0.149f,0.0f); // #FF2600 -> (255, 38, 0) - SbColor ViewProviderSketch::CurveColor (1.0f,1.0f,1.0f); // #FFFFFF -> (255,255,255) -@@ -5693,9 +5694,9 @@ bool ViewProviderSketch::setEdit(int ModNum) - draw(false,true); - - connectUndoDocument = Gui::Application::Instance->activeDocument() -- ->signalUndoDocument.connect(boost::bind(&ViewProviderSketch::slotUndoDocument, this, _1)); -+ ->signalUndoDocument.connect(boost::bind(&ViewProviderSketch::slotUndoDocument, this, bp::_1)); - connectRedoDocument = Gui::Application::Instance->activeDocument() -- ->signalRedoDocument.connect(boost::bind(&ViewProviderSketch::slotRedoDocument, this, _1)); -+ ->signalRedoDocument.connect(boost::bind(&ViewProviderSketch::slotRedoDocument, this, bp::_1)); - - // Enable solver initial solution update while dragging. - ParameterGrp::handle hGrp2 = App::GetApplication().GetParameterGroupByPath("User parameter:BaseApp/Preferences/Mod/Sketcher"); -diff --git a/src/Mod/Spreadsheet/App/PropertySheet.cpp b/src/Mod/Spreadsheet/App/PropertySheet.cpp -index 8ed557f44..669605b4e 100644 ---- a/src/Mod/Spreadsheet/App/PropertySheet.cpp -+++ b/src/Mod/Spreadsheet/App/PropertySheet.cpp -@@ -28,7 +28,7 @@ - #include - #include - #include --#include -+#include - #include - #include - #include -@@ -45,6 +45,7 @@ - using namespace App; - using namespace Base; - using namespace Spreadsheet; -+namespace bp = boost::placeholders; - - namespace Spreadsheet { - -@@ -679,7 +680,7 @@ void PropertySheet::insertRows(int row, int count) - boost::copy( data | boost::adaptors::map_keys, std::back_inserter(keys)); - - /* Sort them */ -- std::sort(keys.begin(), keys.end(), boost::bind(&PropertySheet::rowSortFunc, this, _1, _2)); -+ std::sort(keys.begin(), keys.end(), boost::bind(&PropertySheet::rowSortFunc, this, bp::_1, bp::_2)); - - RewriteExpressionVisitor visitor(CellAddress(row, CellAddress::MAX_COLUMNS), count, 0); - -@@ -728,7 +729,7 @@ void PropertySheet::removeRows(int row, int count) - boost::copy(data | boost::adaptors::map_keys, std::back_inserter(keys)); - - /* Sort them */ -- std::sort(keys.begin(), keys.end(), boost::bind(&PropertySheet::rowSortFunc, this, _1, _2)); -+ std::sort(keys.begin(), keys.end(), boost::bind(&PropertySheet::rowSortFunc, this, bp::_1, bp::_2)); - - RewriteExpressionVisitor visitor(CellAddress(row + count - 1, CellAddress::MAX_COLUMNS), -count, 0); - -@@ -816,7 +817,7 @@ void PropertySheet::removeColumns(int col, int count) - boost::copy(data | boost::adaptors::map_keys, std::back_inserter(keys)); - - /* Sort them */ -- std::sort(keys.begin(), keys.end(), boost::bind(&PropertySheet::colSortFunc, this, _1, _2)); -+ std::sort(keys.begin(), keys.end(), boost::bind(&PropertySheet::colSortFunc, this, bp::_1, bp::_2)); - - RewriteExpressionVisitor visitor(CellAddress(CellAddress::MAX_ROWS, col + count - 1), 0, -count); - -diff --git a/src/Mod/Spreadsheet/App/Sheet.cpp b/src/Mod/Spreadsheet/App/Sheet.cpp -index 5ff7720b0..4157ac08f 100644 ---- a/src/Mod/Spreadsheet/App/Sheet.cpp -+++ b/src/Mod/Spreadsheet/App/Sheet.cpp -@@ -50,12 +50,12 @@ - #include - #include - #include --#include - #include - - using namespace Base; - using namespace App; - using namespace Spreadsheet; -+namespace bp = boost::placeholders; - - PROPERTY_SOURCE(Spreadsheet::Sheet, App::DocumentObject) - -@@ -89,8 +89,8 @@ Sheet::Sheet() - docDeps.setSize(0); - docDeps.setScope(LinkScope::Global); - -- onRenamedDocumentConnection = GetApplication().signalRenameDocument.connect(boost::bind(&Spreadsheet::Sheet::onRenamedDocument, this, _1)); -- onRelabledDocumentConnection = GetApplication().signalRelabelDocument.connect(boost::bind(&Spreadsheet::Sheet::onRelabledDocument, this, _1)); -+ onRenamedDocumentConnection = GetApplication().signalRenameDocument.connect(boost::bind(&Spreadsheet::Sheet::onRenamedDocument, this, bp::_1)); -+ onRelabledDocumentConnection = GetApplication().signalRelabelDocument.connect(boost::bind(&Spreadsheet::Sheet::onRelabledDocument, this, bp::_1)); - } - - /** -diff --git a/src/Mod/Spreadsheet/Gui/SheetModel.cpp b/src/Mod/Spreadsheet/Gui/SheetModel.cpp -index 222d69475..7e17dacc9 100644 ---- a/src/Mod/Spreadsheet/Gui/SheetModel.cpp -+++ b/src/Mod/Spreadsheet/Gui/SheetModel.cpp -@@ -36,17 +36,18 @@ - #include - #include - #include --#include -+#include - - using namespace SpreadsheetGui; - using namespace Spreadsheet; - using namespace App; -+namespace bp = boost::placeholders; - - SheetModel::SheetModel(Sheet *_sheet, QObject *parent) - : QAbstractTableModel(parent) - , sheet(_sheet) - { -- cellUpdatedConnection = sheet->cellUpdated.connect(bind(&SheetModel::cellUpdated, this, _1)); -+ cellUpdatedConnection = sheet->cellUpdated.connect(bind(&SheetModel::cellUpdated, this, bp::_1)); - - ParameterGrp::handle hGrp = App::GetApplication().GetParameterGroupByPath("User parameter:BaseApp/Preferences/Mod/Spreadsheet"); - aliasBgColor = QColor(Base::Tools::fromStdString(hGrp->GetASCII("AliasedCellBackgroundColor", "#feff9e"))); -diff --git a/src/Mod/Spreadsheet/Gui/SheetTableView.cpp b/src/Mod/Spreadsheet/Gui/SheetTableView.cpp -index 5a3913234..31d008cc2 100644 ---- a/src/Mod/Spreadsheet/Gui/SheetTableView.cpp -+++ b/src/Mod/Spreadsheet/Gui/SheetTableView.cpp -@@ -29,7 +29,7 @@ - #endif - - #include --#include -+#include - #include "../App/Utils.h" - #include - #include "SheetTableView.h" -@@ -39,6 +39,7 @@ - using namespace SpreadsheetGui; - using namespace Spreadsheet; - using namespace App; -+namespace bp = boost::placeholders; - - void SheetViewHeader::mouseReleaseEvent(QMouseEvent *event) - { -@@ -253,7 +254,7 @@ void SheetTableView::updateCellSpan(CellAddress address) - void SheetTableView::setSheet(Sheet * _sheet) - { - sheet = _sheet; -- cellSpanChangedConnection = sheet->cellSpanChanged.connect(bind(&SheetTableView::updateCellSpan, this, _1)); -+ cellSpanChangedConnection = sheet->cellSpanChanged.connect(bind(&SheetTableView::updateCellSpan, this, bp::_1)); - - // Update row and column spans - std::vector usedCells = sheet->getUsedCells(); -diff --git a/src/Mod/Spreadsheet/Gui/SpreadsheetView.cpp b/src/Mod/Spreadsheet/Gui/SpreadsheetView.cpp -index 0aedaac9a..75e510fa0 100644 ---- a/src/Mod/Spreadsheet/Gui/SpreadsheetView.cpp -+++ b/src/Mod/Spreadsheet/Gui/SpreadsheetView.cpp -@@ -46,7 +46,7 @@ - #include - #include - #include --#include -+#include - #include - #include "qtcolorpicker.h" - #include -@@ -57,6 +57,7 @@ using namespace SpreadsheetGui; - using namespace Spreadsheet; - using namespace Gui; - using namespace App; -+namespace bp = boost::placeholders; - - /* TRANSLATOR SpreadsheetGui::SheetView */ - -@@ -96,8 +97,8 @@ SheetView::SheetView(Gui::Document *pcDocument, App::DocumentObject *docObj, QWi - - connect(ui->cellContent, SIGNAL(returnPressed()), this, SLOT( editingFinished() )); - -- columnWidthChangedConnection = sheet->columnWidthChanged.connect(bind(&SheetView::resizeColumn, this, _1, _2)); -- rowHeightChangedConnection = sheet->rowHeightChanged.connect(bind(&SheetView::resizeRow, this, _1, _2)); -+ columnWidthChangedConnection = sheet->columnWidthChanged.connect(bind(&SheetView::resizeColumn, this, bp::_1, bp::_2)); -+ rowHeightChangedConnection = sheet->rowHeightChanged.connect(bind(&SheetView::resizeRow, this, bp::_1, bp::_2)); - - connect( model, SIGNAL(dataChanged(const QModelIndex &, const QModelIndex &)), this, SLOT(modelUpdated(const QModelIndex &, const QModelIndex &))); - -diff --git a/src/Mod/TechDraw/Gui/MDIViewPage.cpp b/src/Mod/TechDraw/Gui/MDIViewPage.cpp -index 4cc1adf14..d44c71faf 100644 ---- a/src/Mod/TechDraw/Gui/MDIViewPage.cpp -+++ b/src/Mod/TechDraw/Gui/MDIViewPage.cpp -@@ -39,7 +39,7 @@ - #include - #include - #include -- #include -+ #include - - #endif // #ifndef _PreComp_ - -@@ -95,6 +95,7 @@ - - - using namespace TechDrawGui; -+namespace bp = boost::placeholders; - - /* TRANSLATOR TechDrawGui::MDIViewPage */ - -@@ -139,7 +140,7 @@ MDIViewPage::MDIViewPage(ViewProviderPage *pageVp, Gui::Document* doc, QWidget* - - //get informed by App side about deleted DocumentObjects - App::Document* appDoc = m_vpPage->getDocument()->getDocument(); -- auto bnd = boost::bind(&MDIViewPage::onDeleteObject, this, _1); -+ auto bnd = boost::bind(&MDIViewPage::onDeleteObject, this, bp::_1); - connectDeletedObject = appDoc->signalDeletedObject.connect(bnd); - - -diff --git a/src/Mod/TechDraw/Gui/ViewProviderDrawingView.cpp b/src/Mod/TechDraw/Gui/ViewProviderDrawingView.cpp -index 13385ba25..589a5933c 100644 ---- a/src/Mod/TechDraw/Gui/ViewProviderDrawingView.cpp -+++ b/src/Mod/TechDraw/Gui/ViewProviderDrawingView.cpp -@@ -27,7 +27,7 @@ - #ifndef _PreComp_ - #include - #include --#include -+#include - - #endif - -@@ -56,6 +56,7 @@ - #include "ViewProviderDrawingView.h" - - using namespace TechDrawGui; -+namespace bp = boost::placeholders; - - PROPERTY_SOURCE(TechDrawGui::ViewProviderDrawingView, Gui::ViewProviderDocumentObject) - -@@ -80,7 +81,7 @@ void ViewProviderDrawingView::attach(App::DocumentObject *pcFeat) - { - ViewProviderDocumentObject::attach(pcFeat); - -- auto bnd = boost::bind(&ViewProviderDrawingView::onGuiRepaint, this, _1); -+ auto bnd = boost::bind(&ViewProviderDrawingView::onGuiRepaint, this, bp::_1); - auto feature = getViewObject(); - if (feature != nullptr) { - connectGuiRepaint = feature->signalGuiPaint.connect(bnd); -diff --git a/src/Mod/TechDraw/Gui/ViewProviderPage.cpp b/src/Mod/TechDraw/Gui/ViewProviderPage.cpp -index b03a2159f..01c850645 100644 ---- a/src/Mod/TechDraw/Gui/ViewProviderPage.cpp -+++ b/src/Mod/TechDraw/Gui/ViewProviderPage.cpp -@@ -32,7 +32,7 @@ - #include - #include - #include --#include -+#include - - #endif - -@@ -60,6 +60,7 @@ - #include - - using namespace TechDrawGui; -+namespace bp = boost::placeholders; - - #define _SHOWDRAWING 10 - #define _TOGGLEUPDATE 11 -@@ -90,7 +91,7 @@ void ViewProviderPage::attach(App::DocumentObject *pcFeat) - { - ViewProviderDocumentObject::attach(pcFeat); - -- auto bnd = boost::bind(&ViewProviderPage::onGuiRepaint, this, _1); -+ auto bnd = boost::bind(&ViewProviderPage::onGuiRepaint, this, bp::_1); - auto feature = getDrawPage(); - if (feature != nullptr) { - connectGuiRepaint = feature->signalGuiPaint.connect(bnd); --- -2.29.2 - diff --git a/0001-fem-use-time.process_time-instead-of-removed-time.cl.patch b/0001-fem-use-time.process_time-instead-of-removed-time.cl.patch deleted file mode 100644 index 699f316..0000000 --- a/0001-fem-use-time.process_time-instead-of-removed-time.cl.patch +++ /dev/null @@ -1,86 +0,0 @@ -From 96af5fea1fab074e93011078974fd24fff1068f8 Mon Sep 17 00:00:00 2001 -From: looooo -Date: Tue, 14 Jan 2020 13:45:35 +0100 -Subject: [PATCH] fem: use time.process_time instead of removed time.clock() - -[rebased on 0.18.4 branch] ---- - src/Mod/Fem/femmesh/femmesh2mesh.py | 4 ++-- - src/Mod/Fem/femsolver/calculix/writer.py | 9 +++++++-- - src/Mod/Fem/femsolver/z88/writer.py | 8 ++++++-- - 3 files changed, 15 insertions(+), 6 deletions(-) - -diff --git a/src/Mod/Fem/femmesh/femmesh2mesh.py b/src/Mod/Fem/femmesh/femmesh2mesh.py -index 9c0b4f1b9..e6159f2c7 100644 ---- a/src/Mod/Fem/femmesh/femmesh2mesh.py -+++ b/src/Mod/Fem/femmesh/femmesh2mesh.py -@@ -90,7 +90,7 @@ def femmesh_2_mesh(myFemMesh, myResults=None): - # This code generates a dict and a faceCode for each face of all elements - # All faceCodes are than sorted. - -- start_time = time.clock() -+ start_time = time.process_time() - faceCodeList = [] - faceCodeDict = {} - -@@ -194,6 +194,6 @@ def femmesh_2_mesh(myFemMesh, myResults=None): - output_mesh.extend(triangle) - # print('my 2. triangle: ', triangle) - -- end_time = time.clock() -+ end_time = time.process_time() - print('Mesh by surface search method: ', end_time - start_time) - return output_mesh -diff --git a/src/Mod/Fem/femsolver/calculix/writer.py b/src/Mod/Fem/femsolver/calculix/writer.py -index e9d9e9bae..33302cefa 100644 ---- a/src/Mod/Fem/femsolver/calculix/writer.py -+++ b/src/Mod/Fem/femsolver/calculix/writer.py -@@ -69,12 +69,17 @@ class FemInputWriterCcx(FemInputWriter.FemInputWriter): - FreeCAD.Console.PrintMessage('FemInputWriterCcx --> self.file_name --> ' + self.file_name + '\n') - - def write_calculix_input_file(self): -- timestart = time.clock() -+ timestart = time.process_time() -+ FreeCAD.Console.PrintMessage("Start writing CalculiX input file\n") -+ FreeCAD.Console.PrintMessage("Write ccx input file to: {}\n".format(self.file_name)) - if self.solver_obj.SplitInputWriter is True: - self.write_calculix_splitted_input_file() - else: - self.write_calculix_one_input_file() -- writing_time_string = "Writing time input file: " + str(round((time.clock() - timestart), 2)) + " seconds" -+ writing_time_string = ( -+ "Writing time CalculiX input file: {} seconds" -+ .format(round((time.process_time() - timestart), 2)) -+ ) - if self.femelement_count_test is True: - FreeCAD.Console.PrintMessage(writing_time_string + ' \n\n') - return self.file_name -diff --git a/src/Mod/Fem/femsolver/z88/writer.py b/src/Mod/Fem/femsolver/z88/writer.py -index e141ab9f0..cdcaff63b 100644 ---- a/src/Mod/Fem/femsolver/z88/writer.py -+++ b/src/Mod/Fem/femsolver/z88/writer.py -@@ -61,7 +61,7 @@ class FemInputWriterZ88(FemInputWriter.FemInputWriter): - FreeCAD.Console.PrintMessage('FemInputWriterZ88 --> self.file_name --> ' + self.file_name + '\n') - - def write_z88_input(self): -- timestart = time.clock() -+ timestart = time.process_time() - if not self.femnodes_mesh: - self.femnodes_mesh = self.femmesh.Nodes - if not self.femelement_table: -@@ -76,7 +76,11 @@ class FemInputWriterZ88(FemInputWriter.FemInputWriter): - self.write_z88_integration_properties() - self.write_z88_memory_parameter() - self.write_z88_solver_parameter() -- FreeCAD.Console.PrintMessage("Writing time input file: " + str(time.clock() - timestart) + ' \n\n') -+ writing_time_string = ( -+ "Writing time input file: {} seconds" -+ .format(round((time.process_time() - timestart), 2)) -+ ) -+ FreeCAD.Console.PrintMessage(writing_time_string + " \n\n") - return self.dir_name - - def set_z88_elparam(self): --- -2.25.1 - diff --git a/0001-import-Hotfix-for-build-failure-from-bad-debug-code.patch b/0001-import-Hotfix-for-build-failure-from-bad-debug-code.patch deleted file mode 100644 index 8af2911..0000000 --- a/0001-import-Hotfix-for-build-failure-from-bad-debug-code.patch +++ /dev/null @@ -1,117 +0,0 @@ -From 063515f65007c116c4c0e05c1fcf82637b8bf152 Mon Sep 17 00:00:00 2001 -From: Gabriel Wicke -Date: Sun, 17 May 2020 21:09:19 -0700 -Subject: [PATCH] [import] Hotfix for build failure from bad debug code - -Quick fix for a build failure with latest opencascade. Directly use -std::cout instead of custom streams. ---- - src/Mod/Import/App/StepShape.cpp | 29 ++++++++++++----------------- - 1 file changed, 12 insertions(+), 17 deletions(-) - -diff --git a/src/Mod/Import/App/StepShape.cpp b/src/Mod/Import/App/StepShape.cpp -index acd4a9e706..ec714c891e 100644 ---- a/src/Mod/Import/App/StepShape.cpp -+++ b/src/Mod/Import/App/StepShape.cpp -@@ -65,38 +65,33 @@ int StepShape::read(const char* fileName) - throw Base::FileException("Cannot open STEP file"); - } - -- //Standard_Integer ic = Interface_Static::IVal("read.precision.mode"); -- //Standard_Real rp = Interface_Static::RVal("read.maxprecision.val"); -- //Standard_Integer ic = Interface_Static::IVal("read.maxprecision.mode"); -- //Standard_Integer mv = Interface_Static::IVal("read.stdsameparameter.mode"); -- //Standard_Integer rp = Interface_Static::IVal("read.surfacecurve.mode"); -- //Standard_Real era = Interface_Static::RVal("read.encoderegularity.angle"); -- //Standard_Integer ic = Interface_Static::IVal("read.step.product.mode"); -+ //Standard_Integer ic = Interface_Static::IVal("read.precision.mode"); -+ //Standard_Real rp = Interface_Static::RVal("read.maxprecision.val"); -+ //Standard_Integer ic = Interface_Static::IVal("read.maxprecision.mode"); -+ //Standard_Integer mv = Interface_Static::IVal("read.stdsameparameter.mode"); -+ //Standard_Integer rp = Interface_Static::IVal("read.surfacecurve.mode"); -+ //Standard_Real era = Interface_Static::RVal("read.encoderegularity.angle"); -+ //Standard_Integer ic = Interface_Static::IVal("read.step.product.mode"); - //Standard_Integer ic = Interface_Static::IVal("read.step.product.context"); -- //Standard_Integer ic = Interface_Static::IVal("read.step.shape.repr"); -+ //Standard_Integer ic = Interface_Static::IVal("read.step.shape.repr"); - //Standard_Integer ic = Interface_Static::IVal("read.step.assembly.level"); - //Standard_Integer ic = Interface_Static::IVal("read.step.shape.relationship"); -- //Standard_Integer ic = Interface_Static::IVal("read.step.shape.aspect"); -+ //Standard_Integer ic = Interface_Static::IVal("read.step.shape.aspect"); - -- Handle(TColStd_HSequenceOfTransient) list = aReader.GiveList(); -+ Handle(TColStd_HSequenceOfTransient) list = aReader.GiveList(); - - //Use method StepData_StepModel::NextNumberForLabel to find its rank with the following: - //Standard_CString label = "#..."; - Handle(StepData_StepModel) model = aReader.StepModel(); - //rank = model->NextNumberForLabe(label, 0, Standard_False); - -- Handle(Message_PrinterOStream) mstr = new Message_PrinterOStream(); -- Handle(Message_Messenger) msg = new Message_Messenger(mstr); -- - std::cout << "dump of step header:" << std::endl; -- -- model->DumpHeader(msg); -+ model->DumpHeader(std::cout); - - for(int nent=1;nent<=model->NbEntities();nent++) { - Handle(Standard_Transient) entity=model->Entity(nent); -- - std::cout << "label entity " << nent << ":" ; -- model->PrintLabel(entity,msg); -+ model->PrintLabel(entity, std::cout); - std::cout << ";"<< entity->DynamicType()->Name() << std::endl; - } - --- -2.30.1 - -From 2cb9b147f13419f019f9808ace21d3d2ceae99c5 Mon Sep 17 00:00:00 2001 -From: wmayer -Date: Sat, 30 May 2020 11:56:14 +0200 -Subject: [PATCH] Import: handle OCC versions 7.4.1 and earlier - ---- - src/Mod/Import/App/StepShape.cpp | 13 ++++++++++++- - 1 file changed, 12 insertions(+), 1 deletion(-) - -diff --git a/src/Mod/Import/App/StepShape.cpp b/src/Mod/Import/App/StepShape.cpp -index ec714c891e..a27ff781b6 100644 ---- a/src/Mod/Import/App/StepShape.cpp -+++ b/src/Mod/Import/App/StepShape.cpp -@@ -34,6 +34,7 @@ - # include - # include - # include -+# include - - # include - # include -@@ -86,12 +87,22 @@ int StepShape::read(const char* fileName) - //rank = model->NextNumberForLabe(label, 0, Standard_False); - - std::cout << "dump of step header:" << std::endl; -+#if OCC_VERSION_HEX < 0x070401 -+ Handle(Message_PrinterOStream) mstr = new Message_PrinterOStream(); -+ Handle(Message_Messenger) msg = new Message_Messenger(mstr); -+ model->DumpHeader(msg); -+#else - model->DumpHeader(std::cout); -+#endif - -- for(int nent=1;nent<=model->NbEntities();nent++) { -+ for (int nent=1;nent<=model->NbEntities();nent++) { - Handle(Standard_Transient) entity=model->Entity(nent); - std::cout << "label entity " << nent << ":" ; -+#if OCC_VERSION_HEX < 0x070401 -+ model->PrintLabel(entity, msg); -+#else - model->PrintLabel(entity, std::cout); -+#endif - std::cout << ";"<< entity->DynamicType()->Name() << std::endl; - } - --- -2.30.1 - diff --git a/0001-partdesign-fix-failing-tapered-hole-test.patch b/0001-partdesign-fix-failing-tapered-hole-test.patch deleted file mode 100644 index a432570..0000000 --- a/0001-partdesign-fix-failing-tapered-hole-test.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 8be2c08141f0275e9da005bd143771953e982a59 Mon Sep 17 00:00:00 2001 -From: lorenz -Date: Sun, 3 May 2020 07:47:27 +0200 -Subject: [PATCH] partdesign: fix failing tapered hole test - -The given parameters return an invalid shape. This fails with occt7.4 but doesn't with occt7.3. If the angle is 45 degree the cone is self-intersecting as Hole.Depth > Hole.Diameter/2. Changing the Hole.TaperedAngle to 60 degree solves this issue. ---- - src/Mod/PartDesign/PartDesignTests/TestHole.py | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/Mod/PartDesign/PartDesignTests/TestHole.py b/src/Mod/PartDesign/PartDesignTests/TestHole.py -index d84afd69ca..cc838f4a3b 100644 ---- a/src/Mod/PartDesign/PartDesignTests/TestHole.py -+++ b/src/Mod/PartDesign/PartDesignTests/TestHole.py -@@ -68,7 +68,7 @@ class TestHole(unittest.TestCase): - def testTaperedHole(self): - self.Hole.Diameter = 6 - self.Hole.Depth = 5 -- self.Hole.TaperedAngle = 45 -+ self.Hole.TaperedAngle = 60 - self.Hole.ThreadType = 0 - self.Hole.HoleCutType = 0 - self.Hole.DepthType = 0 --- -2.30.1 - diff --git a/0003-qt-5.14.patch b/0003-qt-5.14.patch deleted file mode 100644 index 915e7f1..0000000 --- a/0003-qt-5.14.patch +++ /dev/null @@ -1,77 +0,0 @@ -commit 17ed2b196a58afbbc3cc1bb99f6eb76060171ad2 -Author: howetuft -Date: Tue Dec 24 16:06:18 2019 +0100 - - [Cmake] Update FindPySide2Tools for PySide2 5.14 - issue #4229 - - Since PySide2 5.14, 'pyside2-rcc' and 'pyside2-uic' have been renamed into plain 'rcc' and 'uic'. - This leads FindPySide2Tools.cmake to no longer find rcc/uic, as reported in bug #4229 (https://www.freecadweb.org/tracker/view.php?id=4229) and prevents compilation. - FindPySide2Tools has been updated accordingly. - -diff --git a/cMake/FindPySide2Tools.cmake b/cMake/FindPySide2Tools.cmake -index 9c9751488..7ca9690dc 100644 ---- a/cMake/FindPySide2Tools.cmake -+++ b/cMake/FindPySide2Tools.cmake -@@ -20,8 +20,24 @@ if(WIN32 OR ${CMAKE_SYSTEM_NAME} MATCHES "Darwin") - set(PYSIDE_BIN_DIR ${PYTHON_BIN_DIR}) - endif(WIN32 OR ${CMAKE_SYSTEM_NAME} MATCHES "Darwin") - --FIND_PROGRAM(PYSIDE2UICBINARY NAMES python2-pyside2-uic pyside2-uic pyside2-uic-${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR} HINTS ${PYSIDE_BIN_DIR}) --FIND_PROGRAM(PYSIDE2RCCBINARY NAMES pyside2-rcc pyside2-rcc-${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR} HINTS ${PYSIDE_BIN_DIR}) -+# Since Qt v5.14, pyside2-uic and pyside2-rcc are directly provided by Qt5Core uic and rcc, with '-g python' option -+# We test Qt5Core version to act accordingly -+ -+FIND_PACKAGE(Qt5Core) -+ -+IF(Qt5Core_VERSION_STRING VERSION_GREATER_EQUAL 5.14) -+ # New (>= 5.14) -+ FIND_PROGRAM(PYSIDE2UICBINARY NAMES uic-qt5 uic) -+ set(UICOPTIONS "--generator=python") -+ FIND_PROGRAM(PYSIDE2RCCBINARY NAMES rcc-qt5 rcc) -+ set(RCCOPTIONS "--generator=python" "--compress-algo=zlib" "--compress=1") -+ELSE(Qt5Core_VERSION_STRING VERSION_LESS 5.14) -+ # Legacy (< 5.14) -+ FIND_PROGRAM(PYSIDE2UICBINARY NAMES python2-pyside2-uic pyside2-uic pyside2-uic-${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR} HINTS ${PYSIDE_BIN_DIR}) -+ FIND_PROGRAM(PYSIDE2RCCBINARY NAMES pyside2-rcc pyside2-rcc-${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR} HINTS ${PYSIDE_BIN_DIR}) -+ set(UICOPTIONS "") -+ set(RCCOPTIONS "") -+ENDIF(Qt5Core_VERSION_STRING VERSION_GREATER_EQUAL 5.14) - - MACRO(PYSIDE_WRAP_UI outfiles) - FOREACH(it ${ARGN}) -@@ -33,7 +49,7 @@ MACRO(PYSIDE_WRAP_UI outfiles) - #) - if(WIN32 OR APPLE) - ADD_CUSTOM_COMMAND(OUTPUT ${outfile} -- COMMAND ${PYSIDE2UICBINARY} ${infile} -o ${outfile} -+ COMMAND ${PYSIDE2UICBINARY} ${UICOPTIONS} ${infile} -o ${outfile} - MAIN_DEPENDENCY ${infile} - ) - else() -@@ -41,7 +57,7 @@ MACRO(PYSIDE_WRAP_UI outfiles) - # pyside2-uic generates in comments at beginning., which is why - # we follow the tool command with in-place sed. - ADD_CUSTOM_COMMAND(OUTPUT ${outfile} -- COMMAND "${PYSIDE2UICBINARY}" "${infile}" -o "${outfile}" -+ COMMAND "${PYSIDE2UICBINARY}" ${UICOPTIONS} "${infile}" -o "${outfile}" - COMMAND sed -i "/^# /d" "${outfile}" - MAIN_DEPENDENCY "${infile}" - ) -@@ -60,7 +76,7 @@ MACRO(PYSIDE_WRAP_RC outfiles) - #) - if(WIN32 OR APPLE) - ADD_CUSTOM_COMMAND(OUTPUT ${outfile} -- COMMAND ${PYSIDE2RCCBINARY} ${infile} -o ${outfile} -+ COMMAND ${PYSIDE2RCCBINARY} ${RCCOPTIONS} ${infile} -o ${outfile} - MAIN_DEPENDENCY ${infile} - ) - else() -@@ -68,7 +84,7 @@ MACRO(PYSIDE_WRAP_RC outfiles) - # pyside-rcc generates in comments at beginning, which is why - # we follow the tool command with in-place sed. - ADD_CUSTOM_COMMAND(OUTPUT "${outfile}" -- COMMAND "${PYSIDE2RCCBINARY}" "${infile}" ${PY_ATTRIBUTE} -o "${outfile}" -+ COMMAND "${PYSIDE2RCCBINARY}" ${RCCOPTIONS} "${infile}" ${PY_ATTRIBUTE} -o "${outfile}" - COMMAND sed -i "/^# /d" "${outfile}" - MAIN_DEPENDENCY "${infile}" - ) diff --git a/FreeCAD-0.18.5.obscpio b/FreeCAD-0.18.5.obscpio deleted file mode 100644 index 1eeb37a..0000000 --- a/FreeCAD-0.18.5.obscpio +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:53ffe7703d67b768fedb216bc9dfa6c0c79ca41acc94a1f7fedadf85e5fc75b4 -size 427464718 diff --git a/FreeCAD-0.18.5.tar.xz b/FreeCAD-0.18.5.tar.xz deleted file mode 100644 index c4a9f66..0000000 --- a/FreeCAD-0.18.5.tar.xz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:c173d76fe0737c7a9dd203205945c46c4113b5fec61b70dd22a58e683bad3633 -size 200710932 diff --git a/FreeCAD-0.19.1.tar.gz b/FreeCAD-0.19.1.tar.gz new file mode 100644 index 0000000..6d15d1e --- /dev/null +++ b/FreeCAD-0.19.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5ec0003c18df204f7b449d4ac0a82f945b41613a0264127de3ef16f6b2efa60f +size 296983463 diff --git a/FreeCAD-test.spec b/FreeCAD-test.spec index e8c6fa8..187bff5 100644 --- a/FreeCAD-test.spec +++ b/FreeCAD-test.spec @@ -17,7 +17,7 @@ Name: FreeCAD-test -Version: 0.18.5 +Version: 0.19.0 Release: 0 Summary: Meta source package that runs the FreeCAD testsuite when built License: LGPL-2.0-or-later AND GPL-2.0-or-later diff --git a/FreeCAD.changes b/FreeCAD.changes index c04f0ee..0862de7 100644 --- a/FreeCAD.changes +++ b/FreeCAD.changes @@ -1,3 +1,24 @@ +------------------------------------------------------------------- +Mon Mar 22 11:57:09 UTC 2021 - Stefan Brüns + +- Update to version 0.19.1: + * Lots of new features, bug fixes and improvements, see + https://wiki.freecadweb.org/Release_notes_0.19 +- Drop upstream patches: + * 0001-Fix-build-with-pyside2-shiboken2-5.12.1.patch + * 0003-qt-5.14.patch + * update-swigpyrunin-for-python-3.8.patch + * 0001-fem-use-time.process_time-instead-of-removed-time.cl.patch + * fix_qt_5.15_build.patch + * 0001-boost-1.73.0-The-practice-of-declaring-the-Bind-plac.patch + * 0001-Fix-ODR-violation-correct-Ui_TaskSketcherGeneral-nam.patch + * 0001-Gui-skip-ci-fix-Wodr.patch + * 0001-Part-Import-skip-ci-disable-use-of-Message_ProgressI.patch + * 0001-import-Hotfix-for-build-failure-from-bad-debug-code.patch + * 0001-partdesign-fix-failing-tapered-hole-test.patch + * 0001-add-missing-std-namespace-to-build-on-Debian-10.patch +- Rebase fix-smesh-vtk9.patch + ------------------------------------------------------------------- Tue Feb 23 19:05:09 UTC 2021 - Stefan Brüns diff --git a/FreeCAD.obsinfo b/FreeCAD.obsinfo deleted file mode 100644 index 76e1a63..0000000 --- a/FreeCAD.obsinfo +++ /dev/null @@ -1,5 +0,0 @@ -name: FreeCAD -version: 0.18.5 -mtime: 1603973581 -commit: 734202bc810bf61bd6f66bdc060e6951bd0d134d - diff --git a/FreeCAD.spec b/FreeCAD.spec index 23a3a97..dc6be76 100644 --- a/FreeCAD.spec +++ b/FreeCAD.spec @@ -23,45 +23,20 @@ %else %bcond_with boost_signals2 %endif -# Bundled SALOME-MESH (smesh) fails to build with VTK 9.0 -%bcond_without smesh +%bcond_with smesh_external Name: FreeCAD -Version: 0.18.5 +Version: 0.19.1 Release: 0 Summary: General Purpose 3D CAD Modeler License: LGPL-2.0-or-later AND GPL-2.0-or-later Group: Productivity/Graphics/CAD URL: https://www.freecadweb.org/ -Source0: %{name}-%version.tar.xz -# PATCH-FIX-UPSTREAM 0001-Fix-build-with-pyside2-shiboken2-5.12.1.patch -- Fix build with shiboken2/pyside2 >= 5.12.1 -Patch1: 0001-Fix-build-with-pyside2-shiboken2-5.12.1.patch -# PATCH-FIX-OPENSUSE qt-5.14.patch -Patch3: 0003-qt-5.14.patch -# PATCH-FIX-UPSTREAM https://github.com/FreeCAD/FreeCAD/commit/6eacb17b3e03d200.patch -Patch4: update-swigpyrunin-for-python-3.8.patch -# PATCH-FIX-UPSTREAM https://github.com/FreeCAD/FreeCAD/pull/2899 -Patch5: 0001-fem-use-time.process_time-instead-of-removed-time.cl.patch +Source0: https://github.com/FreeCAD/FreeCAD/archive/refs/tags/%{version}.tar.gz#/%{name}-%{version}.tar.gz # PATCH-FIX-OPENSUSE Use correct import for Python 3 tkinter -Patch6: fix_unittestgui_tkinter_py3.patch -# PATCH-FIX-UPSTREAM https://github.com/FreeCAD/FreeCAD/pull/3558 -Patch7: fix_qt_5.15_build.patch -# PATCH-FIX-UPSTREAM -- Rebased https://github.com/FreeCAD/FreeCAD/commit/4ec45b545ebf -Patch8: 0001-boost-1.73.0-The-practice-of-declaring-the-Bind-plac.patch +Patch1: fix_unittestgui_tkinter_py3.patch # PATCH-FIX-UPSTREAM Rebased https://github.com/wwmayer/FreeCAD/commit/bb9bcbd51df7 -Patch9: fix-smesh-vtk9.patch -# PATCH-FIX-UPSTREAM -Patch10: 0001-Fix-ODR-violation-correct-Ui_TaskSketcherGeneral-nam.patch -# PATCH-FIX-UPSTREAM -- https://github.com/FreeCAD/FreeCAD/commit/6bd39e8a90e65d81 -Patch11: 0001-Gui-skip-ci-fix-Wodr.patch -# PATCH-FIX-UPSTREAM -- Rebased https://github.com/FreeCAD/FreeCAD/commit/fd9cdb9de9d06ebd -Patch12: 0001-Part-Import-skip-ci-disable-use-of-Message_ProgressI.patch -# PATCH-FIX-UPSTREAM -- Rebased https://github.com/FreeCAD/FreeCAD/commit/063515f65007c116 -Patch13: 0001-import-Hotfix-for-build-failure-from-bad-debug-code.patch -# PATCH-FIX-UPSTREAM -- https://github.com/FreeCAD/FreeCAD/commit/50957037764de76b -Patch14: 0001-add-missing-std-namespace-to-build-on-Debian-10.patch -# PATCH-FIX-UPSTREAM -- https://github.com/FreeCAD/FreeCAD/commit/8be2c08141f0275e -Patch15: 0001-partdesign-fix-failing-tapered-hole-test.patch +Patch2: fix-smesh-vtk9.patch # Test suite fails on 32bit and I don't want to debug that anymore ExcludeArch: %ix86 %arm ppc s390 s390x @@ -74,6 +49,7 @@ BuildRequires: libboost_regex-devel >= 1.55 %if %{without boost_signals2} BuildRequires: libboost_signals-devel >= 1.55 %endif +BuildRequires: libboost_serialization-devel >= 1.55 BuildRequires: libboost_system-devel >= 1.55 BuildRequires: libboost_thread-devel >= 1.55 @@ -84,8 +60,10 @@ BuildRequires: fdupes BuildRequires: glew-devel BuildRequires: hdf5-devel BuildRequires: hicolor-icon-theme +%if %{with smesh_external} # We use the internal smesh version with fixes atm -#BuildRequires: smesh-devel +BuildRequires: smesh-devel +%endif BuildRequires: java-devel BuildRequires: libXerces-c-devel BuildRequires: libXi-devel @@ -93,13 +71,11 @@ BuildRequires: libmed-devel BuildRequires: libspnav-devel BuildRequires: make BuildRequires: netgen-devel -# we use upstream OpenCASCADE instead of oce-devel atm BuildRequires: occt-devel BuildRequires: pkg-config BuildRequires: proj-devel BuildRequires: sqlite3-devel -%if 0%{?suse_version} # Qt5 & python3 BuildRequires: python3-devel BuildRequires: python3-matplotlib @@ -117,32 +93,16 @@ BuildRequires: pkgconfig(Qt5UiTools) BuildRequires: pkgconfig(Qt5WebKit) BuildRequires: pkgconfig(Qt5WebKitWidgets) BuildRequires: pkgconfig(Qt5X11Extras) +BuildRequires: pkgconfig(Qt5XmlPatterns) Requires: python3-numpy Requires: python3-pyside2 Requires: python3-vtk # For Arch & Draft workbench Requires: python3-pivy # For FEM workbench +Requires: python3-PyYAML +Requires: python3-ply Requires: python3-six -# core dump if PySide (version 1) is installed -Conflicts: python3-pyside -Conflicts: python-pyside -# reported to break FreeCAD here -# https://forum.freecadweb.org/viewtopic.php?t=24610 -Conflicts: python-pivy -%endif -%if 0%{?fedora} > 18 -BuildRequires: libshiboken-devel -BuildRequires: python-CXX-devel -BuildRequires: python-devel -BuildRequires: python-matplotlib -BuildRequires: python-pyside-devel -BuildRequires: python-pyside-tools -BuildRequires: pkgconfig(QtWebKit) -Requires: python-numpy -Requires: python-pyside -BuildRequires: qt5-qtbase-devel -%endif BuildRequires: swig BuildRequires: update-desktop-files @@ -175,53 +135,66 @@ This package contains the files needed for development with FreeCAD. # fix env-script-interpreter sed -i '1c#!%{__python3}' \ + src/Mod/AddonManager/AddonManager.py \ + src/Mod/Mesh/App/MeshTestsApp.py \ + src/Mod/Robot/KukaExporter.py \ src/Mod/Robot/MovieTool.py \ + src/Mod/Spreadsheet/importXLSX.py \ + src/Mod/TechDraw/TDTest/D*Test.py \ src/Mod/Test/testmakeWireString.py # Fix "non-executable-script" rpmlint warning -chmod 755 src/Mod/Robot/MovieTool.py \ - src/Mod/Test/testmakeWireString.py \ - src/Mod/Test/unittestgui.py +chmod 755 src/Mod/AddonManager/AddonManager.py \ + src/Mod/Robot/KukaExporter.py \ + src/Mod/Robot/MovieTool.py \ + src/Mod/Spreadsheet/importXLSX.py \ + src/Mod/TechDraw/TDTest/D*Test.py \ + src/Mod/Test/testmakeWireString.py # Fix "wrong-script-end-of-line-encoding" rpmlint warning +sed -i 's/\r$//' src/Mod/Mesh/App/MeshTestsApp.py sed -i 's/\r$//' src/Mod/Part/MakeBottle.py sed -i 's/\r$//' src/Mod/PartDesign/Scripts/FilletArc.py sed -i 's/\r$//' src/Mod/PartDesign/Scripts/Parallelepiped.py sed -i 's/\r$//' src/Mod/PartDesign/Scripts/Spring.py sed -i 's/\r$//' src/Mod/Robot/MovieTool.py +sed -i 's/\r$//' src/Mod/Robot/KukaExporter.py sed -i 's/\r$//' src/Mod/Test/unittestgui.py # Remove 3rd party libs rm src/3rdparty/Pivy -fr rm src/3rdparty/Pivy-0.5 -fr +# Resources are looked up relative to the binaries location, +# so all these need the same prefix, see src/App/Application.cpp %build %cmake \ -DCMAKE_INSTALL_PREFIX=%{x_prefix} \ + -DCMAKE_INSTALL_LIBDIR=%{x_prefix}/lib \ + -DCMAKE_INSTALL_BINDIR=%{x_prefix}/bin \ + -DCMAKE_INSTALL_DATAROOTDIR=%{_datadir} \ -DCMAKE_INSTALL_DATADIR=%{_datadir}/%{name} \ -DCMAKE_INSTALL_DOCDIR=%{_docdir}/%{name} \ - -DCMAKE_INSTALL_LIBDIR=%{x_prefix}/lib \ -DCMAKE_INSTALL_INCLUDEDIR=%{_includedir}/%{name} \ -DCMAKE_SKIP_RPATH:BOOL=OFF \ -DCMAKE_INSTALL_RPATH_USE_LINK_PATH=ON \ -DOCC_INCLUDE_DIR=%{_includedir}/opencascade \ -DRESOURCEDIR=%{_datadir}/%{name} \ - -DCMAKE_CXX_FLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing" \ -DPYTHON_EXECUTABLE=/usr/bin/python3 \ -DSHIBOKEN_INCLUDE_DIR=/usr/include/shiboken2/ \ -DPYSIDE_INCLUDE_DIR=/usr/include/PySide2/ \ -DFREECAD_USE_PYBIND11:BOOL=ON \ -DBUILD_ENABLE_CXX_STD:STRING="C++17" \ -DBUILD_QT5=ON \ - -DFREECAD_USE_QT_DIALOG:BOOL=ON \ + -DFREECAD_USE_QT_DIALOG:BOOL=OFF \ -DFREECAD_USE_EXTERNAL_PIVY:BOOL=TRUE \ -DBUILD_OPENSCAD:BOOL=ON \ - -DFREECAD_USE_EXTERNAL_SMESH=OFF \ -DBUILD_FLAT_MESH:BOOL=ON \ - -DBUILD_SMESH:BOOL=%{?with_smesh:ON}%{!?with_smesh:OFF} \ - -DBUILD_MESH_PART:BOOL=%{?with_smesh:ON}%{!?with_smesh:OFF} \ + -DFREECAD_USE_EXTERNAL_SMESH=%{?with_smesh_external:ON}%{!?with_smesh_external:OFF} \ + -DBUILD_SMESH:BOOL=ON \ + -DBUILD_MESH_PART:BOOL=ON \ -DBUILD_FEM:BOOL=%{?with_smesh:ON}%{!?with_smesh:OFF} \ - -DBUILD_FEM_NETGEN:BOOL=OFF \ + -DBUILD_FEM_NETGEN:BOOL=ON \ -DBUILD_FEM_VTK:BOOL=ON \ -Wno-dev \ .. @@ -231,30 +204,13 @@ rm src/3rdparty/Pivy-0.5 -fr %install %cmake_install -# Move icons, mimeinfo, metainfo to the correct location -mv %{buildroot}%{x_prefix}/share/* %{buildroot}%{_datadir}/ -for size in 64 48 32 16; do - mkdir -p %{buildroot}%{_datadir}/icons/hicolor/${size}x${size}/apps - mv %{buildroot}%{_datadir}/%{name}/freecad-icon-${size}.png \ - %{buildroot}%{_datadir}/icons/hicolor/${size}x${size}/apps/org.freecadweb.FreeCAD.png -done -mkdir -p %{buildroot}%{_datadir}/icons/hicolor/64x64/mimetypes/ -# Install under the correct name according to FDO shared-mime-info-spec -mv %{buildroot}%{_datadir}/%{name}/freecad-doc.png %{buildroot}%{_datadir}/icons/hicolor/64x64/mimetypes/application-x-extension-fcstd.png -rm %{buildroot}%{_datadir}/%{name}/freecad.xpm -rm %{buildroot}%{_datadir}/%{name}/freecad.svg - %suse_update_desktop_file -r org.freecadweb.FreeCAD Education Engineering # Remove unneeded files find %{buildroot} -type f -name "*.la" -delete -print - -# Fix rpmlint warning "doc-file-dependency" -rm -f html/installdox - -# Install development documentation manually in order to fix rpmlint warning "files-duplicate" -mkdir -p %{buildroot}%{_docdir}/%{name}-devel -#cp -a html/ %%{buildroot}%%{_docdir}/%%{name}-devel/ +rm -Rf %{buildroot}%{_datadir}/pixmaps +# Broken +rm -Rf %{buildroot}%{_datadir}/thumbnailers # Link binaries mkdir -p %{buildroot}/usr/bin diff --git a/_constraints b/_constraints index 780cde6..9f6c4db 100644 --- a/_constraints +++ b/_constraints @@ -5,7 +5,7 @@ 14 - 5 + 6 diff --git a/fix-smesh-vtk9.patch b/fix-smesh-vtk9.patch index 2c664a0..f52ff43 100644 --- a/fix-smesh-vtk9.patch +++ b/fix-smesh-vtk9.patch @@ -813,28 +813,3 @@ index fcd044b00f2..f54c24f8618 100644 grid->GetCellPoints(vtkId, npts, pts); for (int i=0; iGetPoints(); - pntData = pd->GetPointData(); diff --git a/fix_qt_5.15_build.patch b/fix_qt_5.15_build.patch deleted file mode 100644 index 5bbf75e..0000000 --- a/fix_qt_5.15_build.patch +++ /dev/null @@ -1,21 +0,0 @@ -From b2882c699b1444efadd9faee36855a965ac6a215 Mon Sep 17 00:00:00 2001 -From: bartoszek -Date: Thu, 4 Jun 2020 14:10:08 +0200 -Subject: [PATCH] Fix qt5:5.15.0 build. - ---- - src/Mod/Image/Gui/OpenGLImageBox.cpp | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/src/Mod/Image/Gui/OpenGLImageBox.cpp b/src/Mod/Image/Gui/OpenGLImageBox.cpp -index 404a1a19f1b..bb22ae0f836 100644 ---- a/src/Mod/Image/Gui/OpenGLImageBox.cpp -+++ b/src/Mod/Image/Gui/OpenGLImageBox.cpp -@@ -26,6 +26,7 @@ - # include - # include - # include -+# include - #endif - - #if defined(__MINGW32__) diff --git a/update-swigpyrunin-for-python-3.8.patch b/update-swigpyrunin-for-python-3.8.patch deleted file mode 100644 index 5fae877..0000000 --- a/update-swigpyrunin-for-python-3.8.patch +++ /dev/null @@ -1,27 +0,0 @@ -From 6eacb17b3e03d20039b85c9daebab9e44386d6bf Mon Sep 17 00:00:00 2001 -From: Richard -Date: Thu, 17 Oct 2019 11:20:10 -0500 -Subject: [PATCH] Update swigpyrun.in for Python 3.8 - -In Python 3.8 some functions related to thread state were intentionally made private. - -This fix (specific to FreeCAD) was suggested here: - -https://bugs.python.org/issue35886 ---- - src/Base/swigpyrun.inl | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/Base/swigpyrun.inl b/src/Base/swigpyrun.inl -index 0eedaaa87a9..65bba62db3c 100644 ---- a/src/Base/swigpyrun.inl -+++ b/src/Base/swigpyrun.inl -@@ -72,7 +72,7 @@ void cleanupSWIG_T(const char* TypeName) - - PyObject *module, *dict; - PyInterpreterState *interp = PyThreadState_GET()->interp; -- PyObject *modules = interp->modules; -+ PyObject *modules = PyImport_GetModuleDict(); - module = PyDict_GetItemString(modules, "__builtin__"); - if (module != NULL && PyModule_Check(module)) { - dict = PyModule_GetDict(module);