diff --git a/src/Mod/Mesh/App/Core/Algorithm.cpp b/src/Mod/Mesh/App/Core/Algorithm.cpp index 23627423d2..8a5c6ec52c 100644 --- a/src/Mod/Mesh/App/Core/Algorithm.cpp +++ b/src/Mod/Mesh/App/Core/Algorithm.cpp @@ -1454,7 +1454,7 @@ bool MeshAlgorithm::CutWithPlane (const Base::Vector3f &clBase, const Base::Vect bool MeshAlgorithm::ConnectLines (std::list > &rclLines, std::list > &rclPolylines, float fMinEps) const { - typedef std::list >::iterator TCIter; + using TCIter = std::list >::iterator; // square search radius // const float fMinEps = 1.0e-2f; // := 10 micrometer distance @@ -1552,7 +1552,7 @@ bool MeshAlgorithm::ConnectLines (std::list >::iterator TPIter; + using TPIter = std::list >::iterator; std::list _clPolyToDelete; for (TPIter pJ = rclPolylines.begin(); pJ != rclPolylines.end(); ++pJ) { if (pJ->size() == 2) { // only one line segment diff --git a/src/Mod/Mesh/App/Core/Algorithm.h b/src/Mod/Mesh/App/Core/Algorithm.h index 32634c4ddb..8298cb612e 100644 --- a/src/Mod/Mesh/App/Core/Algorithm.h +++ b/src/Mod/Mesh/App/Core/Algorithm.h @@ -514,7 +514,7 @@ protected: return false; } }; - typedef std::pair MeshFacetPair; + using MeshFacetPair = std::pair; const MeshKernel &_rclMesh; /**< The mesh kernel. */ std::map _map; }; diff --git a/src/Mod/Mesh/App/Core/Approximation.h b/src/Mod/Mesh/App/Core/Approximation.h index ec2f2d34df..b295106e71 100644 --- a/src/Mod/Mesh/App/Core/Approximation.h +++ b/src/Mod/Mesh/App/Core/Approximation.h @@ -492,7 +492,7 @@ public: /** * WildMagic library uses function with this interface */ - typedef double (*Function)(double,double,double); + using Function = double (*)(double,double,double); /** * The constructor expects an array of quadric coefficients. * @param pKoef Pointer to the quadric coefficients diff --git a/src/Mod/Mesh/App/Core/Builder.cpp b/src/Mod/Mesh/App/Core/Builder.cpp index 7400299541..814b91236b 100644 --- a/src/Mod/Mesh/App/Core/Builder.cpp +++ b/src/Mod/Mesh/App/Core/Builder.cpp @@ -328,7 +328,7 @@ void MeshFastBuilder::AddFacet (const MeshGeomFacet& facetPoints) void MeshFastBuilder::Finish () { - typedef QVector::size_type size_type; + using size_type = QVector::size_type; QVector& verts = p->verts; size_type ulCtPts = verts.size(); for (size_type i=0; i < ulCtPts; ++i) { diff --git a/src/Mod/Mesh/App/Core/Builder.h b/src/Mod/Mesh/App/Core/Builder.h index e71f8da5f2..fc8b3aeb6e 100644 --- a/src/Mod/Mesh/App/Core/Builder.h +++ b/src/Mod/Mesh/App/Core/Builder.h @@ -105,7 +105,7 @@ private: Base::SequencerLauncher* _seq; // keep an array of iterators pointing to the vertex inside the set to save memory - typedef std::pair::iterator, bool> MeshPointIterator; + using MeshPointIterator = std::pair::iterator, bool>; std::vector _pointsIterator; size_t _ptIdx; @@ -189,7 +189,7 @@ private: MeshKernel& _meshKernel; public: - typedef int size_type; + using size_type = int; explicit MeshFastBuilder(MeshKernel &rclM); ~MeshFastBuilder(); diff --git a/src/Mod/Mesh/App/Core/CylinderFit.h b/src/Mod/Mesh/App/Core/CylinderFit.h index ac69574289..b10c2471fb 100644 --- a/src/Mod/Mesh/App/Core/CylinderFit.h +++ b/src/Mod/Mesh/App/Core/CylinderFit.h @@ -30,7 +30,7 @@ // ------------------------------------------------------------------------------- namespace MeshCoreFit { -typedef Eigen::Matrix Matrix5x5; +using Matrix5x5 = Eigen::Matrix; /** * Best-fit cylinder for a given set of points. diff --git a/src/Mod/Mesh/App/Core/Definitions.h b/src/Mod/Mesh/App/Core/Definitions.h index 4745a015da..645b745fd2 100644 --- a/src/Mod/Mesh/App/Core/Definitions.h +++ b/src/Mod/Mesh/App/Core/Definitions.h @@ -71,8 +71,8 @@ public: MeshExport static const Prec PI; }; -typedef Math Mathf; -typedef Math Mathd; +using Mathf = Math; +using Mathd = Math; /** * Global defined tolerances used to compare points diff --git a/src/Mod/Mesh/App/Core/Degeneration.cpp b/src/Mod/Mesh/App/Core/Degeneration.cpp index beec10f200..09106a50bc 100644 --- a/src/Mod/Mesh/App/Core/Degeneration.cpp +++ b/src/Mod/Mesh/App/Core/Degeneration.cpp @@ -95,7 +95,7 @@ bool MeshFixInvalids::Fixup() namespace MeshCore { -typedef MeshPointArray::_TConstIterator VertexIterator; +using VertexIterator = MeshPointArray::_TConstIterator; /* * When building up a mesh then usually the class MeshBuilder is used. This * class uses internally a std::set which uses the '<' operator of @@ -271,7 +271,7 @@ bool MeshFixNaNPoints::Fixup() namespace MeshCore { -typedef MeshFacetArray::_TConstIterator FaceIterator; +using FaceIterator = MeshFacetArray::_TConstIterator; /* * The facet with the lowset index is regarded as 'less'. */ @@ -509,8 +509,8 @@ bool MeshFixDegeneratedFacets::Fixup() bool MeshRemoveNeedles::Fixup() { - typedef std::pair FaceEdge; // (face, edge) pair - typedef std::pair FaceEdgePriority; + using FaceEdge = std::pair; // (face, edge) pair + using FaceEdgePriority = std::pair; MeshTopoAlgorithm topAlg(_rclMesh); MeshRefPointToFacets vf_it(_rclMesh); @@ -609,8 +609,8 @@ bool MeshRemoveNeedles::Fixup() bool MeshFixCaps::Fixup() { - typedef std::pair FaceVertex; // (face, vertex) pair - typedef std::pair FaceVertexPriority; + using FaceVertex = std::pair; // (face, vertex) pair + using FaceVertexPriority = std::pair; MeshTopoAlgorithm topAlg(_rclMesh); const MeshFacetArray &rclFAry = _rclMesh.GetFacets(); diff --git a/src/Mod/Mesh/App/Core/Elements.h b/src/Mod/Mesh/App/Core/Elements.h index 0dd476e1b9..083801b693 100644 --- a/src/Mod/Mesh/App/Core/Elements.h +++ b/src/Mod/Mesh/App/Core/Elements.h @@ -69,7 +69,7 @@ public: }; /** MeshEdge just a pair of two point indices */ -typedef std::pair MeshEdge; +using MeshEdge = std::pair; struct MeshExport EdgeCollapse { @@ -567,7 +567,7 @@ public: unsigned long _ulProp; /**< Free usable property. */ }; -typedef std::vector TMeshPointArray; +using TMeshPointArray = std::vector; /** * Stores all data points of the mesh structure. */ @@ -575,8 +575,8 @@ class MeshExport MeshPointArray: public TMeshPointArray { public: // Iterator interface - typedef std::vector::iterator _TIterator; - typedef std::vector::const_iterator _TConstIterator; + using _TIterator = std::vector::iterator; + using _TConstIterator = std::vector::const_iterator; /** @name Construction */ //@{ @@ -620,7 +620,7 @@ public: PointIndex GetOrAddIndex (const MeshPoint &rclPoint); }; -typedef std::vector TMeshFacetArray; +using TMeshFacetArray = std::vector; /** * Stores all facets of the mesh data-structure. @@ -629,8 +629,8 @@ class MeshExport MeshFacetArray: public TMeshFacetArray { public: // Iterator interface - typedef std::vector::iterator _TIterator; - typedef std::vector::const_iterator _TConstIterator; + using _TIterator = std::vector::iterator; + using _TConstIterator = std::vector::const_iterator; /** @name Construction */ //@{ @@ -1118,9 +1118,9 @@ template class MeshIsFlag { public: - typedef TCLASS first_argument_type; - typedef typename TCLASS::TFlagType second_argument_type; - typedef bool result_type; + using first_argument_type = TCLASS; + using second_argument_type = typename TCLASS::TFlagType; + using result_type = bool; bool operator () (const TCLASS& rclElem, typename TCLASS::TFlagType tFlag) const { return rclElem.IsFlag(tFlag); } }; @@ -1132,9 +1132,9 @@ template class MeshIsNotFlag { public: - typedef TCLASS first_argument_type; - typedef typename TCLASS::TFlagType second_argument_type; - typedef bool result_type; + using first_argument_type = TCLASS; + using second_argument_type = typename TCLASS::TFlagType; + using result_type = bool; bool operator () (const TCLASS& rclElem, typename TCLASS::TFlagType tFlag) const { return !rclElem.IsFlag(tFlag); } }; @@ -1146,9 +1146,9 @@ template class MeshSetFlag { public: - typedef TCLASS first_argument_type; - typedef typename TCLASS::TFlagType second_argument_type; - typedef bool result_type; + using first_argument_type = TCLASS; + using second_argument_type = typename TCLASS::TFlagType; + using result_type = bool; bool operator () (const TCLASS& rclElem, typename TCLASS::TFlagType tFlag) const { rclElem.SetFlag(tFlag); return true; } }; @@ -1160,9 +1160,9 @@ template class MeshResetFlag { public: - typedef TCLASS first_argument_type; - typedef typename TCLASS::TFlagType second_argument_type; - typedef bool result_type; + using first_argument_type = TCLASS; + using second_argument_type = typename TCLASS::TFlagType; + using result_type = bool; bool operator () (const TCLASS& rclElem, typename TCLASS::TFlagType tFlag) const { rclElem.ResetFlag(tFlag); return true; } }; diff --git a/src/Mod/Mesh/App/Core/Helpers.h b/src/Mod/Mesh/App/Core/Helpers.h index a5c844e9c1..e007e12f32 100644 --- a/src/Mod/Mesh/App/Core/Helpers.h +++ b/src/Mod/Mesh/App/Core/Helpers.h @@ -89,7 +89,7 @@ struct MeshExport MeshHelpBuilderEdge */ struct MeshEdgeBuilder: public std::vector { - typedef std::vector::iterator _TIterator; + using _TIterator = std::vector::iterator; inline void Add (PointIndex ulInd1, PointIndex ulInd2, FacetIndex ulSide, FacetIndex ulFInd); }; diff --git a/src/Mod/Mesh/App/Core/KDTree.cpp b/src/Mod/Mesh/App/Core/KDTree.cpp index a0be600239..07da35e920 100644 --- a/src/Mod/Mesh/App/Core/KDTree.cpp +++ b/src/Mod/Mesh/App/Core/KDTree.cpp @@ -35,7 +35,7 @@ using namespace MeshCore; struct Point3d { - typedef float value_type; + using value_type = float; Point3d(const Base::Vector3f& f, PointIndex i) : p(f), i(i) { @@ -84,7 +84,7 @@ struct Point3d PointIndex i; }; -typedef KDTree::KDTree<3, Point3d> MyKDTree; +using MyKDTree = KDTree::KDTree<3, Point3d>; class MeshKDTree::Private { diff --git a/src/Mod/Mesh/App/Core/MeshIO.cpp b/src/Mod/Mesh/App/Core/MeshIO.cpp index b75777f418..549f919cad 100644 --- a/src/Mod/Mesh/App/Core/MeshIO.cpp +++ b/src/Mod/Mesh/App/Core/MeshIO.cpp @@ -787,9 +787,9 @@ namespace MeshCore { }; struct Property { - typedef std::pair first_argument_type; - typedef std::string second_argument_type; - typedef bool result_type; + using first_argument_type = std::pair; + using second_argument_type = std::string; + using result_type = bool; bool operator()(const std::pair& x, const std::string& y) const diff --git a/src/Mod/Mesh/App/Core/Segmentation.h b/src/Mod/Mesh/App/Core/Segmentation.h index de3237502e..ef6252b0b7 100644 --- a/src/Mod/Mesh/App/Core/Segmentation.h +++ b/src/Mod/Mesh/App/Core/Segmentation.h @@ -35,7 +35,7 @@ class PlaneFit; class CylinderFit; class SphereFit; class MeshFacet; -typedef std::vector MeshSegment; +using MeshSegment = std::vector; class MeshExport MeshSurfaceSegment { @@ -56,7 +56,7 @@ protected: std::vector segments; unsigned long minFacets; }; -typedef std::shared_ptr MeshSurfaceSegmentPtr; +using MeshSurfaceSegmentPtr = std::shared_ptr; // -------------------------------------------------------- diff --git a/src/Mod/Mesh/App/Core/Simplify.h b/src/Mod/Mesh/App/Core/Simplify.h index 0502376a8c..74b511db05 100644 --- a/src/Mod/Mesh/App/Core/Simplify.h +++ b/src/Mod/Mesh/App/Core/Simplify.h @@ -17,7 +17,7 @@ #define _USE_MATH_DEFINES #endif -typedef Base::Vector3f vec3f; +using vec3f = Base::Vector3f; class SymmetricMatrix { diff --git a/src/Mod/Mesh/App/Core/SphereFit.h b/src/Mod/Mesh/App/Core/SphereFit.h index 2064849f7e..fbea8c6e98 100644 --- a/src/Mod/Mesh/App/Core/SphereFit.h +++ b/src/Mod/Mesh/App/Core/SphereFit.h @@ -30,7 +30,7 @@ // ------------------------------------------------------------------------------- namespace MeshCoreFit { -typedef Eigen::Matrix Matrix4x4; +using Matrix4x4 = Eigen::Matrix; /** * Best-fit sphere for a given set of points. diff --git a/src/Mod/Mesh/App/Core/TopoAlgorithm.cpp b/src/Mod/Mesh/App/Core/TopoAlgorithm.cpp index 87b0207913..3c8f05586a 100644 --- a/src/Mod/Mesh/App/Core/TopoAlgorithm.cpp +++ b/src/Mod/Mesh/App/Core/TopoAlgorithm.cpp @@ -287,8 +287,8 @@ float MeshTopoAlgorithm::SwapEdgeBenefit(FacetIndex f, int e) const vertices[v1], vertices[v4]); } -typedef std::pair FaceEdge; // (face, edge) pair -typedef std::pair FaceEdgePriority; +using FaceEdge = std::pair; // (face, edge) pair +using FaceEdgePriority = std::pair; void MeshTopoAlgorithm::OptimizeTopology() { diff --git a/src/Mod/Mesh/App/Core/TopoAlgorithm.h b/src/Mod/Mesh/App/Core/TopoAlgorithm.h index 153dca1ecf..1359c3ff42 100644 --- a/src/Mod/Mesh/App/Core/TopoAlgorithm.h +++ b/src/Mod/Mesh/App/Core/TopoAlgorithm.h @@ -321,7 +321,7 @@ private: }; // cache - typedef std::map tCache; + using tCache = std::map; tCache* _cache; }; diff --git a/src/Mod/Mesh/App/Core/Utilities.h b/src/Mod/Mesh/App/Core/Utilities.h index 84804b2208..712ffeb6a6 100644 --- a/src/Mod/Mesh/App/Core/Utilities.h +++ b/src/Mod/Mesh/App/Core/Utilities.h @@ -31,8 +31,8 @@ namespace Base { // Specialization for Wm4::Vector3d template <> struct vec_traits { - typedef Wm4::Vector3d vec_type; - typedef double float_type; + using vec_type = Wm4::Vector3d; + using float_type = double; explicit vec_traits(const vec_type& v) : v(v){} inline std::tuple get() const { return std::make_tuple(v.X(), v.Y(), v.Z()); @@ -43,8 +43,8 @@ private: // Specialization for Wm4::Vector3f template <> struct vec_traits { - typedef Wm4::Vector3f vec_type; - typedef float float_type; + using vec_type = Wm4::Vector3f; + using float_type = float; explicit vec_traits(const vec_type& v) : v(v){} inline std::tuple get() const { return std::make_tuple(v.X(), v.Y(), v.Z()); diff --git a/src/Mod/Mesh/App/Mesh.h b/src/Mod/Mesh/App/Mesh.h index 9f72e2f540..38f30fe6b4 100644 --- a/src/Mod/Mesh/App/Mesh.h +++ b/src/Mod/Mesh/App/Mesh.h @@ -91,7 +91,7 @@ public: using TFacePair = std::pair; using TFacePairs = std::vector; - // typedef needed for cross-section + // type def needed for cross-section using TPlane = std::pair; using TPolylines = std::list>; using TRay = std::pair; @@ -406,7 +406,7 @@ public: const_facet_iterator facets_end() const { return const_facet_iterator(this, countFacets()); } - typedef std::vector::const_iterator const_segment_iterator; + using const_segment_iterator = std::vector::const_iterator; const_segment_iterator segments_begin() const { return _segments.begin(); } const_segment_iterator segments_end() const diff --git a/src/Mod/Mesh/App/MeshFeature.h b/src/Mod/Mesh/App/MeshFeature.h index e3c02a0ce1..33278447ce 100644 --- a/src/Mod/Mesh/App/MeshFeature.h +++ b/src/Mod/Mesh/App/MeshFeature.h @@ -85,8 +85,8 @@ public: PyObject* getPyObject() override; }; -typedef App::FeatureCustomT FeatureCustom; -typedef App::FeaturePythonT FeaturePython; +using FeatureCustom = App::FeatureCustomT; +using FeaturePython = App::FeaturePythonT; } //namespace Mesh diff --git a/src/Mod/Mesh/Gui/MeshEditor.h b/src/Mod/Mesh/Gui/MeshEditor.h index f102014b8b..3867fd034a 100644 --- a/src/Mod/Mesh/Gui/MeshEditor.h +++ b/src/Mod/Mesh/Gui/MeshEditor.h @@ -138,8 +138,8 @@ private Q_SLOTS: void closeBridge(); private: - typedef std::vector TBoundary; - typedef boost::signals2::connection Connection; + using TBoundary = std::vector; + using Connection = boost::signals2::connection; static void fileHoleCallback(void * ud, SoEventCallback * n); void createPolygons(); diff --git a/src/Mod/Mesh/Gui/SegmentationBestFit.h b/src/Mod/Mesh/Gui/SegmentationBestFit.h index 9a09fcbe04..abca9a7fa9 100644 --- a/src/Mod/Mesh/Gui/SegmentationBestFit.h +++ b/src/Mod/Mesh/Gui/SegmentationBestFit.h @@ -49,7 +49,7 @@ public: virtual std::vector getParameter(Points) const = 0; }; -typedef std::list > ParameterList; +using ParameterList = std::list >; class ParametersDialog : public QDialog { Q_OBJECT diff --git a/src/Mod/Mesh/Gui/SoFCIndexedFaceSet.h b/src/Mod/Mesh/Gui/SoFCIndexedFaceSet.h index 2164a865c7..e8eea9142b 100644 --- a/src/Mod/Mesh/Gui/SoFCIndexedFaceSet.h +++ b/src/Mod/Mesh/Gui/SoFCIndexedFaceSet.h @@ -35,9 +35,9 @@ class SoGLCoordinateElement; class SoTextureCoordinateBundle; -typedef unsigned int GLuint; -typedef int GLint; -typedef float GLfloat; +using GLuint = unsigned int; +using GLint = int; +using GLfloat = float; namespace MeshGui { @@ -93,7 +93,7 @@ private: * @author Werner Mayer */ class MeshGuiExport SoFCIndexedFaceSet : public SoIndexedFaceSet { - typedef SoIndexedFaceSet inherited; + using inherited = SoIndexedFaceSet; SO_NODE_HEADER(SoFCIndexedFaceSet); diff --git a/src/Mod/Mesh/Gui/SoFCMeshFaceSet.h b/src/Mod/Mesh/Gui/SoFCMeshFaceSet.h index c2faa41829..a418231b93 100644 --- a/src/Mod/Mesh/Gui/SoFCMeshFaceSet.h +++ b/src/Mod/Mesh/Gui/SoFCMeshFaceSet.h @@ -43,9 +43,9 @@ class Feature; namespace MeshGui { class MeshGuiExport SoSFMeshFacetArray : public SoSField { - typedef SoSField inherited; + using inherited = SoSField; - SO_SFIELD_HEADER(SoSFMeshFacetArray, MeshCore::MeshFacetArray*, MeshCore::MeshFacetArray*); + SO_SFIELD_HEADER(SoSFMeshFacetArray, MeshCore::MeshFacetArray*, MeshCore::MeshFacetArray*) public: static void initClass(void); @@ -62,7 +62,7 @@ protected: // ------------------------------------------------------- class MeshGuiExport SoFCMeshFacetElement : public SoReplacedElement { - typedef SoReplacedElement inherited; + using inherited = SoReplacedElement; SO_ELEMENT_HEADER(SoFCMeshFacetElement); @@ -83,7 +83,7 @@ protected: // ------------------------------------------------------- class MeshGuiExport SoFCMeshFacet : public SoNode { - typedef SoSField inherited; + using inherited = SoSField; SO_NODE_HEADER(SoFCMeshFacet); @@ -119,7 +119,7 @@ protected: * @author Werner Mayer */ class MeshGuiExport SoFCMeshFaceSet : public SoShape { - typedef SoShape inherited; + using inherited = SoShape; SO_NODE_HEADER(SoFCMeshFaceSet); @@ -141,19 +141,19 @@ protected: const SoPrimitiveVertex * v3, SoPickedPoint * pp); -private: - enum Binding { - OVERALL = 0, - PER_FACE_INDEXED, - PER_VERTEX_INDEXED, - NONE = OVERALL - }; +private: + enum Binding { + OVERALL = 0, + PER_FACE_INDEXED, + PER_VERTEX_INDEXED, + NONE = OVERALL + }; private: // Force using the reference count mechanism. - virtual ~SoFCMeshFaceSet() {}; + virtual ~SoFCMeshFaceSet() {} virtual void notify(SoNotList * list); - Binding findMaterialBinding(SoState * const state) const; + Binding findMaterialBinding(SoState * const state) const; // Draw faces void drawFaces(const MeshCore::MeshPointArray *, const MeshCore::MeshFacetArray*, SoMaterialBundle* mb, Binding bind, SbBool needNormals, SbBool ccw) const; @@ -170,7 +170,7 @@ private: // ------------------------------------------------------------ class MeshGuiExport SoFCMeshOpenEdgeSet : public SoShape { - typedef SoShape inherited; + using inherited = SoShape; SO_NODE_HEADER(SoFCMeshOpenEdgeSet); @@ -185,7 +185,7 @@ protected: virtual void generatePrimitives(SoAction *action); private: // Force using the reference count mechanism. - virtual ~SoFCMeshOpenEdgeSet() {}; + virtual ~SoFCMeshOpenEdgeSet() {} void drawLines(const MeshCore::MeshPointArray *, const MeshCore::MeshFacetArray*) const ; }; diff --git a/src/Mod/Mesh/Gui/SoFCMeshNode.h b/src/Mod/Mesh/Gui/SoFCMeshNode.h index 7ae4b580f5..b4c57d8904 100644 --- a/src/Mod/Mesh/Gui/SoFCMeshNode.h +++ b/src/Mod/Mesh/Gui/SoFCMeshNode.h @@ -35,7 +35,7 @@ class MeshObject; namespace MeshGui { class MeshGuiExport SoFCMeshNode : public SoShape { - typedef SoShape inherited; + using inherited = SoShape; SO_NODE_HEADER(SoFCMeshNode); @@ -62,7 +62,7 @@ protected: private: // Force using the reference count mechanism. - virtual ~SoFCMeshNode() {}; + virtual ~SoFCMeshNode() {} virtual void notify(SoNotList * list); // Draw faces void drawFaces(SbBool needNormals) const; @@ -80,7 +80,7 @@ private: // ------------------------------------------------------------ class MeshGuiExport SoFCMeshOpenEdge : public SoShape { - typedef SoShape inherited; + using inherited = SoShape; SO_NODE_HEADER(SoFCMeshOpenEdge); @@ -96,7 +96,7 @@ protected: virtual void generatePrimitives(SoAction *action); private: // Force using the reference count mechanism. - virtual ~SoFCMeshOpenEdge() {}; + virtual ~SoFCMeshOpenEdge() {} void drawLines() const ; private: diff --git a/src/Mod/Mesh/Gui/SoFCMeshObject.h b/src/Mod/Mesh/Gui/SoFCMeshObject.h index a6e64594ab..7da9e6e91f 100644 --- a/src/Mod/Mesh/Gui/SoFCMeshObject.h +++ b/src/Mod/Mesh/Gui/SoFCMeshObject.h @@ -34,16 +34,16 @@ #include #include -typedef unsigned int GLuint; -typedef int GLint; -typedef float GLfloat; +using GLuint = unsigned int; +using GLint = int; +using GLfloat = float; namespace MeshCore { class MeshFacetGrid; } namespace MeshGui { class MeshGuiExport SoSFMeshObject : public SoSField { - typedef SoSField inherited; + using inherited = SoSField; SO_SFIELD_HEADER(SoSFMeshObject, Base::Reference, Base::Reference) @@ -57,7 +57,7 @@ private: // ------------------------------------------------------- class MeshGuiExport SoFCMeshObjectElement : public SoReplacedElement { - typedef SoReplacedElement inherited; + using inherited = SoReplacedElement; SO_ELEMENT_HEADER(SoFCMeshObjectElement); @@ -78,7 +78,7 @@ protected: // ------------------------------------------------------- class MeshGuiExport SoFCMeshPickNode : public SoNode { - typedef SoNode inherited; + using inherited = SoNode; SO_NODE_HEADER(SoFCMeshPickNode); @@ -102,7 +102,7 @@ private: // ------------------------------------------------------- class MeshGuiExport SoFCMeshGridNode : public SoNode { - typedef SoNode inherited; + using inherited = SoNode; SO_NODE_HEADER(SoFCMeshGridNode); @@ -122,7 +122,7 @@ protected: // ------------------------------------------------------- class MeshGuiExport SoFCMeshObjectNode : public SoNode { - typedef SoNode inherited; + using inherited = SoNode; SO_NODE_HEADER(SoFCMeshObjectNode); @@ -164,7 +164,7 @@ protected: * @author Werner Mayer */ class MeshGuiExport SoFCMeshObjectShape : public SoShape { - typedef SoShape inherited; + using inherited = SoShape; SO_NODE_HEADER(SoFCMeshObjectShape); @@ -225,7 +225,7 @@ private: }; class MeshGuiExport SoFCMeshSegmentShape : public SoShape { - typedef SoShape inherited; + using inherited = SoShape; SO_NODE_HEADER(SoFCMeshSegmentShape); @@ -252,7 +252,7 @@ private: private: // Force using the reference count mechanism. - ~SoFCMeshSegmentShape() override {}; + ~SoFCMeshSegmentShape() override {} Binding findMaterialBinding(SoState * const state) const; // Draw faces void drawFaces(const Mesh::MeshObject *, SoMaterialBundle* mb, Binding bind, @@ -261,7 +261,7 @@ private: }; class MeshGuiExport SoFCMeshObjectBoundary : public SoShape { - typedef SoShape inherited; + using inherited = SoShape; SO_NODE_HEADER(SoFCMeshObjectBoundary); @@ -276,7 +276,7 @@ protected: void generatePrimitives(SoAction *action) override; private: // Force using the reference count mechanism. - ~SoFCMeshObjectBoundary() override {}; + ~SoFCMeshObjectBoundary() override {} void drawLines(const Mesh::MeshObject *) const ; }; diff --git a/src/Mod/Mesh/Gui/SoFCMeshVertex.h b/src/Mod/Mesh/Gui/SoFCMeshVertex.h index f7eb5137f3..ace1fd975e 100644 --- a/src/Mod/Mesh/Gui/SoFCMeshVertex.h +++ b/src/Mod/Mesh/Gui/SoFCMeshVertex.h @@ -32,9 +32,9 @@ namespace MeshGui { class MeshGuiExport SoSFMeshPointArray : public SoSField { - typedef SoSField inherited; + using inherited = SoSField; - SO_SFIELD_HEADER(SoSFMeshPointArray, MeshCore::MeshPointArray*, MeshCore::MeshPointArray*); + SO_SFIELD_HEADER(SoSFMeshPointArray, MeshCore::MeshPointArray*, MeshCore::MeshPointArray*) public: static void initClass(void); @@ -51,7 +51,7 @@ protected: // ------------------------------------------------------- class MeshGuiExport SoFCMeshVertexElement : public SoReplacedElement { - typedef SoReplacedElement inherited; + using inherited = SoReplacedElement; SO_ELEMENT_HEADER(SoFCMeshVertexElement); @@ -72,7 +72,7 @@ protected: // ------------------------------------------------------- class MeshGuiExport SoFCMeshVertex : public SoNode { - typedef SoSField inherited; + using inherited = SoSField; SO_NODE_HEADER(SoFCMeshVertex); diff --git a/src/Mod/Mesh/Gui/SoPolygon.h b/src/Mod/Mesh/Gui/SoPolygon.h index ecde6b3919..bd842cccf2 100644 --- a/src/Mod/Mesh/Gui/SoPolygon.h +++ b/src/Mod/Mesh/Gui/SoPolygon.h @@ -37,7 +37,7 @@ namespace MeshGui { class MeshGuiExport SoPolygon : public SoShape { - typedef SoShape inherited; + using inherited = SoShape; SO_NODE_HEADER(SoPolygon); diff --git a/src/Mod/Mesh/Gui/ViewProviderCurvature.h b/src/Mod/Mesh/Gui/ViewProviderCurvature.h index 1e1112fc2d..2262924d6b 100644 --- a/src/Mod/Mesh/Gui/ViewProviderCurvature.h +++ b/src/Mod/Mesh/Gui/ViewProviderCurvature.h @@ -58,7 +58,7 @@ namespace MeshGui { class MeshGuiExport ViewProviderMeshCurvature : public Gui::ViewProviderDocumentObject, public App::DocumentObserver, public Base::Observer { - typedef Gui::ViewProviderDocumentObject inherited; + using inherited = Gui::ViewProviderDocumentObject; PROPERTY_HEADER_WITH_OVERRIDE(MeshGui::ViewProviderMeshCurvature); diff --git a/src/Mod/Mesh/Gui/ViewProviderPython.h b/src/Mod/Mesh/Gui/ViewProviderPython.h index 8f4942a05b..663c0972bb 100644 --- a/src/Mod/Mesh/Gui/ViewProviderPython.h +++ b/src/Mod/Mesh/Gui/ViewProviderPython.h @@ -29,7 +29,7 @@ namespace MeshGui { -typedef Gui::ViewProviderPythonFeatureT ViewProviderPython; +using ViewProviderPython = Gui::ViewProviderPythonFeatureT; } // namespace MeshGui