From a05843fc36da04880c9c3438967241872d17e2e4 Mon Sep 17 00:00:00 2001
From: Dmitri Naumov <github@naumov.de>
Date: Sat, 15 Apr 2017 16:34:38 +0200
Subject: [PATCH] Use nullptr instead of 0 and NULL.

---
 .../DataExplorer/Base/CheckboxDelegate.h      |  2 +-
 .../Base/ColorPickerPushButton.cpp            |  2 +-
 .../DataExplorer/Base/ColorPickerPushButton.h |  2 +-
 .../Base/QNonScalableGraphicsTextItem.h       |  5 +-
 .../DataExplorer/Base/QValueTooltipSlider.h   |  2 +-
 .../DataExplorer/Base/StrictIntValidator.h    |  4 +-
 Applications/DataExplorer/Base/TreeItem.cpp   |  4 +-
 Applications/DataExplorer/Base/TreeModel.cpp  |  4 +-
 Applications/DataExplorer/Base/TreeModel.h    |  2 +-
 .../DataExplorer/Base/TreeModelIterator.cpp   |  8 ++--
 .../DataExplorer/Base/TreeModelIterator.h     |  2 +-
 Applications/DataExplorer/DataView/BaseItem.h |  3 +-
 .../DataExplorer/DataView/ColorTableModel.h   |  5 +-
 .../DataExplorer/DataView/ColorTableView.h    |  5 +-
 .../DataView/CondFromRasterDialog.cpp         |  2 +-
 .../DataView/CondFromRasterDialog.h           |  3 +-
 .../DataView/CreateStructuredGridDialog.h     |  2 +-
 .../DataView/DataExplorerSettingsDialog.h     |  2 +-
 .../DataView/DiagramView/DetailWindow.h       |  8 ++--
 .../DataView/DiagramView/DiagramList.cpp      |  6 ++-
 .../DiagramView/DiagramPrefsDialog.cpp        |  4 +-
 .../DataView/DiagramView/DiagramPrefsDialog.h | 14 +++---
 .../DataView/DiagramView/DiagramScene.cpp     |  2 +-
 .../DataView/DiagramView/DiagramScene.h       |  4 +-
 .../DataView/DiagramView/DiagramView.h        |  4 +-
 .../DataView/DiagramView/QArrow.h             |  5 +-
 .../DataView/DiagramView/QGraphicsGrid.h      | 11 +++--
 .../DataExplorer/DataView/ElementTreeModel.h  |  2 +-
 .../DataExplorer/DataView/ElementTreeView.cpp |  3 +-
 .../DataExplorer/DataView/ElementTreeView.h   |  2 +-
 .../DataExplorer/DataView/GeoObjectListItem.h | 24 ++++++----
 .../DataView/GeoOnMeshMappingDialog.h         |  2 +-
 .../DataExplorer/DataView/GeoTabWidget.h      |  2 +-
 .../DataExplorer/DataView/GeoTreeItem.h       |  7 ++-
 .../DataExplorer/DataView/GeoTreeModel.cpp    | 10 ++--
 .../DataExplorer/DataView/GeoTreeModel.h      |  2 +-
 .../DataExplorer/DataView/GeoTreeView.cpp     |  9 ++--
 .../DataExplorer/DataView/GeoTreeView.h       |  2 +-
 .../DataExplorer/DataView/LicenseDialog.h     |  2 +-
 .../DataExplorer/DataView/LineEditDialog.cpp  |  3 +-
 .../DataExplorer/DataView/LineEditDialog.h    |  3 +-
 .../DataExplorer/DataView/LinearEditDialog.h  |  5 +-
 .../DataView/MergeGeometriesDialog.h          |  3 +-
 .../DataView/MeshElementRemovalDialog.h       |  3 +-
 .../DataView/MeshLayerEditDialog.h            |  2 +-
 .../DataView/MeshQualitySelectionDialog.h     |  2 +-
 .../DataView/MeshValueEditDialog.h            |  2 +-
 .../DataExplorer/DataView/ModelTreeItem.cpp   |  4 +-
 .../DataExplorer/DataView/ModelTreeItem.h     |  3 +-
 .../DataView/ModellingTabWidget.h             |  2 +-
 .../DataExplorer/DataView/MshEditDialog.cpp   | 26 ++++++-----
 Applications/DataExplorer/DataView/MshModel.h |  2 +-
 .../DataExplorer/DataView/MshTabWidget.h      |  2 +-
 Applications/DataExplorer/DataView/MshView.h  |  2 +-
 .../DataView/NetCdfConfigureDialog.cpp        |  2 +-
 .../DataView/NetCdfConfigureDialog.h          |  3 +-
 .../DataExplorer/DataView/SaveMeshDialog.h    |  2 +-
 .../DataExplorer/DataView/SelectMeshDialog.h  |  4 +-
 .../DataExplorer/DataView/SetNameDialog.h     |  3 +-
 .../DataExplorer/DataView/StationTabWidget.h  |  2 +-
 .../DataExplorer/DataView/StationTreeModel.h  |  2 +-
 .../DataExplorer/DataView/StationTreeView.h   |  2 +-
 .../DataView/StratView/StratBar.h             |  2 +-
 .../DataView/StratView/StratScene.h           |  7 +--
 .../DataView/StratView/StratView.h            |  2 +-
 .../DataView/StratView/StratWindow.h          |  7 +--
 .../DataView/SurfaceExtractionDialog.h        |  2 +-
 .../VtkVis/MeshFromRasterDialog.h             |  2 +-
 .../DataExplorer/VtkVis/QVtkDataSetMapper.cpp |  3 +-
 .../DataExplorer/VtkVis/VisualizationWidget.h |  2 +-
 .../VtkVis/VtkAlgorithmProperties.h           |  2 +-
 .../VtkVis/VtkAlgorithmPropertyCheckbox.h     |  3 +-
 .../VtkVis/VtkAlgorithmPropertyLineEdit.h     |  2 +-
 .../VtkVis/VtkAlgorithmPropertyVectorEdit.h   |  2 +-
 .../VtkCompositeColormapToImageFilter.cpp     |  2 +-
 .../VtkCompositeElementSelectionFilter.cpp    |  2 +-
 .../VtkVis/VtkCompositeGeoObjectFilter.cpp    |  6 +--
 .../VtkCompositeTextureOnSurfaceFilter.cpp    |  4 +-
 .../DataExplorer/VtkVis/VtkFilterFactory.cpp  |  4 +-
 .../DataExplorer/VtkVis/VtkGeoImageSource.cpp |  2 +-
 .../DataExplorer/VtkVis/VtkPointsSource.cpp   |  3 +-
 .../VtkVis/VtkPolylinesSource.cpp             |  3 +-
 .../DataExplorer/VtkVis/VtkRaster.cpp         |  2 +-
 .../DataExplorer/VtkVis/VtkStationSource.cpp  |  3 +-
 .../DataExplorer/VtkVis/VtkSurfacesSource.cpp |  3 +-
 .../DataExplorer/VtkVis/VtkVisImageItem.cpp   | 17 +++----
 .../DataExplorer/VtkVis/VtkVisPipeline.cpp    |  9 ++--
 .../DataExplorer/VtkVis/VtkVisPipeline.h      |  4 +-
 .../VtkVis/VtkVisPipelineItem.cpp             | 28 +++++++----
 .../VtkVis/VtkVisPipelineView.cpp             | 23 +++++-----
 .../DataExplorer/VtkVis/VtkVisPipelineView.h  |  2 +-
 .../DataExplorer/VtkVis/VtkVisTabWidget.cpp   |  4 +-
 .../DataExplorer/VtkVis/VtkVisTabWidget.h     |  2 +-
 Applications/DataExplorer/main.cpp            |  4 +-
 Applications/DataExplorer/mainwindow.cpp      |  5 +-
 Applications/DataExplorer/mainwindow.h        |  2 +-
 Applications/FileIO/AsciiRasterInterface.cpp  | 19 +++++---
 Applications/FileIO/GMSInterface.cpp          | 24 +++++-----
 .../FileIO/Gmsh/GMSHAdaptiveMeshDensity.cpp   | 12 +++--
 Applications/FileIO/Gmsh/GMSHPolygonTree.cpp  |  3 +-
 Applications/FileIO/SHPInterface.cpp          |  4 +-
 BaseLib/RunTime.h                             |  4 +-
 GeoLib/IO/Legacy/OGSIOVer4.cpp                |  6 +--
 GeoLib/IO/XmlIO/Qt/XmlGmlInterface.cpp        |  6 +--
 GeoLib/IO/XmlIO/Qt/XmlStnInterface.cpp        | 42 +++++++++++------
 GeoLib/IO/XmlIO/Rapid/RapidStnInterface.cpp   | 46 ++++++++++++-------
 GeoLib/SensorData.cpp                         |  3 +-
 GeoLib/StationBorehole.cpp                    |  9 ++--
 MeshLib/Elements/Element.h                    |  2 +-
 MeshLib/IO/Legacy/MeshIO.cpp                  |  2 +-
 .../VtkMeshNodalCoordinatesTemplate-impl.h    | 12 ++---
 Tests/MeshLib/TestMoveMeshNodes.cpp           |  2 +-
 112 files changed, 357 insertions(+), 277 deletions(-)

diff --git a/Applications/DataExplorer/Base/CheckboxDelegate.h b/Applications/DataExplorer/Base/CheckboxDelegate.h
index 0e82581b7c8..2e4d8cd4be7 100644
--- a/Applications/DataExplorer/Base/CheckboxDelegate.h
+++ b/Applications/DataExplorer/Base/CheckboxDelegate.h
@@ -31,7 +31,7 @@ class CheckboxDelegate : public QItemDelegate
 
 public:
     /// \brief Constructor
-    CheckboxDelegate (QObject* parent = 0);
+    CheckboxDelegate(QObject* parent = nullptr);
 
     /// \brief Paints a checkbox. This overrides the default painting of a combo box.
     void paint(QPainter* painter, const QStyleOptionViewItem& option,
diff --git a/Applications/DataExplorer/Base/ColorPickerPushButton.cpp b/Applications/DataExplorer/Base/ColorPickerPushButton.cpp
index d66c2e4142b..980e05a6fa7 100644
--- a/Applications/DataExplorer/Base/ColorPickerPushButton.cpp
+++ b/Applications/DataExplorer/Base/ColorPickerPushButton.cpp
@@ -27,7 +27,7 @@ ColorPickerPushButton::ColorPickerPushButton( QWidget* parent /*= 0*/ )
 void ColorPickerPushButton::mouseReleaseEvent(QMouseEvent* e)
 {
     Q_UNUSED(e);
-    QColor newColor = QColorDialog::getColor(_color, NULL, "Choose a color");
+    QColor newColor = QColorDialog::getColor(_color, nullptr, "Choose a color");
     if (!newColor.isValid())
         return;
 
diff --git a/Applications/DataExplorer/Base/ColorPickerPushButton.h b/Applications/DataExplorer/Base/ColorPickerPushButton.h
index 5596d767fc7..3cb466406e7 100644
--- a/Applications/DataExplorer/Base/ColorPickerPushButton.h
+++ b/Applications/DataExplorer/Base/ColorPickerPushButton.h
@@ -30,7 +30,7 @@ class ColorPickerPushButton : public QPushButton
     Q_OBJECT
 
 public:
-    ColorPickerPushButton(QWidget* parent = 0);
+    ColorPickerPushButton(QWidget* parent = nullptr);
 
 public slots:
     /// Calls the QColorDialog
diff --git a/Applications/DataExplorer/Base/QNonScalableGraphicsTextItem.h b/Applications/DataExplorer/Base/QNonScalableGraphicsTextItem.h
index ce9d3677f00..2db5bdb0fbd 100644
--- a/Applications/DataExplorer/Base/QNonScalableGraphicsTextItem.h
+++ b/Applications/DataExplorer/Base/QNonScalableGraphicsTextItem.h
@@ -24,8 +24,9 @@
 class QNonScalableGraphicsTextItem : public QGraphicsTextItem
 {
 public:
-    QNonScalableGraphicsTextItem(QGraphicsItem* parent = 0);
-    QNonScalableGraphicsTextItem(const QString &text, QGraphicsItem* parent = 0);
+    QNonScalableGraphicsTextItem(QGraphicsItem* parent = nullptr);
+    QNonScalableGraphicsTextItem(const QString& text,
+                                 QGraphicsItem* parent = nullptr);
     ~QNonScalableGraphicsTextItem();
 
     void paint(QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget);
diff --git a/Applications/DataExplorer/Base/QValueTooltipSlider.h b/Applications/DataExplorer/Base/QValueTooltipSlider.h
index bdd247503c4..5b07d677659 100644
--- a/Applications/DataExplorer/Base/QValueTooltipSlider.h
+++ b/Applications/DataExplorer/Base/QValueTooltipSlider.h
@@ -23,7 +23,7 @@ class QValueTooltipSlider : public QSlider
     Q_OBJECT
 
 public:
-    QValueTooltipSlider(QWidget* parent = 0);
+    QValueTooltipSlider(QWidget* parent = nullptr);
 
 public slots:
     void setTooltipValue(int value);
diff --git a/Applications/DataExplorer/Base/StrictIntValidator.h b/Applications/DataExplorer/Base/StrictIntValidator.h
index bb1ba32ab52..677fea754fa 100644
--- a/Applications/DataExplorer/Base/StrictIntValidator.h
+++ b/Applications/DataExplorer/Base/StrictIntValidator.h
@@ -23,8 +23,8 @@
 class StrictIntValidator : public QIntValidator
 {
 public:
-    StrictIntValidator ( int min, int max, QObject* parent = 0) :
-        QIntValidator( min, max, parent)
+    StrictIntValidator(int min, int max, QObject* parent = nullptr)
+        : QIntValidator(min, max, parent)
     {}
 
     QValidator::State validate(QString & input, int &pos) const
diff --git a/Applications/DataExplorer/Base/TreeItem.cpp b/Applications/DataExplorer/Base/TreeItem.cpp
index b0efd8b7e49..bbb88c8ba2a 100644
--- a/Applications/DataExplorer/Base/TreeItem.cpp
+++ b/Applications/DataExplorer/Base/TreeItem.cpp
@@ -45,14 +45,14 @@ void TreeItem::appendChild(TreeItem* item)
 /**
  * Returns the child that corresponds to the specified row number
  * in the item's list of child items
- * Returns NULL if that child does not exist.
+ * Returns nullptr if that child does not exist.
  */
 TreeItem* TreeItem::child(int row) const
 {
     if (_childItems.count() > row)
         return _childItems.value(row);
     else
-        return NULL;
+        return nullptr;
 }
 
 /**
diff --git a/Applications/DataExplorer/Base/TreeModel.cpp b/Applications/DataExplorer/Base/TreeModel.cpp
index 1e41dc09147..2791690d995 100644
--- a/Applications/DataExplorer/Base/TreeModel.cpp
+++ b/Applications/DataExplorer/Base/TreeModel.cpp
@@ -29,7 +29,7 @@ TreeModel::TreeModel( QObject* parent )
     //_modelType = TREE_MODEL;
     QList<QVariant> rootData;
     rootData << "1" << "2" << "3";
-    _rootItem = new TreeItem(rootData, NULL);
+    _rootItem = new TreeItem(rootData, nullptr);
     //setupModelData(data, _rootItem);
 }
 
@@ -151,7 +151,7 @@ bool TreeModel::setData( const QModelIndex &index, const QVariant &value, int ro
 Qt::ItemFlags TreeModel::flags(const QModelIndex &index) const
 {
     if (!index.isValid())
-        return 0;
+        return nullptr;
 
     return Qt::ItemIsEnabled | Qt::ItemIsSelectable;
 }
diff --git a/Applications/DataExplorer/Base/TreeModel.h b/Applications/DataExplorer/Base/TreeModel.h
index 1323babbc78..94ce0218234 100644
--- a/Applications/DataExplorer/Base/TreeModel.h
+++ b/Applications/DataExplorer/Base/TreeModel.h
@@ -31,7 +31,7 @@ class TreeModel : public QAbstractItemModel
     Q_OBJECT
 
 public:
-    TreeModel(QObject* parent = 0);
+    TreeModel(QObject* parent = nullptr);
     virtual ~TreeModel();
 
     QVariant data(const QModelIndex &index, int role) const;
diff --git a/Applications/DataExplorer/Base/TreeModelIterator.cpp b/Applications/DataExplorer/Base/TreeModelIterator.cpp
index 050c85ae058..1335f54acd4 100644
--- a/Applications/DataExplorer/Base/TreeModelIterator.cpp
+++ b/Applications/DataExplorer/Base/TreeModelIterator.cpp
@@ -18,8 +18,8 @@
 #include "TreeItem.h"
 #include "TreeModel.h"
 
-TreeModelIterator::TreeModelIterator( TreeModel* model )
-    : _current(NULL), _model(model)
+TreeModelIterator::TreeModelIterator(TreeModel* model)
+    : _current(nullptr), _model(model)
 {
     if (_model->rootItem()->childCount() > 0)
     {
@@ -46,9 +46,9 @@ TreeModelIterator& TreeModelIterator::operator++()
 TreeItem* TreeModelIterator::next( const TreeItem* current )
 {
     if (!current)
-        return NULL;
+        return nullptr;
 
-    TreeItem* next = NULL;
+    TreeItem* next = nullptr;
     if (current->childCount())
     {
         // walk the child
diff --git a/Applications/DataExplorer/Base/TreeModelIterator.h b/Applications/DataExplorer/Base/TreeModelIterator.h
index 7ed76018637..c040a811fc9 100644
--- a/Applications/DataExplorer/Base/TreeModelIterator.h
+++ b/Applications/DataExplorer/Base/TreeModelIterator.h
@@ -38,7 +38,7 @@ public:
     TreeModelIterator(TreeModel* model);
 
     /// \brief Dereferencing the iterator to retrieve the current TreeItem.
-    /// Returns NULL if the iterator is at the end.
+    /// Returns nullptr if the iterator is at the end.
     TreeItem* operator* () const;
 
     /// \brief Advance the iterator to the next TreeItem.
diff --git a/Applications/DataExplorer/DataView/BaseItem.h b/Applications/DataExplorer/DataView/BaseItem.h
index b5f897282b8..c2e1a34401d 100644
--- a/Applications/DataExplorer/DataView/BaseItem.h
+++ b/Applications/DataExplorer/DataView/BaseItem.h
@@ -28,7 +28,8 @@
 class BaseItem
 {
 public:
-    BaseItem(const QString &listName, const std::vector<GeoLib::Point*>* stations = NULL )
+    BaseItem(const QString& listName,
+             const std::vector<GeoLib::Point*>* stations = nullptr)
         : _stations(stations), _vtkSource(VtkStationSource::New())
     {
         // create the vtk-object for 3d-visualisation of this list
diff --git a/Applications/DataExplorer/DataView/ColorTableModel.h b/Applications/DataExplorer/DataView/ColorTableModel.h
index 97a94ac11d0..d8e69a8e097 100644
--- a/Applications/DataExplorer/DataView/ColorTableModel.h
+++ b/Applications/DataExplorer/DataView/ColorTableModel.h
@@ -27,8 +27,9 @@ class ColorTableModel : public QAbstractTableModel
     Q_OBJECT
 
 public:
-    ColorTableModel( const std::map<std::string, DataHolderLib::Color*> &colorLookupTable,
-                     QObject* parent = 0 );
+    ColorTableModel(
+        const std::map<std::string, DataHolderLib::Color*>& colorLookupTable,
+        QObject* parent = nullptr);
     ~ColorTableModel();
 
     int columnCount(const QModelIndex& parent = QModelIndex()) const;
diff --git a/Applications/DataExplorer/DataView/ColorTableView.h b/Applications/DataExplorer/DataView/ColorTableView.h
index 3892db6945c..47ae8b2b7dc 100644
--- a/Applications/DataExplorer/DataView/ColorTableView.h
+++ b/Applications/DataExplorer/DataView/ColorTableView.h
@@ -25,7 +25,7 @@ class ColorTableView : public QTableView
 
 public:
     /// Constructor
-    ColorTableView(QWidget* parent = 0);
+    ColorTableView(QWidget* parent = nullptr);
 };
 
 /**
@@ -37,8 +37,7 @@ class ColorTableViewDelegate : public QItemDelegate
 
 public:
     /// Constructor
-    ColorTableViewDelegate(QWidget* parent = 0) : QItemDelegate(parent) {}
-
+    ColorTableViewDelegate(QWidget* parent = nullptr) : QItemDelegate(parent) {}
     /// Overwrites the paint-method to set user-defined properties instead of the default properties.
     void paint(QPainter* painter, const QStyleOptionViewItem &option,
                const QModelIndex &index) const;
diff --git a/Applications/DataExplorer/DataView/CondFromRasterDialog.cpp b/Applications/DataExplorer/DataView/CondFromRasterDialog.cpp
index 66679ef301e..fb824f12065 100644
--- a/Applications/DataExplorer/DataView/CondFromRasterDialog.cpp
+++ b/Applications/DataExplorer/DataView/CondFromRasterDialog.cpp
@@ -83,7 +83,7 @@ void CondFromRasterDialog::accept()
         return;
     }
 
-    MeshLib::Mesh* mesh (NULL);
+    MeshLib::Mesh* mesh(nullptr);
     for (std::size_t i=0; i<_msh_vec.size(); i++)
         if (_msh_vec[i]->getName().compare(mesh_name) == 0)
         {
diff --git a/Applications/DataExplorer/DataView/CondFromRasterDialog.h b/Applications/DataExplorer/DataView/CondFromRasterDialog.h
index 4be6b081793..ecf00fef0f5 100644
--- a/Applications/DataExplorer/DataView/CondFromRasterDialog.h
+++ b/Applications/DataExplorer/DataView/CondFromRasterDialog.h
@@ -31,7 +31,8 @@ class CondFromRasterDialog : public QDialog, private Ui_CondFromRaster
     Q_OBJECT
 
 public:
-    CondFromRasterDialog(const std::vector<MeshLib::Mesh*> &msh_vec, QDialog* parent = 0);
+    CondFromRasterDialog(const std::vector<MeshLib::Mesh*>& msh_vec,
+                         QDialog* parent = nullptr);
     ~CondFromRasterDialog(void);
 
 private:
diff --git a/Applications/DataExplorer/DataView/CreateStructuredGridDialog.h b/Applications/DataExplorer/DataView/CreateStructuredGridDialog.h
index 29b9ae6cfd8..89f061a014a 100644
--- a/Applications/DataExplorer/DataView/CreateStructuredGridDialog.h
+++ b/Applications/DataExplorer/DataView/CreateStructuredGridDialog.h
@@ -27,7 +27,7 @@ class CreateStructuredGridDialog : public QDialog, private Ui_CreateStructuredGr
     Q_OBJECT
 
 public:
-    CreateStructuredGridDialog(QDialog* parent = 0);
+    CreateStructuredGridDialog(QDialog* parent = nullptr);
 
 private slots:
     void on_lineButton_toggled()  const;
diff --git a/Applications/DataExplorer/DataView/DataExplorerSettingsDialog.h b/Applications/DataExplorer/DataView/DataExplorerSettingsDialog.h
index ed40b7a5dc9..7fcc38b4e1d 100644
--- a/Applications/DataExplorer/DataView/DataExplorerSettingsDialog.h
+++ b/Applications/DataExplorer/DataView/DataExplorerSettingsDialog.h
@@ -25,7 +25,7 @@ class DataExplorerSettingsDialog : public QDialog, private Ui_DataExplorerSettin
     Q_OBJECT
 
 public:
-    DataExplorerSettingsDialog(QDialog* parent = 0);
+    DataExplorerSettingsDialog(QDialog* parent = nullptr);
     ~DataExplorerSettingsDialog(void);
 
 
diff --git a/Applications/DataExplorer/DataView/DiagramView/DetailWindow.h b/Applications/DataExplorer/DataView/DiagramView/DetailWindow.h
index 48f1c55414b..c5dcb6ac8c7 100644
--- a/Applications/DataExplorer/DataView/DiagramView/DetailWindow.h
+++ b/Applications/DataExplorer/DataView/DiagramView/DetailWindow.h
@@ -27,22 +27,22 @@ class DetailWindow : public QWidget, private Ui_DetailWindow
 
 public:
     /// Creates an empty diagram window.
-    DetailWindow(QWidget* parent = 0);
+    DetailWindow(QWidget* parent = nullptr);
     /**
      * Creates a window containing a diagram.
      * \param filename ASCII file containing x and y values for the graph to be displayed.
      * \param parent The parent QWidget.
      */
-    DetailWindow(QString filename, QWidget* parent = 0);
+    DetailWindow(QString filename, QWidget* parent = nullptr);
 
     /**
      * Creates a window containing a diagram
      * \param list A QDiagramList containing all the data points and necessary metainformation for a graph to be displayed
      * \param parent The parent QWidget.
      */
-    DetailWindow(DiagramList* list, QWidget* parent = 0);
+    DetailWindow(DiagramList* list, QWidget* parent = nullptr);
 
-    DetailWindow(std::vector<std::size_t> data, QWidget* parent = 0);
+    DetailWindow(std::vector<std::size_t> data, QWidget* parent = nullptr);
 
     ~DetailWindow(void);
 
diff --git a/Applications/DataExplorer/DataView/DiagramView/DiagramList.cpp b/Applications/DataExplorer/DataView/DiagramView/DiagramList.cpp
index c6621a8504e..7739ccff7c7 100644
--- a/Applications/DataExplorer/DataView/DiagramView/DiagramList.cpp
+++ b/Applications/DataExplorer/DataView/DiagramView/DiagramList.cpp
@@ -200,7 +200,11 @@ int DiagramList::readList(const QString &path, std::vector<DiagramList*> &lists)
 
                 for (int i = 0; i < nLists; i++)
                 {
-                    value = strtod(BaseLib::replaceString(",", ".",fields.takeFirst().toStdString()).c_str(),0);
+                    value =
+                        strtod(BaseLib::replaceString(
+                                   ",", ".", fields.takeFirst().toStdString())
+                                   .c_str(),
+                               nullptr);
                     lists[i]->addNextPoint(numberOfSecs,value);
                 }
             }
diff --git a/Applications/DataExplorer/DataView/DiagramView/DiagramPrefsDialog.cpp b/Applications/DataExplorer/DataView/DiagramView/DiagramPrefsDialog.cpp
index d59280d6f2b..4269f58b5ae 100644
--- a/Applications/DataExplorer/DataView/DiagramView/DiagramPrefsDialog.cpp
+++ b/Applications/DataExplorer/DataView/DiagramView/DiagramPrefsDialog.cpp
@@ -74,7 +74,7 @@ void DiagramPrefsDialog::accept()
         if (_list[0]->size() > 0)
         {
             bool window_is_empty(false);
-            if (_window == NULL)
+            if (_window == nullptr)
             {
                 _window = new DetailWindow();
                 _window->setAttribute(Qt::WA_DeleteOnClose);
@@ -96,7 +96,7 @@ void DiagramPrefsDialog::accept()
             else
             {
                 delete _window;
-                _window = NULL;
+                _window = nullptr;
                 OGSError::box("No dataset selected.");
             }
         }
diff --git a/Applications/DataExplorer/DataView/DiagramView/DiagramPrefsDialog.h b/Applications/DataExplorer/DataView/DiagramView/DiagramPrefsDialog.h
index 696e81b577c..d14723ef7cc 100644
--- a/Applications/DataExplorer/DataView/DiagramView/DiagramPrefsDialog.h
+++ b/Applications/DataExplorer/DataView/DiagramView/DiagramPrefsDialog.h
@@ -49,16 +49,16 @@ public:
      * \param parent The parent QDialog.
      */
     DiagramPrefsDialog(const GeoLib::Station* stn,
-                       const QString &listName,
-                       //DatabaseConnection* db,
-                       QDialog* parent = 0);
+                       const QString& listName,
+                       // DatabaseConnection* db,
+                       QDialog* parent = nullptr);
 
     /**
      * Opens a new dialog and automatically reads data from the associated station object.
      * \param stn The station object associated the diagram.
      * \param parent The parent QDialog.
      */
-    DiagramPrefsDialog(GeoLib::Station* stn, QDialog* parent = 0);
+    DiagramPrefsDialog(GeoLib::Station* stn, QDialog* parent = nullptr);
 
     /**
      * Opens a new dialog and automatically reads data from the specified file. The diagram is not associated
@@ -67,9 +67,9 @@ public:
      * \param[out] window Returns the created DetailWindow.
      * \param parent The parent QDialog.
      */
-    DiagramPrefsDialog(const QString &filename,
-                       DetailWindow* window = NULL,
-                       QDialog* parent = 0);
+    DiagramPrefsDialog(const QString& filename,
+                       DetailWindow* window = nullptr,
+                       QDialog* parent = nullptr);
 
     ~DiagramPrefsDialog(void);
 
diff --git a/Applications/DataExplorer/DataView/DiagramView/DiagramScene.cpp b/Applications/DataExplorer/DataView/DiagramView/DiagramScene.cpp
index 57f6e8fc213..44d83a2af42 100644
--- a/Applications/DataExplorer/DataView/DiagramView/DiagramScene.cpp
+++ b/Applications/DataExplorer/DataView/DiagramView/DiagramScene.cpp
@@ -78,7 +78,7 @@ QArrow* DiagramScene::addArrow(float length, float angle, QPen &pen)
 /// Adds a caption for a graph beneath the actual diagram.
 void DiagramScene::addCaption(const QString &name, QPen &pen)
 {
-    QGraphicsItemGroup* caption = new QGraphicsItemGroup(NULL);
+    QGraphicsItemGroup* caption = new QGraphicsItemGroup(nullptr);
     QGraphicsLineItem* l = addLine(0,0,100,0,pen);
     QGraphicsTextItem* t = addText(name);
     l->setPos(0,0);
diff --git a/Applications/DataExplorer/DataView/DiagramView/DiagramScene.h b/Applications/DataExplorer/DataView/DiagramView/DiagramScene.h
index 511ed66e63f..1453dadc5ba 100644
--- a/Applications/DataExplorer/DataView/DiagramView/DiagramScene.h
+++ b/Applications/DataExplorer/DataView/DiagramView/DiagramScene.h
@@ -28,8 +28,8 @@ class QDateTime;
 class DiagramScene : public QGraphicsScene
 {
 public:
-    DiagramScene(QObject* parent = 0);
-    DiagramScene(DiagramList* list, QObject* parent = 0);
+    DiagramScene(QObject* parent = nullptr);
+    DiagramScene(DiagramList* list, QObject* parent = nullptr);
     ~DiagramScene();
 
     QArrow* addArrow(float length, float angle, QPen &pen);
diff --git a/Applications/DataExplorer/DataView/DiagramView/DiagramView.h b/Applications/DataExplorer/DataView/DiagramView/DiagramView.h
index 927eaa98daa..968bf3cdaf7 100644
--- a/Applications/DataExplorer/DataView/DiagramView/DiagramView.h
+++ b/Applications/DataExplorer/DataView/DiagramView/DiagramView.h
@@ -31,13 +31,13 @@ public:
     /**
      * Creates an empty view.
      */
-    DiagramView(QWidget* parent = 0);
+    DiagramView(QWidget* parent = nullptr);
     /**
      * Creates a view already containing a graph
      * \param list Contains a list of data points and metainformation to be displayed by the scene.
      * \param parent The parent QWidget.
      */
-    DiagramView(DiagramList* list, QWidget* parent = 0);
+    DiagramView(DiagramList* list, QWidget* parent = nullptr);
     ~DiagramView();
 
     /// Adds a new graph to the scene.
diff --git a/Applications/DataExplorer/DataView/DiagramView/QArrow.h b/Applications/DataExplorer/DataView/DiagramView/QArrow.h
index 8df5ac7f365..4731222866c 100644
--- a/Applications/DataExplorer/DataView/DiagramView/QArrow.h
+++ b/Applications/DataExplorer/DataView/DiagramView/QArrow.h
@@ -25,8 +25,9 @@ const double PI = 3.14159265;
 class QArrow : public QGraphicsItem
 {
 public:
-    QArrow(float l, float a, float hl, float hw, QPen &pen, QGraphicsItem* parent = 0);
-    QArrow(float l, float a, QPen &pen, QGraphicsItem* parent = 0);
+    QArrow(float l, float a, float hl, float hw, QPen& pen,
+           QGraphicsItem* parent = nullptr);
+    QArrow(float l, float a, QPen& pen, QGraphicsItem* parent = nullptr);
     ~QArrow();
 
     double getLength();
diff --git a/Applications/DataExplorer/DataView/DiagramView/QGraphicsGrid.h b/Applications/DataExplorer/DataView/DiagramView/QGraphicsGrid.h
index ba529f9c648..3518d07edda 100644
--- a/Applications/DataExplorer/DataView/DiagramView/QGraphicsGrid.h
+++ b/Applications/DataExplorer/DataView/DiagramView/QGraphicsGrid.h
@@ -25,20 +25,23 @@
 class QGraphicsGrid : public QGraphicsItem
 {
 public:
-    QGraphicsGrid(QRectF rect, int xCells, int yCells, QGraphicsItem* parent = 0);
+    QGraphicsGrid(QRectF rect,
+                  int xCells,
+                  int yCells,
+                  QGraphicsItem* parent = nullptr);
     QGraphicsGrid(int x,
                   int y,
                   int width,
                   int height,
                   int xCells,
                   int yCells,
-                  QGraphicsItem* parent = 0);
+                  QGraphicsItem* parent = nullptr);
     QGraphicsGrid(QRectF rect,
                   int xCells,
                   int yCells,
                   bool ticks,
                   QPen pen,
-                  QGraphicsItem* parent = 0);
+                  QGraphicsItem* parent = nullptr);
     QGraphicsGrid(int x,
                   int y,
                   int width,
@@ -47,7 +50,7 @@ public:
                   int yCells,
                   bool ticks,
                   QPen pen,
-                  QGraphicsItem* parent = 0);
+                  QGraphicsItem* parent = nullptr);
     ~QGraphicsGrid();
 
     QRectF boundingRect() const;
diff --git a/Applications/DataExplorer/DataView/ElementTreeModel.h b/Applications/DataExplorer/DataView/ElementTreeModel.h
index eb860ac9573..dfac4a60e2f 100644
--- a/Applications/DataExplorer/DataView/ElementTreeModel.h
+++ b/Applications/DataExplorer/DataView/ElementTreeModel.h
@@ -32,7 +32,7 @@ class ElementTreeModel : public TreeModel
     Q_OBJECT
 
 public:
-    ElementTreeModel( QObject* parent = 0 );
+    ElementTreeModel(QObject* parent = nullptr);
     ~ElementTreeModel();
 
     vtkUnstructuredGridAlgorithm const* getSource() const { return _mesh_source; };
diff --git a/Applications/DataExplorer/DataView/ElementTreeView.cpp b/Applications/DataExplorer/DataView/ElementTreeView.cpp
index db7813459fe..085a8acd125 100644
--- a/Applications/DataExplorer/DataView/ElementTreeView.cpp
+++ b/Applications/DataExplorer/DataView/ElementTreeView.cpp
@@ -29,7 +29,8 @@ void ElementTreeView::updateView()
 {
     setAlternatingRowColors(true);
     setColumnWidth(0,125);
-    std::size_t nColumns = (this->model() != NULL) ? this->model()->columnCount() : 0;
+    std::size_t nColumns =
+        (this->model() != nullptr) ? this->model()->columnCount() : 0;
     for (std::size_t i = 1; i < nColumns; i++)
         resizeColumnToContents(i);
     this->expandAll();
diff --git a/Applications/DataExplorer/DataView/ElementTreeView.h b/Applications/DataExplorer/DataView/ElementTreeView.h
index a3531ba226d..cdd048901f1 100644
--- a/Applications/DataExplorer/DataView/ElementTreeView.h
+++ b/Applications/DataExplorer/DataView/ElementTreeView.h
@@ -26,7 +26,7 @@ class ElementTreeView : public QTreeView
 
 public:
     /// Constructor
-    ElementTreeView(QWidget* parent = 0);
+    ElementTreeView(QWidget* parent = nullptr);
 
 public slots:
     void updateView();
diff --git a/Applications/DataExplorer/DataView/GeoObjectListItem.h b/Applications/DataExplorer/DataView/GeoObjectListItem.h
index a85c9b86b89..99c5e667894 100644
--- a/Applications/DataExplorer/DataView/GeoObjectListItem.h
+++ b/Applications/DataExplorer/DataView/GeoObjectListItem.h
@@ -34,11 +34,13 @@ class GeoObjectListItem : public TreeItem
 {
 public:
     /// Constructor for the TreeItem specifying the "Points"-subtree of a geometry.
-    GeoObjectListItem(const QList<QVariant> &data,
+    GeoObjectListItem(const QList<QVariant>& data,
                       TreeItem* parent,
-                      const std::vector<GeoLib::Point*>* geo_data = NULL,
+                      const std::vector<GeoLib::Point*>* geo_data = nullptr,
                       GeoLib::GEOTYPE type = GeoLib::GEOTYPE::POINT)
-        : TreeItem(data, parent), _vtkSource(VtkPointsSource::New()), _type(type)
+        : TreeItem(data, parent),
+          _vtkSource(VtkPointsSource::New()),
+          _type(type)
     {
         QString geo_name = parent->data(0).toString();
         static_cast<VtkPointsSource*>(_vtkSource)->setPoints(geo_data);
@@ -46,11 +48,13 @@ public:
     }
 
     /// Constructor for the TreeItem specifying the "Polylines"-subtree of a geometry.
-    GeoObjectListItem(const QList<QVariant> &data,
+    GeoObjectListItem(const QList<QVariant>& data,
                       TreeItem* parent,
-                      const std::vector<GeoLib::Polyline*>* geo_data = NULL,
+                      const std::vector<GeoLib::Polyline*>* geo_data = nullptr,
                       GeoLib::GEOTYPE type = GeoLib::GEOTYPE::POLYLINE)
-        : TreeItem(data, parent), _vtkSource(VtkPolylinesSource::New()), _type(type)
+        : TreeItem(data, parent),
+          _vtkSource(VtkPolylinesSource::New()),
+          _type(type)
     {
         QString geo_name = parent->data(0).toString();
         static_cast<VtkPolylinesSource*>(_vtkSource)->setPolylines(geo_data);
@@ -58,11 +62,13 @@ public:
     }
 
     /// Constructor for the TreeItem specifying the "Surfaces"-subtree of a geometry.
-    GeoObjectListItem(const QList<QVariant> &data,
+    GeoObjectListItem(const QList<QVariant>& data,
                       TreeItem* parent,
-                      const std::vector<GeoLib::Surface*>* geo_data = NULL,
+                      const std::vector<GeoLib::Surface*>* geo_data = nullptr,
                       GeoLib::GEOTYPE type = GeoLib::GEOTYPE::SURFACE)
-        : TreeItem(data, parent), _vtkSource(VtkSurfacesSource::New()),  _type(type)
+        : TreeItem(data, parent),
+          _vtkSource(VtkSurfacesSource::New()),
+          _type(type)
     {
         QString geo_name = parent->data(0).toString();
         static_cast<VtkSurfacesSource*>(_vtkSource)->setSurfaces(geo_data);
diff --git a/Applications/DataExplorer/DataView/GeoOnMeshMappingDialog.h b/Applications/DataExplorer/DataView/GeoOnMeshMappingDialog.h
index 985c6cde388..5977fb06031 100644
--- a/Applications/DataExplorer/DataView/GeoOnMeshMappingDialog.h
+++ b/Applications/DataExplorer/DataView/GeoOnMeshMappingDialog.h
@@ -33,7 +33,7 @@ class GeoOnMeshMappingDialog : public QDialog, private Ui_GeoOnMeshMapping
 public:
     GeoOnMeshMappingDialog(
         std::vector<std::unique_ptr<MeshLib::Mesh>> const& mesh_vec,
-        QDialog* parent = 0);
+        QDialog* parent = nullptr);
     ~GeoOnMeshMappingDialog(void);
 
     std::string const& getNewGeoName() const { return _new_geo_name; };
diff --git a/Applications/DataExplorer/DataView/GeoTabWidget.h b/Applications/DataExplorer/DataView/GeoTabWidget.h
index 825a3916c68..7a742e966ac 100644
--- a/Applications/DataExplorer/DataView/GeoTabWidget.h
+++ b/Applications/DataExplorer/DataView/GeoTabWidget.h
@@ -25,7 +25,7 @@ class GeoTabWidget : public QWidget, public Ui_GeoTabWidgetBase
     Q_OBJECT
 
 public:
-    GeoTabWidget(QWidget* parent = 0);
+    GeoTabWidget(QWidget* parent = nullptr);
 
 private:
 
diff --git a/Applications/DataExplorer/DataView/GeoTreeItem.h b/Applications/DataExplorer/DataView/GeoTreeItem.h
index 45d3c41a2c9..9d2f04299eb 100644
--- a/Applications/DataExplorer/DataView/GeoTreeItem.h
+++ b/Applications/DataExplorer/DataView/GeoTreeItem.h
@@ -32,9 +32,12 @@ public:
      * \param parent The parent item in the tree
      * \param item The GeoObject (i.e. Point, Polyline or Surface)
      */
-    GeoTreeItem(const QList<QVariant> &data,
+    GeoTreeItem(const QList<QVariant>& data,
                 TreeItem* parent,
-                const GeoLib::GeoObject* item = NULL) : TreeItem(data, parent), _item(item) {}
+                const GeoLib::GeoObject* item = nullptr)
+        : TreeItem(data, parent), _item(item)
+    {
+    }
     ~GeoTreeItem() {}
 
     /// Returns the geo-object associated with this item (i.e. a point, polyline or surface).
diff --git a/Applications/DataExplorer/DataView/GeoTreeModel.cpp b/Applications/DataExplorer/DataView/GeoTreeModel.cpp
index b5c6f6a91c6..ac186f8326b 100644
--- a/Applications/DataExplorer/DataView/GeoTreeModel.cpp
+++ b/Applications/DataExplorer/DataView/GeoTreeModel.cpp
@@ -30,7 +30,7 @@ GeoTreeModel::GeoTreeModel( QObject* parent )
     QList<QVariant> rootData;
     delete _rootItem;
     rootData << "Id" << "x" << "y" << "z" << "name ";
-    _rootItem = new GeoTreeItem(rootData, NULL, NULL);
+    _rootItem = new GeoTreeItem(rootData, nullptr, nullptr);
 }
 
 GeoTreeModel::~GeoTreeModel()
@@ -84,14 +84,14 @@ void GeoTreeModel::addPolylineList(QString geoName, GeoLib::PolylineVec const& p
     beginResetModel();
 
     int nLists = _rootItem->childCount();
-    TreeItem* geo(NULL);
+    TreeItem* geo(nullptr);
     for (int i = 0; i < nLists; i++)
     {
         if (_rootItem->child(i)->data(0).toString().compare(geoName) == 0)
             geo = _rootItem->child(i);
     }
 
-    if (geo == NULL)
+    if (geo == nullptr)
     {
         ERR("GeoTreeModel::addPolylineList(): No corresponding geometry for \"%s\" found.", geoName.toStdString().c_str());
         return;
@@ -175,7 +175,7 @@ void GeoTreeModel::addSurfaceList(QString geoName, GeoLib::SurfaceVec const& sur
     beginResetModel();
 
     int nLists = _rootItem->childCount();
-    TreeItem* geo(NULL);
+    TreeItem* geo(nullptr);
     for (int i = 0; i < nLists; i++)
     {
         if (_rootItem->child(i)->data(0).toString().compare(geoName) == 0)
@@ -316,7 +316,7 @@ vtkPolyDataAlgorithm* GeoTreeModel::vtkSource(const std::string &name, GeoLib::G
                     return item->vtkSource();
             }
     }
-    return NULL;
+    return nullptr;
 }
 
 void GeoTreeModel::setNameForItem(const std::string &name,
diff --git a/Applications/DataExplorer/DataView/GeoTreeModel.h b/Applications/DataExplorer/DataView/GeoTreeModel.h
index 543a77ef9cf..253090f33c4 100644
--- a/Applications/DataExplorer/DataView/GeoTreeModel.h
+++ b/Applications/DataExplorer/DataView/GeoTreeModel.h
@@ -42,7 +42,7 @@ class GeoTreeModel : public TreeModel
     Q_OBJECT
 
 public:
-    GeoTreeModel( QObject* parent = 0 );
+    GeoTreeModel(QObject* parent = nullptr);
     ~GeoTreeModel();
 
     /**
diff --git a/Applications/DataExplorer/DataView/GeoTreeView.cpp b/Applications/DataExplorer/DataView/GeoTreeView.cpp
index c52cd8898a0..5bd4a4ea7de 100644
--- a/Applications/DataExplorer/DataView/GeoTreeView.cpp
+++ b/Applications/DataExplorer/DataView/GeoTreeView.cpp
@@ -121,9 +121,9 @@ void GeoTreeView::contextMenuEvent( QContextMenuEvent* event )
     QMenu menu;
 
     // The current index is a list of points/polylines/surfaces
-    if (list != NULL)
+    if (list != nullptr)
     {
-        QAction* connectPlyAction(NULL);
+        QAction* connectPlyAction(nullptr);
         if (list->getType() == GeoLib::GEOTYPE::POLYLINE)
         {
             connectPlyAction = menu.addAction("Connect Polylines...");
@@ -142,7 +142,7 @@ void GeoTreeView::contextMenuEvent( QContextMenuEvent* event )
         GeoObjectListItem* parent = dynamic_cast<GeoObjectListItem*>(item->parentItem());
 
         // The current index refers to a geo-object
-        if (parent != NULL)
+        if (parent != nullptr)
         {
             QMenu* cond_menu = new QMenu("Set FEM Condition");
             //menu.addMenu(cond_menu);
@@ -260,7 +260,8 @@ void GeoTreeView::writeToFile() const
          file_type.append(";;Legacy geometry file (*.gli)");
 #endif // DEBUG
         QString geoName = item->data(0).toString();
-        QString fileName = QFileDialog::getSaveFileName(NULL, "Save geometry as",
+        QString fileName = QFileDialog::getSaveFileName(
+            nullptr, "Save geometry as",
             LastSavedFileDirectory::getDir() + geoName, file_type);
         if (!fileName.isEmpty())
         {
diff --git a/Applications/DataExplorer/DataView/GeoTreeView.h b/Applications/DataExplorer/DataView/GeoTreeView.h
index dd4f27cb9df..98a94e39642 100644
--- a/Applications/DataExplorer/DataView/GeoTreeView.h
+++ b/Applications/DataExplorer/DataView/GeoTreeView.h
@@ -31,7 +31,7 @@ class GeoTreeView : public QTreeView
 
 public:
     /// Constructor
-    GeoTreeView(QWidget* parent = 0);
+    GeoTreeView(QWidget* parent = nullptr);
 
     /// Update the view to visualise changes made to the underlying data
     void updateView();
diff --git a/Applications/DataExplorer/DataView/LicenseDialog.h b/Applications/DataExplorer/DataView/LicenseDialog.h
index 0e9b60923e7..e317bf44e90 100644
--- a/Applications/DataExplorer/DataView/LicenseDialog.h
+++ b/Applications/DataExplorer/DataView/LicenseDialog.h
@@ -25,7 +25,7 @@ class LicenseDialog : public QDialog, private Ui_License
     Q_OBJECT
 
 public:
-    LicenseDialog(QDialog* parent = 0);
+    LicenseDialog(QDialog* parent = nullptr);
     ~LicenseDialog() {};
 
 private:
diff --git a/Applications/DataExplorer/DataView/LineEditDialog.cpp b/Applications/DataExplorer/DataView/LineEditDialog.cpp
index 56215c54dac..f3f653a8fa7 100644
--- a/Applications/DataExplorer/DataView/LineEditDialog.cpp
+++ b/Applications/DataExplorer/DataView/LineEditDialog.cpp
@@ -80,7 +80,8 @@ void LineEditDialog::accept()
     if (!selectedIndeces.empty())
     {
         std::string prox_string = this->proximityEdit->text().toStdString();
-        double prox = (prox_string.empty()) ? 0.0 : strtod( prox_string.c_str(), 0 );
+        double prox =
+            (prox_string.empty()) ? 0.0 : strtod(prox_string.c_str(), nullptr);
         std::string ply_name =
                 (plyNameEdit->text().toStdString().empty()) ? "" : plyNameEdit->text().
                 toStdString();
diff --git a/Applications/DataExplorer/DataView/LineEditDialog.h b/Applications/DataExplorer/DataView/LineEditDialog.h
index 8db79316cf0..f2a444e12bc 100644
--- a/Applications/DataExplorer/DataView/LineEditDialog.h
+++ b/Applications/DataExplorer/DataView/LineEditDialog.h
@@ -31,7 +31,8 @@ class LineEditDialog : public QDialog, private Ui_LineEdit
     Q_OBJECT
 
 public:
-    LineEditDialog(const GeoLib::PolylineVec &ply_vec, QDialog* parent = 0);
+    LineEditDialog(const GeoLib::PolylineVec& ply_vec,
+                   QDialog* parent = nullptr);
     ~LineEditDialog(void);
 
 private:
diff --git a/Applications/DataExplorer/DataView/LinearEditDialog.h b/Applications/DataExplorer/DataView/LinearEditDialog.h
index d35d57bb0a1..a94039ec128 100644
--- a/Applications/DataExplorer/DataView/LinearEditDialog.h
+++ b/Applications/DataExplorer/DataView/LinearEditDialog.h
@@ -27,7 +27,10 @@ class LinearEditDialog : public QDialog, private Ui_LinearEdit
     Q_OBJECT
 
 public:
-    LinearEditDialog(const GeoLib::Polyline &line, const std::vector<std::size_t> &dis_nodes, const std::vector<double> &dis_values, QDialog* parent = 0);
+    LinearEditDialog(const GeoLib::Polyline& line,
+                     const std::vector<std::size_t>& dis_nodes,
+                     const std::vector<double>& dis_values,
+                     QDialog* parent = nullptr);
     ~LinearEditDialog(void);
 
 private:
diff --git a/Applications/DataExplorer/DataView/MergeGeometriesDialog.h b/Applications/DataExplorer/DataView/MergeGeometriesDialog.h
index ad9c1bac5f5..c8dcc161a25 100644
--- a/Applications/DataExplorer/DataView/MergeGeometriesDialog.h
+++ b/Applications/DataExplorer/DataView/MergeGeometriesDialog.h
@@ -32,7 +32,8 @@ class MergeGeometriesDialog : public QDialog, private Ui_MergeGeometries
     Q_OBJECT
 
 public:
-    MergeGeometriesDialog(GeoLib::GEOObjects& geoObjects, QDialog* parent = 0);
+    MergeGeometriesDialog(GeoLib::GEOObjects& geoObjects,
+                          QDialog* parent = nullptr);
     ~MergeGeometriesDialog(void);
 
     /// Returns a vector of selected geometries
diff --git a/Applications/DataExplorer/DataView/MeshElementRemovalDialog.h b/Applications/DataExplorer/DataView/MeshElementRemovalDialog.h
index d08232f9c59..edd0cf89fab 100644
--- a/Applications/DataExplorer/DataView/MeshElementRemovalDialog.h
+++ b/Applications/DataExplorer/DataView/MeshElementRemovalDialog.h
@@ -36,7 +36,8 @@ class MeshElementRemovalDialog : public QDialog, private Ui_MeshElementRemoval
     Q_OBJECT
 
 public:
-    MeshElementRemovalDialog(DataHolderLib::Project const& project, QDialog* parent = 0);
+    MeshElementRemovalDialog(DataHolderLib::Project const& project,
+                             QDialog* parent = nullptr);
     ~MeshElementRemovalDialog(void);
 
 private slots:
diff --git a/Applications/DataExplorer/DataView/MeshLayerEditDialog.h b/Applications/DataExplorer/DataView/MeshLayerEditDialog.h
index bca05f792bf..83f443134d7 100644
--- a/Applications/DataExplorer/DataView/MeshLayerEditDialog.h
+++ b/Applications/DataExplorer/DataView/MeshLayerEditDialog.h
@@ -39,7 +39,7 @@ class MeshLayerEditDialog : public QDialog, private Ui_MeshLayerEdit
     Q_OBJECT
 
 public:
-    MeshLayerEditDialog(const MeshLib::Mesh* mesh, QDialog* parent = 0);
+    MeshLayerEditDialog(const MeshLib::Mesh* mesh, QDialog* parent = nullptr);
     ~MeshLayerEditDialog(void);
 
 private:
diff --git a/Applications/DataExplorer/DataView/MeshQualitySelectionDialog.h b/Applications/DataExplorer/DataView/MeshQualitySelectionDialog.h
index 72502837624..9160253fa49 100644
--- a/Applications/DataExplorer/DataView/MeshQualitySelectionDialog.h
+++ b/Applications/DataExplorer/DataView/MeshQualitySelectionDialog.h
@@ -28,7 +28,7 @@ class MeshQualitySelectionDialog : public QDialog, private Ui_MeshQualitySelecti
     Q_OBJECT
 
 public:
-    MeshQualitySelectionDialog(QDialog* parent = 0);
+    MeshQualitySelectionDialog(QDialog* parent = nullptr);
     ~MeshQualitySelectionDialog(void);
 
     /// Returns selected metric
diff --git a/Applications/DataExplorer/DataView/MeshValueEditDialog.h b/Applications/DataExplorer/DataView/MeshValueEditDialog.h
index df4de5b0a15..518981d079e 100644
--- a/Applications/DataExplorer/DataView/MeshValueEditDialog.h
+++ b/Applications/DataExplorer/DataView/MeshValueEditDialog.h
@@ -31,7 +31,7 @@ class MeshValueEditDialog : public QDialog, private Ui_MeshValueEdit
 
 public:
     /// Constructor for creating a new FEM condition.
-    MeshValueEditDialog(MeshLib::Mesh* mesh, QDialog* parent = 0);
+    MeshValueEditDialog(MeshLib::Mesh* mesh, QDialog* parent = nullptr);
 
     ~MeshValueEditDialog(void);
 
diff --git a/Applications/DataExplorer/DataView/ModelTreeItem.cpp b/Applications/DataExplorer/DataView/ModelTreeItem.cpp
index 803c89d3f62..67132a7eb15 100644
--- a/Applications/DataExplorer/DataView/ModelTreeItem.cpp
+++ b/Applications/DataExplorer/DataView/ModelTreeItem.cpp
@@ -21,8 +21,8 @@ ModelTreeItem::ModelTreeItem(const QList<QVariant> &data, TreeItem* parent, Base
 
 BaseItem* ModelTreeItem::getItem() const
 {
-    if (_item != NULL)
+    if (_item != nullptr)
         return _item;
-    return NULL;
+    return nullptr;
 }
 
diff --git a/Applications/DataExplorer/DataView/ModelTreeItem.h b/Applications/DataExplorer/DataView/ModelTreeItem.h
index 58a86176b42..a2e664e9fb8 100644
--- a/Applications/DataExplorer/DataView/ModelTreeItem.h
+++ b/Applications/DataExplorer/DataView/ModelTreeItem.h
@@ -32,7 +32,8 @@ public:
      * \param parent The parent item in the tree
      * \param item The ModelItem-object
      */
-    ModelTreeItem(const QList<QVariant> &data, TreeItem* parent, BaseItem* item = NULL);
+    ModelTreeItem(const QList<QVariant>& data, TreeItem* parent,
+                  BaseItem* item = nullptr);
     ~ModelTreeItem() { delete _item; }
 
     /// Returns the station object from which this item has been constructed
diff --git a/Applications/DataExplorer/DataView/ModellingTabWidget.h b/Applications/DataExplorer/DataView/ModellingTabWidget.h
index 87bcb53b388..af7e6a1f4fc 100644
--- a/Applications/DataExplorer/DataView/ModellingTabWidget.h
+++ b/Applications/DataExplorer/DataView/ModellingTabWidget.h
@@ -25,7 +25,7 @@ class ModellingTabWidget : public QWidget, public Ui_ModellingTabWidgetBase
     Q_OBJECT
 
 public:
-    ModellingTabWidget(QWidget* parent = 0);
+    ModellingTabWidget(QWidget* parent = nullptr);
 
 private slots:
 
diff --git a/Applications/DataExplorer/DataView/MshEditDialog.cpp b/Applications/DataExplorer/DataView/MshEditDialog.cpp
index ebf5bcc71fd..8a1dfca4266 100644
--- a/Applications/DataExplorer/DataView/MshEditDialog.cpp
+++ b/Applications/DataExplorer/DataView/MshEditDialog.cpp
@@ -29,17 +29,19 @@
 #include <QVBoxLayout>
 
 MshEditDialog::MshEditDialog(const MeshLib::Mesh* mesh, QDialog* parent)
-    : QDialog(parent), _msh(mesh), _noDataDeleteBox(NULL),
-      _nLayerLabel (new QLabel("Please specify the number of layers to add:")),
-      _nLayerExplanation (new QLabel("(select \"0\" for surface mapping)")),
-      _layerEdit (new QLineEdit("0")),
-      _nextButton (new QPushButton("Next")),
-      _layerBox (NULL),
-      _radioButtonBox (NULL),
-      _layerSelectionLayout (new QGridLayout),
-      _radiobuttonLayout (new QVBoxLayout),
-      _selectButton1 (new QRadioButton("Add layers based on raster files")),
-      _selectButton2 (new QRadioButton("Add layers with static thickness")),
+    : QDialog(parent),
+      _msh(mesh),
+      _noDataDeleteBox(nullptr),
+      _nLayerLabel(new QLabel("Please specify the number of layers to add:")),
+      _nLayerExplanation(new QLabel("(select \"0\" for surface mapping)")),
+      _layerEdit(new QLineEdit("0")),
+      _nextButton(new QPushButton("Next")),
+      _layerBox(nullptr),
+      _radioButtonBox(nullptr),
+      _layerSelectionLayout(new QGridLayout),
+      _radiobuttonLayout(new QVBoxLayout),
+      _selectButton1(new QRadioButton("Add layers based on raster files")),
+      _selectButton2(new QRadioButton("Add layers with static thickness")),
       _n_layers(0),
       _use_rasters(true)
 {
@@ -187,7 +189,7 @@ void MshEditDialog::accept()
         {
             int result(1);
             const unsigned nLayers = _layerEdit->text().toInt();
-            MeshLib::Mesh* new_mesh (NULL);
+            MeshLib::Mesh* new_mesh(nullptr);
 
             if (nLayers==0)
             {
diff --git a/Applications/DataExplorer/DataView/MshModel.h b/Applications/DataExplorer/DataView/MshModel.h
index 5f2ac09098d..2013e855daf 100644
--- a/Applications/DataExplorer/DataView/MshModel.h
+++ b/Applications/DataExplorer/DataView/MshModel.h
@@ -39,7 +39,7 @@ class MshModel : public TreeModel
     Q_OBJECT
 
 public:
-    MshModel(DataHolderLib::Project &project, QObject* parent = 0);
+    MshModel(DataHolderLib::Project& project, QObject* parent = nullptr);
 
     /// Adds a new mesh
     void addMesh(std::unique_ptr<MeshLib::Mesh> mesh);
diff --git a/Applications/DataExplorer/DataView/MshTabWidget.h b/Applications/DataExplorer/DataView/MshTabWidget.h
index ec7b8196214..4064ea215cf 100644
--- a/Applications/DataExplorer/DataView/MshTabWidget.h
+++ b/Applications/DataExplorer/DataView/MshTabWidget.h
@@ -25,7 +25,7 @@ class MshTabWidget : public QWidget, public Ui_MshTabWidgetBase
     Q_OBJECT
 
 public:
-    MshTabWidget(QWidget* parent = 0);
+    MshTabWidget(QWidget* parent = nullptr);
 
 private slots:
     void enableSaveButton(bool enable) { this->saveMeshPushButton->setEnabled(enable); };
diff --git a/Applications/DataExplorer/DataView/MshView.h b/Applications/DataExplorer/DataView/MshView.h
index 4eb055ebcd1..8cdde7798e0 100644
--- a/Applications/DataExplorer/DataView/MshView.h
+++ b/Applications/DataExplorer/DataView/MshView.h
@@ -37,7 +37,7 @@ class MshView : public QTreeView
     Q_OBJECT
 
 public:
-    MshView(QWidget* parent = 0);
+    MshView(QWidget* parent = nullptr);
     ~MshView();
 
 public slots:
diff --git a/Applications/DataExplorer/DataView/NetCdfConfigureDialog.cpp b/Applications/DataExplorer/DataView/NetCdfConfigureDialog.cpp
index 013ec3475dd..13e089edd32 100644
--- a/Applications/DataExplorer/DataView/NetCdfConfigureDialog.cpp
+++ b/Applications/DataExplorer/DataView/NetCdfConfigureDialog.cpp
@@ -221,7 +221,7 @@ void NetCdfConfigureDialog::setDimensionSelect()
 
 void NetCdfConfigureDialog::getDimEdges(int dimId, unsigned &size, double &firstValue, double &lastValue)
 {
-    if ((_currentFile->get_var(_currentVar->get_dim(dimId)->name())) != NULL)
+    if ((_currentFile->get_var(_currentVar->get_dim(dimId)->name())) != nullptr)
     {
         NcVar *tmpVarOfDim = _currentFile->get_var(_currentVar->get_dim(dimId)->name());
         if ((tmpVarOfDim->num_dims()) == 1)
diff --git a/Applications/DataExplorer/DataView/NetCdfConfigureDialog.h b/Applications/DataExplorer/DataView/NetCdfConfigureDialog.h
index 6371f44127d..8be5093a210 100644
--- a/Applications/DataExplorer/DataView/NetCdfConfigureDialog.h
+++ b/Applications/DataExplorer/DataView/NetCdfConfigureDialog.h
@@ -33,7 +33,8 @@ class NetCdfConfigureDialog : public QDialog, private Ui_NetCdfConfigure
     Q_OBJECT
 
 public:
-    NetCdfConfigureDialog(const std::string &fileName, QDialog* parent = 0);
+    NetCdfConfigureDialog(const std::string& fileName,
+                          QDialog* parent = nullptr);
     ~NetCdfConfigureDialog(void);
     MeshLib::Mesh* getMesh() { return _currentMesh; };
     std::string getName();
diff --git a/Applications/DataExplorer/DataView/SaveMeshDialog.h b/Applications/DataExplorer/DataView/SaveMeshDialog.h
index 0e371636be7..425244b8961 100644
--- a/Applications/DataExplorer/DataView/SaveMeshDialog.h
+++ b/Applications/DataExplorer/DataView/SaveMeshDialog.h
@@ -29,7 +29,7 @@ class SaveMeshDialog : public QDialog, private Ui_SaveMesh
     Q_OBJECT
 
 public:
-    SaveMeshDialog(MeshLib::Mesh const& mesh, QDialog* parent = 0);
+    SaveMeshDialog(MeshLib::Mesh const& mesh, QDialog* parent = nullptr);
     ~SaveMeshDialog() {}
 
 private slots:
diff --git a/Applications/DataExplorer/DataView/SelectMeshDialog.h b/Applications/DataExplorer/DataView/SelectMeshDialog.h
index dcc1c4e1f94..57da27a82f8 100644
--- a/Applications/DataExplorer/DataView/SelectMeshDialog.h
+++ b/Applications/DataExplorer/DataView/SelectMeshDialog.h
@@ -35,8 +35,8 @@ class SelectMeshDialog : public QDialog
 public:
     /// Constructor
     SelectMeshDialog(const GeoLib::GeoObject* geo_object,
-                  const std::list<std::string> &msh_names,
-                  QDialog* parent = 0);
+                     const std::list<std::string>& msh_names,
+                     QDialog* parent = nullptr);
     ~SelectMeshDialog();
 
     QDialogButtonBox* _buttonBox; /// The buttons used in this dialog.
diff --git a/Applications/DataExplorer/DataView/SetNameDialog.h b/Applications/DataExplorer/DataView/SetNameDialog.h
index 5afe0ea52d4..4cca4829ae8 100644
--- a/Applications/DataExplorer/DataView/SetNameDialog.h
+++ b/Applications/DataExplorer/DataView/SetNameDialog.h
@@ -32,7 +32,8 @@ class SetNameDialog : public QDialog
 
 public:
     /// Constructor
-    SetNameDialog(const std::string &geo_object_type, std::size_t id, const std::string &old_name, QDialog* parent = 0);
+    SetNameDialog(const std::string& geo_object_type, std::size_t id,
+                  const std::string& old_name, QDialog* parent = nullptr);
     ~SetNameDialog();
 
     std::string getNewName();
diff --git a/Applications/DataExplorer/DataView/StationTabWidget.h b/Applications/DataExplorer/DataView/StationTabWidget.h
index 2cfefb80502..088329da3ab 100644
--- a/Applications/DataExplorer/DataView/StationTabWidget.h
+++ b/Applications/DataExplorer/DataView/StationTabWidget.h
@@ -25,7 +25,7 @@ class StationTabWidget : public QWidget, public Ui_StationTabWidgetBase
     Q_OBJECT
 
 public:
-    StationTabWidget(QWidget* parent = 0);
+    StationTabWidget(QWidget* parent = nullptr);
 
 private:
 
diff --git a/Applications/DataExplorer/DataView/StationTreeModel.h b/Applications/DataExplorer/DataView/StationTreeModel.h
index a303250304a..f4257527c62 100644
--- a/Applications/DataExplorer/DataView/StationTreeModel.h
+++ b/Applications/DataExplorer/DataView/StationTreeModel.h
@@ -43,7 +43,7 @@ class StationTreeModel : public TreeModel
     Q_OBJECT
 
 public:
-    StationTreeModel(QObject* parent = 0);
+    StationTreeModel(QObject* parent = nullptr);
     ~StationTreeModel();
 
     void addStationList(QString listName, const std::vector<GeoLib::Point*>* stations);
diff --git a/Applications/DataExplorer/DataView/StationTreeView.h b/Applications/DataExplorer/DataView/StationTreeView.h
index 3b5ed7c73e3..567eb536b60 100644
--- a/Applications/DataExplorer/DataView/StationTreeView.h
+++ b/Applications/DataExplorer/DataView/StationTreeView.h
@@ -31,7 +31,7 @@ class StationTreeView : public QTreeView
 
 public:
     /// Constructor
-    StationTreeView(QWidget* parent = 0);
+    StationTreeView(QWidget* parent = nullptr);
 
     /// Update the view to visualise changes made to the underlying data
     void updateView();
diff --git a/Applications/DataExplorer/DataView/StratView/StratBar.h b/Applications/DataExplorer/DataView/StratView/StratBar.h
index 66b39987ab2..97111408dbc 100644
--- a/Applications/DataExplorer/DataView/StratView/StratBar.h
+++ b/Applications/DataExplorer/DataView/StratView/StratBar.h
@@ -37,7 +37,7 @@ public:
      */
     StratBar(GeoLib::StationBorehole* station,
              std::map<std::string, DataHolderLib::Color>* stratColors = nullptr,
-             QGraphicsItem* parent = 0);
+             QGraphicsItem* parent = nullptr);
     ~StratBar();
 
     /// Returns the bounding rectangle of the bar.
diff --git a/Applications/DataExplorer/DataView/StratView/StratScene.h b/Applications/DataExplorer/DataView/StratView/StratScene.h
index 03fb6688343..47612198c1e 100644
--- a/Applications/DataExplorer/DataView/StratView/StratScene.h
+++ b/Applications/DataExplorer/DataView/StratView/StratScene.h
@@ -29,9 +29,10 @@ class StratScene : public QGraphicsScene
 {
 public:
     /// Constructor
-    StratScene(GeoLib::StationBorehole* station,
-               std::map<std::string, DataHolderLib::Color>* stratColors = nullptr,
-               QObject* parent = 0);
+    StratScene(
+        GeoLib::StationBorehole* station,
+        std::map<std::string, DataHolderLib::Color>* stratColors = nullptr,
+        QObject* parent = nullptr);
     ~StratScene();
 
     /// The margin between the boundary of the scene and the bounding box of all items within the scene
diff --git a/Applications/DataExplorer/DataView/StratView/StratView.h b/Applications/DataExplorer/DataView/StratView/StratView.h
index b55b30db4eb..fde63435e95 100644
--- a/Applications/DataExplorer/DataView/StratView/StratView.h
+++ b/Applications/DataExplorer/DataView/StratView/StratView.h
@@ -34,7 +34,7 @@ public:
     /**
      * Creates an empty view.
      */
-    StratView(QWidget* parent = 0) : _scene(NULL) {Q_UNUSED(parent); }
+    StratView(QWidget* parent = nullptr) : _scene(nullptr) { Q_UNUSED(parent); }
     ~StratView();
 
     /// Sets the Borehole whose data should be visualised.
diff --git a/Applications/DataExplorer/DataView/StratView/StratWindow.h b/Applications/DataExplorer/DataView/StratView/StratWindow.h
index 16da35d466f..40bf8cdf72a 100644
--- a/Applications/DataExplorer/DataView/StratView/StratWindow.h
+++ b/Applications/DataExplorer/DataView/StratView/StratWindow.h
@@ -36,9 +36,10 @@ public:
      * \param stratColors A color map.
      * \param parent The parent QWidget.
      */
-    StratWindow(GeoLib::StationBorehole* station,
-                std::map<std::string, DataHolderLib::Color>* stratColors = nullptr,
-                QWidget* parent = 0);
+    StratWindow(
+        GeoLib::StationBorehole* station,
+        std::map<std::string, DataHolderLib::Color>* stratColors = nullptr,
+        QWidget* parent = nullptr);
     ~StratWindow(void) { this->destroy(); }
 
 private:
diff --git a/Applications/DataExplorer/DataView/SurfaceExtractionDialog.h b/Applications/DataExplorer/DataView/SurfaceExtractionDialog.h
index ad482c3b457..4a9327e3eba 100644
--- a/Applications/DataExplorer/DataView/SurfaceExtractionDialog.h
+++ b/Applications/DataExplorer/DataView/SurfaceExtractionDialog.h
@@ -31,7 +31,7 @@ class SurfaceExtractionDialog : public QDialog, private Ui_SurfaceExtraction
     Q_OBJECT
 
 public:
-    SurfaceExtractionDialog(QDialog* parent = 0);
+    SurfaceExtractionDialog(QDialog* parent = nullptr);
     ~SurfaceExtractionDialog() {}
 
     int getTolerance() const { return _tolerance; }
diff --git a/Applications/DataExplorer/VtkVis/MeshFromRasterDialog.h b/Applications/DataExplorer/VtkVis/MeshFromRasterDialog.h
index e474792a216..474b9649699 100644
--- a/Applications/DataExplorer/VtkVis/MeshFromRasterDialog.h
+++ b/Applications/DataExplorer/VtkVis/MeshFromRasterDialog.h
@@ -34,7 +34,7 @@ class MeshFromRasterDialog : public QDialog, private Ui_MeshFromRaster
 
 public:
     /// Constructor
-    MeshFromRasterDialog(QDialog* parent = 0);
+    MeshFromRasterDialog(QDialog* parent = nullptr);
     ~MeshFromRasterDialog(void);
 
     std::string getMeshName() const { return _mesh_name; }
diff --git a/Applications/DataExplorer/VtkVis/QVtkDataSetMapper.cpp b/Applications/DataExplorer/VtkVis/QVtkDataSetMapper.cpp
index 713b12a9ade..6fbd18db23f 100644
--- a/Applications/DataExplorer/VtkVis/QVtkDataSetMapper.cpp
+++ b/Applications/DataExplorer/VtkVis/QVtkDataSetMapper.cpp
@@ -19,8 +19,7 @@
 
 vtkStandardNewMacro(QVtkDataSetMapper);
 
-QVtkDataSetMapper::QVtkDataSetMapper()
-    : QObject(NULL)
+QVtkDataSetMapper::QVtkDataSetMapper() : QObject(nullptr)
 {
 }
 
diff --git a/Applications/DataExplorer/VtkVis/VisualizationWidget.h b/Applications/DataExplorer/VtkVis/VisualizationWidget.h
index 68aadb2abcf..68c9ae3e56e 100644
--- a/Applications/DataExplorer/VtkVis/VisualizationWidget.h
+++ b/Applications/DataExplorer/VtkVis/VisualizationWidget.h
@@ -32,7 +32,7 @@ class VisualizationWidget : public QWidget, public Ui_VisualizationWidgetBase
 public:
 
     /// @brief Constructor.
-    VisualizationWidget(QWidget* parent = 0);
+    VisualizationWidget(QWidget* parent = nullptr);
 
     /// @brief Destructor.
     ~VisualizationWidget();
diff --git a/Applications/DataExplorer/VtkVis/VtkAlgorithmProperties.h b/Applications/DataExplorer/VtkVis/VtkAlgorithmProperties.h
index 56be66388ad..418682932ad 100644
--- a/Applications/DataExplorer/VtkVis/VtkAlgorithmProperties.h
+++ b/Applications/DataExplorer/VtkVis/VtkAlgorithmProperties.h
@@ -140,7 +140,7 @@ class VtkAlgorithmProperties : public QObject
 
 public:
     /// Constructor (sets default values)
-    VtkAlgorithmProperties(QObject* parent = NULL);
+    VtkAlgorithmProperties(QObject* parent = nullptr);
 
     virtual ~VtkAlgorithmProperties();
 
diff --git a/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyCheckbox.h b/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyCheckbox.h
index 3ed35df96e3..4272845776a 100644
--- a/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyCheckbox.h
+++ b/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyCheckbox.h
@@ -31,7 +31,8 @@ public:
     /// @param algProps The VtkAlgorithmProperties object.
     /// @param parent The parent widget.
     VtkAlgorithmPropertyCheckbox(const bool value, const QString& name,
-                                 VtkAlgorithmProperties* algProps, QWidget* parent = 0);
+                                 VtkAlgorithmProperties* algProps,
+                                 QWidget* parent = nullptr);
 
     /// @brief Destructor.
     virtual ~VtkAlgorithmPropertyCheckbox();
diff --git a/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyLineEdit.h b/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyLineEdit.h
index 6045b33e291..9a7da243688 100644
--- a/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyLineEdit.h
+++ b/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyLineEdit.h
@@ -37,7 +37,7 @@ public:
                                  const QString& name,
                                  QVariant::Type type,
                                  VtkAlgorithmProperties* algProps,
-                                 QWidget* parent = 0);
+                                 QWidget* parent = nullptr);
     virtual ~VtkAlgorithmPropertyLineEdit();
 
 private:
diff --git a/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyVectorEdit.h b/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyVectorEdit.h
index c697818960a..209f02242c5 100644
--- a/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyVectorEdit.h
+++ b/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyVectorEdit.h
@@ -37,7 +37,7 @@ public:
                                    const QString& name,
                                    QVariant::Type type,
                                    VtkAlgorithmProperties* algProps,
-                                   QWidget* parent = 0);
+                                   QWidget* parent = nullptr);
     virtual ~VtkAlgorithmPropertyVectorEdit();
 
 private:
diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeColormapToImageFilter.cpp b/Applications/DataExplorer/VtkVis/VtkCompositeColormapToImageFilter.cpp
index 29d4cea5e64..c204bb0b8a2 100644
--- a/Applications/DataExplorer/VtkVis/VtkCompositeColormapToImageFilter.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkCompositeColormapToImageFilter.cpp
@@ -44,7 +44,7 @@ void VtkCompositeColormapToImageFilter::init()
 
     vtkSmartPointer<VtkColorLookupTable> colormap = vtkSmartPointer<VtkColorLookupTable>::New();
 
-    QWidget* parent = 0;
+    QWidget* parent = nullptr;
     QSettings settings;
     QString fileName = QFileDialog::getOpenFileName(parent, "Select color lookup table",
                                                     settings.value("lastOpenedLookupTableFileDirectory").toString(),
diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeElementSelectionFilter.cpp b/Applications/DataExplorer/VtkVis/VtkCompositeElementSelectionFilter.cpp
index 072576cc14c..133188ae9b0 100644
--- a/Applications/DataExplorer/VtkVis/VtkCompositeElementSelectionFilter.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkCompositeElementSelectionFilter.cpp
@@ -41,7 +41,7 @@ void VtkCompositeElementSelectionFilter::init()
     this->_outputDataObjectType = VTK_UNSTRUCTURED_GRID;
 
     this->SetLookUpTable(QString::fromStdString(_selection_name), this->GetLookupTable());
-     vtkSmartPointer<VtkAppendArrayFilter> selFilter (NULL);
+    vtkSmartPointer<VtkAppendArrayFilter> selFilter(nullptr);
     if (!_selection.empty())
     {
         selFilter = vtkSmartPointer<VtkAppendArrayFilter>::New();
diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeGeoObjectFilter.cpp b/Applications/DataExplorer/VtkVis/VtkCompositeGeoObjectFilter.cpp
index 9426aa2df05..53b3cb87df2 100644
--- a/Applications/DataExplorer/VtkVis/VtkCompositeGeoObjectFilter.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkCompositeGeoObjectFilter.cpp
@@ -39,11 +39,11 @@ VtkCompositeGeoObjectFilter::VtkCompositeGeoObjectFilter( vtkAlgorithm* inputAlg
       {
         vtkAlgorithm* parentAlg = ao->GetProducer();
 
-        if (dynamic_cast<VtkPolylinesSource*>(parentAlg) != NULL)
+        if (dynamic_cast<VtkPolylinesSource*>(parentAlg) != nullptr)
             _type = GeoLib::GEOTYPE::POLYLINE;
-        else if (dynamic_cast<VtkSurfacesSource*>(parentAlg) != NULL)
+        else if (dynamic_cast<VtkSurfacesSource*>(parentAlg) != nullptr)
             _type = GeoLib::GEOTYPE::SURFACE;
-        else if (dynamic_cast<VtkStationSource*>(parentAlg) != NULL)
+        else if (dynamic_cast<VtkStationSource*>(parentAlg) != nullptr)
         {
             /* TODO
             if (dynamic_cast<VtkStationSource*>(parentAlg)->getType() == GeoLib::Station::StationType::BOREHOLE)
diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeTextureOnSurfaceFilter.cpp b/Applications/DataExplorer/VtkVis/VtkCompositeTextureOnSurfaceFilter.cpp
index b4d355f453e..6861d716b29 100644
--- a/Applications/DataExplorer/VtkVis/VtkCompositeTextureOnSurfaceFilter.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkCompositeTextureOnSurfaceFilter.cpp
@@ -60,7 +60,7 @@ void VtkCompositeTextureOnSurfaceFilter::init()
     else
         surface->SetInputConnection(_inputAlgorithm->GetOutputPort());
 
-    QWidget* parent = 0;
+    QWidget* parent = nullptr;
     QSettings settings;
     QString fileName = QFileDialog::getOpenFileName(parent, "Select raster file to apply as texture",
                                                     settings.value("lastOpenedTextureFileDirectory").toString(),
@@ -84,7 +84,7 @@ void VtkCompositeTextureOnSurfaceFilter::init()
     {
         NetCdfConfigureDialog dlg(fileName.toStdString().c_str());
         dlg.exec();
-        if (dlg.getRaster() != NULL)
+        if (dlg.getRaster() != nullptr)
         {
             VtkGeoImageSource* image = dlg.getRaster();
             double origin[3];
diff --git a/Applications/DataExplorer/VtkVis/VtkFilterFactory.cpp b/Applications/DataExplorer/VtkVis/VtkFilterFactory.cpp
index e1b0e226cfa..22690d91875 100644
--- a/Applications/DataExplorer/VtkVis/VtkFilterFactory.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkFilterFactory.cpp
@@ -133,7 +133,7 @@ VtkCompositeFilter* VtkFilterFactory::CreateCompositeFilter( QString type,
         return new VtkCompositeGeoObjectFilter(inputAlgorithm);
 
     else
-        return NULL;
+        return nullptr;
 }
 
 vtkAlgorithm* VtkFilterFactory::CreateSimpleFilter( QString type )
@@ -143,5 +143,5 @@ vtkAlgorithm* VtkFilterFactory::CreateSimpleFilter( QString type )
     if (type.compare(QString("vtkDataSetSurfaceFilter")) == 0)
         return vtkDataSetSurfaceFilter::New();
 
-    return NULL;
+    return nullptr;
 }
diff --git a/Applications/DataExplorer/VtkVis/VtkGeoImageSource.cpp b/Applications/DataExplorer/VtkVis/VtkGeoImageSource.cpp
index 627b124b4b3..68e429f1564 100644
--- a/Applications/DataExplorer/VtkVis/VtkGeoImageSource.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkGeoImageSource.cpp
@@ -56,7 +56,7 @@ void vtkSimpleImageFilterExampleExecute(vtkImageData* input,
 }
 
 VtkGeoImageSource::VtkGeoImageSource()
-: _imageSource(NULL), _x0(0), _y0(0), _z0(0), _spacing(1)
+    : _imageSource(nullptr), _x0(0), _y0(0), _z0(0), _spacing(1)
 {
 }
 
diff --git a/Applications/DataExplorer/VtkVis/VtkPointsSource.cpp b/Applications/DataExplorer/VtkVis/VtkPointsSource.cpp
index 38b708709ed..1f0778dfeaf 100644
--- a/Applications/DataExplorer/VtkVis/VtkPointsSource.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkPointsSource.cpp
@@ -32,8 +32,7 @@
 
 vtkStandardNewMacro(VtkPointsSource);
 
-VtkPointsSource::VtkPointsSource()
-    : _points(NULL)
+VtkPointsSource::VtkPointsSource() : _points(nullptr)
 {
     _removable = false; // From VtkAlgorithmProperties
     this->SetNumberOfInputPorts(0);
diff --git a/Applications/DataExplorer/VtkVis/VtkPolylinesSource.cpp b/Applications/DataExplorer/VtkVis/VtkPolylinesSource.cpp
index bbefb00504d..a68bb576aa8 100644
--- a/Applications/DataExplorer/VtkVis/VtkPolylinesSource.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkPolylinesSource.cpp
@@ -36,8 +36,7 @@
 
 vtkStandardNewMacro(VtkPolylinesSource);
 
-VtkPolylinesSource::VtkPolylinesSource()
-    : _polylines(NULL)
+VtkPolylinesSource::VtkPolylinesSource() : _polylines(nullptr)
 {
     _removable = false; // From VtkAlgorithmProperties
     this->SetNumberOfInputPorts(0);
diff --git a/Applications/DataExplorer/VtkVis/VtkRaster.cpp b/Applications/DataExplorer/VtkVis/VtkRaster.cpp
index 1b5989b4b6a..7f289cff5d0 100644
--- a/Applications/DataExplorer/VtkVis/VtkRaster.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkRaster.cpp
@@ -109,7 +109,7 @@ vtkImageImport* VtkRaster::loadImageFromTIFF(const std::string &fileName,
         if (geoTiff)
         {
             int imgWidth = 0, imgHeight = 0, nImages = 0, pntCount = 0;
-            double* pnts = 0;
+            double* pnts = nullptr;
 
             // get actual number of images in the tiff file
             do {
diff --git a/Applications/DataExplorer/VtkVis/VtkStationSource.cpp b/Applications/DataExplorer/VtkVis/VtkStationSource.cpp
index 76721155567..0937fea68d6 100644
--- a/Applications/DataExplorer/VtkVis/VtkStationSource.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkStationSource.cpp
@@ -35,8 +35,7 @@
 
 vtkStandardNewMacro(VtkStationSource);
 
-VtkStationSource::VtkStationSource()
-    : _stations(NULL)
+VtkStationSource::VtkStationSource() : _stations(nullptr)
 {
     _removable = false; // From VtkAlgorithmProperties
     this->SetNumberOfInputPorts(0);
diff --git a/Applications/DataExplorer/VtkVis/VtkSurfacesSource.cpp b/Applications/DataExplorer/VtkVis/VtkSurfacesSource.cpp
index 45a6684c5ef..038be7b47e8 100644
--- a/Applications/DataExplorer/VtkVis/VtkSurfacesSource.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkSurfacesSource.cpp
@@ -32,8 +32,7 @@
 
 vtkStandardNewMacro(VtkSurfacesSource);
 
-VtkSurfacesSource::VtkSurfacesSource()
-    : _surfaces(NULL)
+VtkSurfacesSource::VtkSurfacesSource() : _surfaces(nullptr)
 {
     _removable = false; // From VtkAlgorithmProperties
     this->SetNumberOfInputPorts(0);
diff --git a/Applications/DataExplorer/VtkVis/VtkVisImageItem.cpp b/Applications/DataExplorer/VtkVis/VtkVisImageItem.cpp
index 1320f0ac251..275dcf32489 100644
--- a/Applications/DataExplorer/VtkVis/VtkVisImageItem.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkVisImageItem.cpp
@@ -38,16 +38,17 @@
 #include <vtkXMLImageDataWriter.h>
 
 VtkVisImageItem::VtkVisImageItem(
-        vtkAlgorithm* algorithm, TreeItem* parentItem,
-        const QList<QVariant> data /*= QList<QVariant>()*/)
-    : VtkVisPipelineItem(algorithm, parentItem, data), _transformFilter(NULL)
+    vtkAlgorithm* algorithm, TreeItem* parentItem,
+    const QList<QVariant> data /*= QList<QVariant>()*/)
+    : VtkVisPipelineItem(algorithm, parentItem, data), _transformFilter(nullptr)
 {
 }
 
 VtkVisImageItem::VtkVisImageItem(
-        VtkCompositeFilter* compositeFilter, TreeItem* parentItem,
-        const QList<QVariant> data /*= QList<QVariant>()*/)
-    : VtkVisPipelineItem(compositeFilter, parentItem, data), _transformFilter(NULL)
+    VtkCompositeFilter* compositeFilter, TreeItem* parentItem,
+    const QList<QVariant> data /*= QList<QVariant>()*/)
+    : VtkVisPipelineItem(compositeFilter, parentItem, data),
+      _transformFilter(nullptr)
 {
 }
 
@@ -109,7 +110,7 @@ void VtkVisImageItem::Initialize(vtkRenderer* renderer)
             newProps->SetTexture(parentProps->GetTexture());
             setVtkProperties(newProps);
             vtkProps = newProps;
-            parentItem = NULL;
+            parentItem = nullptr;
         }
         else
             parentItem = dynamic_cast<VtkVisPipelineItem*>(parentItem->parentItem());
@@ -127,7 +128,7 @@ void VtkVisImageItem::Initialize(vtkRenderer* renderer)
                     dynamic_cast<VtkVisPipelineItem*>(this->parentItem());
             if (visParentItem)
                 this->SetActiveAttribute(visParentItem->GetActiveAttribute());
-            if (vtkProps->GetTexture() != NULL)
+            if (vtkProps->GetTexture() != nullptr)
                 this->SetActiveAttribute("Solid Color");
         }
     }
diff --git a/Applications/DataExplorer/VtkVis/VtkVisPipeline.cpp b/Applications/DataExplorer/VtkVis/VtkVisPipeline.cpp
index 2b3d52aed62..2ecc975736b 100644
--- a/Applications/DataExplorer/VtkVis/VtkVisPipeline.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkVisPipeline.cpp
@@ -70,7 +70,7 @@ VtkVisPipeline::VtkVisPipeline( vtkRenderer* renderer, QObject* parent /*= 0*/ )
     QList<QVariant> rootData;
     rootData << "Object name" << "Visible";
     delete _rootItem;
-    _rootItem = new TreeItem(rootData, NULL);
+    _rootItem = new TreeItem(rootData, nullptr);
 
     QSettings settings;
     QVariant backgroundColorVariant = settings.value("VtkBackgroundColor");
@@ -112,7 +112,7 @@ vtkLight* VtkVisPipeline::getLight(const GeoLib::Point &pos) const
         if (pos[0] == lightPos[0] && pos[1] == lightPos[1] && pos[2] == lightPos[2])
             return *it;
     }
-    return NULL;
+    return nullptr;
 }
 
 void VtkVisPipeline::removeLight(const GeoLib::Point &pos)
@@ -286,7 +286,8 @@ QModelIndex VtkVisPipeline::addPipelineItem(VtkVisPipelineItem* item, const QMod
     if (!parent.isValid()) // Set global superelevation on source objects
     {
         QSettings settings;
-        if (dynamic_cast<vtkImageAlgorithm*>(item->algorithm()) == NULL) // if not an image
+        if (dynamic_cast<vtkImageAlgorithm*>(item->algorithm()) ==
+            nullptr)  // if not an image
             item->setScale(1.0, 1.0, settings.value("globalSuperelevation", 1.0).toDouble());
     }
 
@@ -338,7 +339,7 @@ QModelIndex VtkVisPipeline::addPipelineItem( vtkAlgorithm* source, QModelIndex p
     QList<QVariant> itemData;
     itemData << QString::fromStdString(itemName) << true;
 
-    VtkVisPipelineItem* item(NULL);
+    VtkVisPipelineItem* item(nullptr);
     if (dynamic_cast<vtkImageAlgorithm*>(source))
         item = new VtkVisImageItem(source, getItem(parent), itemData);
     else
diff --git a/Applications/DataExplorer/VtkVis/VtkVisPipeline.h b/Applications/DataExplorer/VtkVis/VtkVisPipeline.h
index 4c496755311..fad5e1cfede 100644
--- a/Applications/DataExplorer/VtkVis/VtkVisPipeline.h
+++ b/Applications/DataExplorer/VtkVis/VtkVisPipeline.h
@@ -57,7 +57,7 @@ class VtkVisPipeline : public TreeModel
     Q_OBJECT
 
 public:
-    VtkVisPipeline(vtkRenderer* renderer, QObject* parent = 0);
+    VtkVisPipeline(vtkRenderer* renderer, QObject* parent = nullptr);
 
     /// \brief Emits vtkVisPipelineChanged() and calls base class method.
     bool setData(const QModelIndex &index, const QVariant &value, int role = Qt::EditRole);
@@ -65,7 +65,7 @@ public:
     /// \brief Adds a light to the scene at the given coordinates.
     void addLight(const GeoLib::Point &pos);
 
-    /// \brief Returns a light (or NULL) for the given coordinates.
+    /// \brief Returns a light (or nullptr) for the given coordinates.
     vtkLight* getLight(const GeoLib::Point &pos) const;
 
     /// \brief Removes a light at the given coordinates (if possible).
diff --git a/Applications/DataExplorer/VtkVis/VtkVisPipelineItem.cpp b/Applications/DataExplorer/VtkVis/VtkVisPipelineItem.cpp
index 03c50e84d64..589e768e2a4 100644
--- a/Applications/DataExplorer/VtkVis/VtkVisPipelineItem.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkVisPipelineItem.cpp
@@ -45,10 +45,14 @@ extern FbxScene* lScene;
 #endif
 
 VtkVisPipelineItem::VtkVisPipelineItem(
-        vtkAlgorithm* algorithm, TreeItem* parentItem,
-        const QList<QVariant> data /*= QList<QVariant>()*/)
-    : TreeItem(data, parentItem),   _actor(NULL), _algorithm(algorithm),
-      _renderer(NULL), _compositeFilter(NULL), _vtkProps(NULL)
+    vtkAlgorithm* algorithm, TreeItem* parentItem,
+    const QList<QVariant> data /*= QList<QVariant>()*/)
+    : TreeItem(data, parentItem),
+      _actor(nullptr),
+      _algorithm(algorithm),
+      _renderer(nullptr),
+      _compositeFilter(nullptr),
+      _vtkProps(nullptr)
 {
     VtkVisPipelineItem* visParentItem = dynamic_cast<VtkVisPipelineItem*>(parentItem);
     if (parentItem->parentItem())
@@ -56,10 +60,13 @@ VtkVisPipelineItem::VtkVisPipelineItem(
 }
 
 VtkVisPipelineItem::VtkVisPipelineItem(
-        VtkCompositeFilter* compositeFilter, TreeItem* parentItem,
-        const QList<QVariant> data /*= QList<QVariant>()*/)
-    : TreeItem(data, parentItem), _actor(NULL), _renderer(NULL), _compositeFilter(compositeFilter),
-      _vtkProps(NULL)
+    VtkCompositeFilter* compositeFilter, TreeItem* parentItem,
+    const QList<QVariant> data /*= QList<QVariant>()*/)
+    : TreeItem(data, parentItem),
+      _actor(nullptr),
+      _renderer(nullptr),
+      _compositeFilter(compositeFilter),
+      _vtkProps(nullptr)
 {
     _algorithm = _compositeFilter->GetOutputAlgorithm();
 }
@@ -77,7 +84,7 @@ VtkVisPipelineItem* VtkVisPipelineItem::child( int row ) const
     if (treeItem)
         return dynamic_cast<VtkVisPipelineItem*>(treeItem);
     else
-        return NULL;
+        return nullptr;
 }
 
 QVariant VtkVisPipelineItem::data( int column ) const
@@ -138,7 +145,8 @@ int VtkVisPipelineItem::writeToFile(const std::string &filename) const
                 }
             }
             else
-                QMessageBox::warning(NULL, "Conversion to FBX not possible",
+                QMessageBox::warning(
+                    nullptr, "Conversion to FBX not possible",
                     "It is not possible to convert an vtkImageData based object \
                     to FBX. If you want to convert raster data import it via \" \
                     File / Import / Raster Files as PolyData\"!");
diff --git a/Applications/DataExplorer/VtkVis/VtkVisPipelineView.cpp b/Applications/DataExplorer/VtkVis/VtkVisPipelineView.cpp
index 60d23124016..b7484c60ca8 100644
--- a/Applications/DataExplorer/VtkVis/VtkVisPipelineView.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkVisPipelineView.cpp
@@ -85,8 +85,8 @@ void VtkVisPipelineView::contextMenuEvent( QContextMenuEvent* event )
         QMenu menu;
         QAction* addFilterAction = menu.addAction("Add filter...");
 
-        QAction* addLUTAction(NULL);
-        QAction* addMeshingAction(NULL);
+        QAction* addLUTAction(nullptr);
+        QAction* addMeshingAction(nullptr);
         if (objectType == VTK_IMAGE_DATA)
         {
             // this exception is needed as image object are only displayed in the vis-pipeline
@@ -101,7 +101,7 @@ void VtkVisPipelineView::contextMenuEvent( QContextMenuEvent* event )
             connect(addLUTAction, SIGNAL(triggered()), this, SLOT(addColorTable()));
         }
 
-        QAction* addConvertToMeshAction(NULL);
+        QAction* addConvertToMeshAction(nullptr);
         if (objectType == VTK_UNSTRUCTURED_GRID)
         {
             addConvertToMeshAction = menu.addAction("Convert to Mesh...");
@@ -113,7 +113,7 @@ void VtkVisPipelineView::contextMenuEvent( QContextMenuEvent* event )
 #ifdef VTKFBXCONVERTER_FOUND
         QAction* exportFbxAction = menu.addAction("Export as Fbx");
 #endif
-        QAction* removeAction = NULL;
+        QAction* removeAction = nullptr;
         if (!isSourceItem || vtkProps->IsRemovable())
         {
             menu.addSeparator();
@@ -209,8 +209,7 @@ void VtkVisPipelineView::convertVTKToOGSMesh()
         static_cast<VtkVisPipeline*>(this->model())->getItem(this->selectionModel()->currentIndex()));
     vtkSmartPointer<vtkAlgorithm> algorithm = item->algorithm();
 
-
-    vtkUnstructuredGrid* grid(NULL);
+    vtkUnstructuredGrid* grid(nullptr);
     vtkUnstructuredGridAlgorithm* ugAlg = vtkUnstructuredGridAlgorithm::SafeDownCast(algorithm);
     if (ugAlg)
         grid = ugAlg->GetOutput();
@@ -252,9 +251,9 @@ void VtkVisPipelineView::selectionChanged( const QItemSelection &selected,
     }
     else
     {
-        emit actorSelected(NULL);
-        emit itemSelected(NULL);
-        emit dataObjectSelected(NULL);
+        emit actorSelected(nullptr);
+        emit itemSelected(nullptr);
+        emit dataObjectSelected(nullptr);
     }
 }
 
@@ -300,8 +299,10 @@ void VtkVisPipelineView::addColorTable()
             }
         }
         else
-            QMessageBox::warning(NULL, "Color lookup table could not be applied.",
-                                 "Color lookup tables can only be applied to VtkVisPointSetItem.");
+            QMessageBox::warning(nullptr,
+                                 "Color lookup table could not be applied.",
+                                 "Color lookup tables can only be applied to "
+                                 "VtkVisPointSetItem.");
         QDir dir = QDir(filename);
         settings.setValue("lastOpenedLutFileDirectory", dir.absolutePath());
     }
diff --git a/Applications/DataExplorer/VtkVis/VtkVisPipelineView.h b/Applications/DataExplorer/VtkVis/VtkVisPipelineView.h
index cf93faf6725..6f8c9e15800 100644
--- a/Applications/DataExplorer/VtkVis/VtkVisPipelineView.h
+++ b/Applications/DataExplorer/VtkVis/VtkVisPipelineView.h
@@ -40,7 +40,7 @@ class VtkVisPipelineView : public QTreeView
 
 public:
     /// @brief Constructor.
-    VtkVisPipelineView(QWidget* parent = 0);
+    VtkVisPipelineView(QWidget* parent = nullptr);
 
     /// @brief Overridden to set model specific header properties.
     virtual void setModel(QAbstractItemModel* model);
diff --git a/Applications/DataExplorer/VtkVis/VtkVisTabWidget.cpp b/Applications/DataExplorer/VtkVis/VtkVisTabWidget.cpp
index 0a9b4a99ead..7d2e816ef95 100644
--- a/Applications/DataExplorer/VtkVis/VtkVisTabWidget.cpp
+++ b/Applications/DataExplorer/VtkVis/VtkVisTabWidget.cpp
@@ -233,8 +233,8 @@ void VtkVisTabWidget::buildProportiesDialog(VtkVisPipelineItem* item)
     while(layout->count())
         delete layout->takeAt(0)->widget();
 
-    QMap<QString, QVariant>* propMap = NULL;
-    QMap<QString, QList<QVariant> >* propVecMap = NULL;
+    QMap<QString, QVariant>* propMap = nullptr;
+    QMap<QString, QList<QVariant>>* propVecMap = nullptr;
     VtkAlgorithmProperties* algProps = item->getVtkProperties();
 
     if (algProps == nullptr)
diff --git a/Applications/DataExplorer/VtkVis/VtkVisTabWidget.h b/Applications/DataExplorer/VtkVis/VtkVisTabWidget.h
index d815a25ecc7..51e498fcc87 100644
--- a/Applications/DataExplorer/VtkVis/VtkVisTabWidget.h
+++ b/Applications/DataExplorer/VtkVis/VtkVisTabWidget.h
@@ -30,7 +30,7 @@ class VtkVisTabWidget : public QWidget, public Ui_VtkVisTabWidgetBase
 
 public:
     /// Constructor
-    VtkVisTabWidget(QWidget* parent = 0);
+    VtkVisTabWidget(QWidget* parent = nullptr);
 
 protected slots:
     /// Updates the property panels to show informations on the given VtkVisPipelineItem.
diff --git a/Applications/DataExplorer/main.cpp b/Applications/DataExplorer/main.cpp
index 6c0d9aa1112..256090d31c7 100644
--- a/Applications/DataExplorer/main.cpp
+++ b/Applications/DataExplorer/main.cpp
@@ -8,8 +8,8 @@
 #ifdef VTKFBXCONVERTER_FOUND
 #include <fbxsdk.h>
 #include "Common.h"
-FbxManager* lSdkManager = NULL;
-FbxScene* lScene = NULL;
+FbxManager* lSdkManager = nullptr;
+FbxScene* lScene = nullptr;
 #endif
 
 #include <vtkSmartPointer.h>
diff --git a/Applications/DataExplorer/mainwindow.cpp b/Applications/DataExplorer/mainwindow.cpp
index 5c826f142d2..a06e5158edf 100644
--- a/Applications/DataExplorer/mainwindow.cpp
+++ b/Applications/DataExplorer/mainwindow.cpp
@@ -926,8 +926,7 @@ void MainWindow::callGMSH(std::vector<std::string> & selectedGeometries,
                 gmsh_io.writeToFile(fileName.toStdString());
             }
 
-
-            if (system(NULL) != 0) // command processor available
+            if (system(nullptr) != 0)  // command processor available
             {
                 QSettings settings;
                 std::string gmsh_path = settings.value("DataExplorerGmshPath").toString().toStdString();
@@ -1245,7 +1244,7 @@ void MainWindow::startPresentationMode()
 
     // Move the widget to the screen and maximize it
     // Real fullscreen hides the menu
-    _vtkWidget->setParent(NULL, Qt::Window);
+    _vtkWidget->setParent(nullptr, Qt::Window);
     _vtkWidget->move(QPoint(_screenGeometries[screen].x(),
                             _screenGeometries[screen].y()));
     //_vtkWidget->showFullScreen();
diff --git a/Applications/DataExplorer/mainwindow.h b/Applications/DataExplorer/mainwindow.h
index 414359274e5..8a72d833ffd 100644
--- a/Applications/DataExplorer/mainwindow.h
+++ b/Applications/DataExplorer/mainwindow.h
@@ -45,7 +45,7 @@ class MainWindow : public QMainWindow, public Ui_MainWindowClass
     Q_OBJECT
 
 public:
-    MainWindow(QWidget* parent = 0);
+    MainWindow(QWidget* parent = nullptr);
 
     void ShowWindow();
     void HideWindow();
diff --git a/Applications/FileIO/AsciiRasterInterface.cpp b/Applications/FileIO/AsciiRasterInterface.cpp
index 495189c6e4f..4f6e3d78b51 100644
--- a/Applications/FileIO/AsciiRasterInterface.cpp
+++ b/Applications/FileIO/AsciiRasterInterface.cpp
@@ -54,8 +54,8 @@ GeoLib::Raster* AsciiRasterInterface::getRasterFromASCFile(std::string const& fn
             const std::size_t idx ((header.n_rows - j - 1) * header.n_cols);
             for (std::size_t i(0); i < header.n_cols; ++i) {
                 in >> s;
-                values[idx+i] = strtod(BaseLib::replaceString(",", ".", s).c_str(),0);
-
+                values[idx + i] = strtod(
+                    BaseLib::replaceString(",", ".", s).c_str(), nullptr);
             }
         }
         in.close();
@@ -87,26 +87,30 @@ bool AsciiRasterInterface::readASCHeader(std::ifstream &in, GeoLib::RasterHeader
     in >> tag;
     if (tag.compare("xllcorner") == 0 || tag.compare("xllcenter") == 0) {
         in >> value;
-        header.origin[0] = strtod(BaseLib::replaceString(",", ".", value).c_str(), 0);
+        header.origin[0] =
+            strtod(BaseLib::replaceString(",", ".", value).c_str(), nullptr);
     } else return false;
 
     in >> tag;
     if (tag.compare("yllcorner") == 0 || tag.compare("yllcenter") == 0) {
         in >> value;
-        header.origin[1] = strtod(BaseLib::replaceString(",", ".", value).c_str(), 0);
+        header.origin[1] =
+            strtod(BaseLib::replaceString(",", ".", value).c_str(), nullptr);
     } else return false;
     header.origin[2] = 0;
 
     in >> tag;
     if (tag.compare("cellsize") == 0) {
         in >> value;
-        header.cell_size = strtod(BaseLib::replaceString(",", ".", value).c_str(), 0);
+        header.cell_size =
+            strtod(BaseLib::replaceString(",", ".", value).c_str(), nullptr);
     } else return false;
 
     in >> tag;
     if (tag.compare("NODATA_value") == 0 || tag.compare("nodata_value") == 0) {
         in >> value;
-        header.no_data = strtod(BaseLib::replaceString(",", ".", value).c_str(), 0);
+        header.no_data =
+            strtod(BaseLib::replaceString(",", ".", value).c_str(), nullptr);
     } else return false;
 
     return true;
@@ -137,7 +141,8 @@ GeoLib::Raster* AsciiRasterInterface::getRasterFromSurferFile(std::string const&
             for (std::size_t i(0); i < header.n_cols; ++i)
             {
                 in >> s;
-                const double val (strtod(BaseLib::replaceString(",", ".", s).c_str(),0));
+                const double val(strtod(
+                    BaseLib::replaceString(",", ".", s).c_str(), nullptr));
                 values[idx+i] = (val > max || val < min) ? no_data_val : val;
             }
         }
diff --git a/Applications/FileIO/GMSInterface.cpp b/Applications/FileIO/GMSInterface.cpp
index 5ef41b250fb..0dd1370ff5c 100644
--- a/Applications/FileIO/GMSInterface.cpp
+++ b/Applications/FileIO/GMSInterface.cpp
@@ -42,7 +42,7 @@ int GMSInterface::readBoreholesFromGMS(std::vector<GeoLib::Point*>* boreholes,
     std::string line(""), cName(""), sName("");
     std::list<std::string>::const_iterator it;
     GeoLib::Point* pnt = new GeoLib::Point();
-    GeoLib::StationBorehole* newBorehole = NULL;
+    GeoLib::StationBorehole* newBorehole = nullptr;
     std::ifstream in( filename.c_str() );
 
     if (!in.is_open())
@@ -64,9 +64,9 @@ int GMSInterface::readBoreholesFromGMS(std::vector<GeoLib::Point*>* boreholes,
             if (fields.begin()->compare(cName) == 0) // add new layer
             {
                 it = fields.begin();
-                (*pnt)[0] = strtod((++it)->c_str(), 0);
-                (*pnt)[1] = strtod((++it)->c_str(), 0);
-                (*pnt)[2] = strtod((++it)->c_str(), 0);
+                (*pnt)[0] = strtod((++it)->c_str(), nullptr);
+                (*pnt)[1] = strtod((++it)->c_str(), nullptr);
+                (*pnt)[2] = strtod((++it)->c_str(), nullptr);
 
                 // check if current layer has a thickness of 0.0.
                 // if so skip it since it will mess with the vtk-visualisation later on!
@@ -85,16 +85,16 @@ int GMSInterface::readBoreholesFromGMS(std::vector<GeoLib::Point*>* boreholes,
             }
             else // add new borehole
             {
-                if (newBorehole != NULL)
+                if (newBorehole != nullptr)
                 {
                     newBorehole->setDepth((*newBorehole)[2] - depth);
                     boreholes->push_back(newBorehole);
                 }
                 cName = *fields.begin();
                 it = fields.begin();
-                (*pnt)[0] = strtod((++it)->c_str(), 0);
-                (*pnt)[1] = strtod((++it)->c_str(), 0);
-                (*pnt)[2] = strtod((++it)->c_str(), 0);
+                (*pnt)[0] = strtod((++it)->c_str(), nullptr);
+                (*pnt)[1] = strtod((++it)->c_str(), nullptr);
+                (*pnt)[2] = strtod((++it)->c_str(), nullptr);
                 sName = (*(++it));
                 newBorehole =
                         GeoLib::StationBorehole::createStation(cName, (*pnt)[0],
@@ -107,7 +107,7 @@ int GMSInterface::readBoreholesFromGMS(std::vector<GeoLib::Point*>* boreholes,
             ERR("GMSInterface::readBoreholeFromGMS(): Error reading format.");
     }
     // write the last borehole from the file
-    if (newBorehole != NULL)
+    if (newBorehole != nullptr)
     {
         newBorehole->setDepth((*newBorehole)[2] - depth);
         boreholes->push_back(newBorehole);
@@ -226,7 +226,7 @@ MeshLib::Mesh* GMSInterface::readGMS3DMMesh(const std::string &filename)
     if (!in.is_open())
     {
         ERR("GMSInterface::readGMS3DMMesh(): Could not open file %s.", filename.c_str());
-        return NULL;
+        return nullptr;
     }
 
     // Read data from file
@@ -234,7 +234,7 @@ MeshLib::Mesh* GMSInterface::readGMS3DMMesh(const std::string &filename)
     if (line.compare("MESH3D") != 0)
     {
         ERR("GMSInterface::readGMS3DMMesh(): Could not read expected file header.");
-        return NULL;
+        return nullptr;
     }
 
     INFO("GMSInterface::readGMS3DMMesh(): Read GMS-3DM mesh.");
@@ -314,7 +314,7 @@ MeshLib::Mesh* GMSInterface::readGMS3DMMesh(const std::string &filename)
         {
             WARN("GMSInterface::readGMS3DMMesh() - Element type \"%s\" not recognised.",
                  element_id.c_str());
-            return NULL;
+            return nullptr;
         }
     }
 
diff --git a/Applications/FileIO/Gmsh/GMSHAdaptiveMeshDensity.cpp b/Applications/FileIO/Gmsh/GMSHAdaptiveMeshDensity.cpp
index b8e42c1ff6d..202a16998a6 100644
--- a/Applications/FileIO/Gmsh/GMSHAdaptiveMeshDensity.cpp
+++ b/Applications/FileIO/Gmsh/GMSHAdaptiveMeshDensity.cpp
@@ -30,11 +30,13 @@ namespace FileIO
 {
 namespace GMSH
 {
-
-GMSHAdaptiveMeshDensity::GMSHAdaptiveMeshDensity(double pnt_density, double station_density,
-                                                 std::size_t max_pnts_per_leaf) :
-    _pnt_density(pnt_density), _station_density(station_density),
-    _max_pnts_per_leaf(max_pnts_per_leaf), _quad_tree(NULL)
+GMSHAdaptiveMeshDensity::GMSHAdaptiveMeshDensity(double pnt_density,
+                                                 double station_density,
+                                                 std::size_t max_pnts_per_leaf)
+    : _pnt_density(pnt_density),
+      _station_density(station_density),
+      _max_pnts_per_leaf(max_pnts_per_leaf),
+      _quad_tree(nullptr)
 {
 }
 
diff --git a/Applications/FileIO/Gmsh/GMSHPolygonTree.cpp b/Applications/FileIO/Gmsh/GMSHPolygonTree.cpp
index c45b9e14f14..cfbd9812ae3 100644
--- a/Applications/FileIO/Gmsh/GMSHPolygonTree.cpp
+++ b/Applications/FileIO/Gmsh/GMSHPolygonTree.cpp
@@ -336,7 +336,8 @@ void GMSHPolygonTree::writeSubPolygonsAsLineConstraints(std::size_t &line_offset
         dynamic_cast<GMSHPolygonTree*>((*it))->writeSubPolygonsAsLineConstraints(line_offset, sfc_number, out);
     }
 
-    if (_parent != NULL) {
+    if (_parent != nullptr)
+    {
         const std::size_t n_pnts(_node_polygon->getNumberOfPoints());
         std::size_t first_pnt_id(_node_polygon->getPointID(0)), second_pnt_id;
         for (std::size_t k(1); k<n_pnts; k++) {
diff --git a/Applications/FileIO/SHPInterface.cpp b/Applications/FileIO/SHPInterface.cpp
index c1589b7f95d..86614231434 100644
--- a/Applications/FileIO/SHPInterface.cpp
+++ b/Applications/FileIO/SHPInterface.cpp
@@ -262,7 +262,9 @@ bool SHPInterface::write2dMeshToSHP(const std::string &file_name, const MeshLib:
             DBFWriteIntegerAttribute(hDBF, polygon_id, node1_field, e->getNode(1)->getID());
             DBFWriteIntegerAttribute(hDBF, polygon_id, node2_field, e->getNode(2)->getID());
 
-            SHPObject *object = SHPCreateObject(SHPT_POLYGON, polygon_id++, 0, 0, NULL, ++nNodes, padfX, padfY, padfZ, NULL);
+            SHPObject* object =
+                SHPCreateObject(SHPT_POLYGON, polygon_id++, 0, nullptr, nullptr,
+                                ++nNodes, padfX, padfY, padfZ, nullptr);
             SHPWriteObject(hSHP, -1, object);
 
             // Note: cleaning up the coordinate arrays padfX, -Y, -Z results in a crash, I assume that shapelib removes them
diff --git a/BaseLib/RunTime.h b/BaseLib/RunTime.h
index 197ec678baf..295c06b51e8 100644
--- a/BaseLib/RunTime.h
+++ b/BaseLib/RunTime.h
@@ -40,7 +40,7 @@ class RunTime
 #else
 #ifndef _MSC_VER
             timeval t;
-            gettimeofday(&t, 0);
+            gettimeofday(&t, nullptr);
             _start_time = t.tv_sec + t.tv_usec/1000000.0;
 #else
             _start_time = timeGetTime();
@@ -56,7 +56,7 @@ class RunTime
 #else
 #ifndef _MSC_VER
             timeval t;
-            gettimeofday(&t, 0);
+            gettimeofday(&t, nullptr);
             return t.tv_sec + t.tv_usec/1000000.0 - _start_time;
 #else
             return (timeGetTime() - _start_time)/1000.0;
diff --git a/GeoLib/IO/Legacy/OGSIOVer4.cpp b/GeoLib/IO/Legacy/OGSIOVer4.cpp
index eb483416930..dc63160f446 100644
--- a/GeoLib/IO/Legacy/OGSIOVer4.cpp
+++ b/GeoLib/IO/Legacy/OGSIOVer4.cpp
@@ -174,7 +174,7 @@ std::string readPolyline(std::istream &in,
         if (line.find("$TYPE") != std::string::npos) // subkeyword found
         {
             in >> line; // read value
-            type = static_cast<std::size_t> (strtol(line.c_str(), NULL, 0));
+            type = static_cast<std::size_t>(strtol(line.c_str(), nullptr, 0));
         }
         //....................................................................
         if (line.find("$EPSILON") != std::string::npos) // subkeyword found
@@ -280,7 +280,7 @@ std::string readSurface(std::istream &in,
                         std::string const& path, std::vector<std::string>& errors)
 {
     std::string line;
-    GeoLib::Surface* sfc(NULL);
+    GeoLib::Surface* sfc(nullptr);
 
     int type (-1);
     std::string name;
@@ -301,7 +301,7 @@ std::string readSurface(std::istream &in,
         if (line.find("$TYPE") != std::string::npos) // subkeyword found
         {
             in >> line; // read value
-            type = strtol(line.c_str(), NULL, 0);
+            type = strtol(line.c_str(), nullptr, 0);
         }
         //....................................................................
         if (line.find("$EPSILON") != std::string::npos) // subkeyword found
diff --git a/GeoLib/IO/XmlIO/Qt/XmlGmlInterface.cpp b/GeoLib/IO/XmlIO/Qt/XmlGmlInterface.cpp
index 2aa89e4aa6e..e0f7d7fd1ed 100644
--- a/GeoLib/IO/XmlIO/Qt/XmlGmlInterface.cpp
+++ b/GeoLib/IO/XmlIO/Qt/XmlGmlInterface.cpp
@@ -124,7 +124,7 @@ void XmlGmlInterface::readPoints(const QDomNode &pointsRoot, std::vector<GeoLib:
         point = point.nextSiblingElement();
     }
 
-    // if names-map is empty, set it to NULL because it is not needed
+    // if names-map is empty, set it to nullptr because it is not needed
     if (pnt_names->empty())
     {
         delete pnt_names;
@@ -170,7 +170,7 @@ void XmlGmlInterface::readPolylines(const QDomNode &polylinesRoot,
         polyline = polyline.nextSiblingElement();
     }
 
-    // if names-map is empty, set it to NULL because it is not needed
+    // if names-map is empty, set it to nullptr because it is not needed
     if (ply_names->empty())
     {
         delete ply_names;
@@ -206,7 +206,7 @@ void XmlGmlInterface::readSurfaces(const QDomNode &surfacesRoot,
         surface = surface.nextSiblingElement();
     }
 
-    // if names-map is empty, set it to NULL because it is not needed
+    // if names-map is empty, set it to nullptr because it is not needed
     if (sfc_names->empty())
     {
         delete sfc_names;
diff --git a/GeoLib/IO/XmlIO/Qt/XmlStnInterface.cpp b/GeoLib/IO/XmlIO/Qt/XmlStnInterface.cpp
index 96b3872c613..bd401e9da98 100644
--- a/GeoLib/IO/XmlIO/Qt/XmlStnInterface.cpp
+++ b/GeoLib/IO/XmlIO/Qt/XmlStnInterface.cpp
@@ -388,7 +388,8 @@ void XmlStnInterface::rapidReadStations(const rapidxml::xml_node<>* station_root
         {
             double zVal(0.0);
             if (station_node->first_attribute("z"))
-                zVal = strtod(station_node->first_attribute("z")->value(), 0);
+                zVal = strtod(station_node->first_attribute("z")->value(),
+                              nullptr);
 
             std::string station_name(""), sensor_data_file_name(""), bdate_str("0000-00-00");
             double station_value(0.0), borehole_depth(0.0);
@@ -398,16 +399,19 @@ void XmlStnInterface::rapidReadStations(const rapidxml::xml_node<>* station_root
                 sensor_data_file_name =
                         station_node->first_node("sensordata")->value();
             if (station_node->first_node("value"))
-                station_value = strtod(station_node->first_node("value")->value(), 0);
+                station_value =
+                    strtod(station_node->first_node("value")->value(), nullptr);
             /* add other station features here */
 
             if (std::string(station_node->name()).compare("station") == 0)
             {
                 GeoLib::Station* s = new GeoLib::Station(
-                        strtod(station_node->first_attribute("x")->value(), 0),
-                        strtod(station_node->first_attribute("y")->value(), 0),
-                        zVal,
-                        station_name);
+                    strtod(station_node->first_attribute("x")->value(),
+                           nullptr),
+                    strtod(station_node->first_attribute("y")->value(),
+                           nullptr),
+                    zVal,
+                    station_name);
                 s->setStationValue(station_value);
                 if (!sensor_data_file_name.empty())
                     s->addSensorDataFromCSV(BaseLib::copyPathToFileName(
@@ -418,15 +422,19 @@ void XmlStnInterface::rapidReadStations(const rapidxml::xml_node<>* station_root
             else if (std::string(station_node->name()).compare("borehole") == 0)
             {
                 if (station_node->first_node("bdepth"))
-                    borehole_depth = strtod(station_node->first_node("bdepth")->value(), 0);
+                    borehole_depth = strtod(
+                        station_node->first_node("bdepth")->value(), nullptr);
                 if (station_node->first_node("bdate"))
                     bdate_str = station_node->first_node("bdate")->value();
                 /* add other borehole features here */
 
-                GeoLib::StationBorehole* s = GeoLib::StationBorehole::createStation(
+                GeoLib::StationBorehole* s =
+                    GeoLib::StationBorehole::createStation(
                         station_name,
-                        strtod(station_node->first_attribute("x")->value(), 0),
-                        strtod(station_node->first_attribute("y")->value(), 0),
+                        strtod(station_node->first_attribute("x")->value(),
+                               nullptr),
+                        strtod(station_node->first_attribute("y")->value(),
+                               nullptr),
                         zVal,
                         borehole_depth,
                         bdate_str);
@@ -459,13 +467,17 @@ void XmlStnInterface::rapidReadStratigraphy( const rapidxml::xml_node<>* strat_r
                 horizon_name = horizon_node->first_node("name")->value();
             /* add other horizon features here */
 
-            double depth (strtod(horizon_node->first_attribute("z")->value(), 0));
+            double depth(
+                strtod(horizon_node->first_attribute("z")->value(), nullptr));
             if (fabs(depth - depth_check) > std::numeric_limits<double>::epsilon()) // skip soil-layer if its thickness is zero
             {
-                borehole->addSoilLayer(strtod(horizon_node->first_attribute("x")->value(), 0),
-                                       strtod(horizon_node->first_attribute("y")->value(), 0),
-                                       depth,
-                                       horizon_name);
+                borehole->addSoilLayer(
+                    strtod(horizon_node->first_attribute("x")->value(),
+                           nullptr),
+                    strtod(horizon_node->first_attribute("y")->value(),
+                           nullptr),
+                    depth,
+                    horizon_name);
                 depth_check = depth;
             }
             else
diff --git a/GeoLib/IO/XmlIO/Rapid/RapidStnInterface.cpp b/GeoLib/IO/XmlIO/Rapid/RapidStnInterface.cpp
index a07d262f79b..9f5f55a630a 100644
--- a/GeoLib/IO/XmlIO/Rapid/RapidStnInterface.cpp
+++ b/GeoLib/IO/XmlIO/Rapid/RapidStnInterface.cpp
@@ -34,7 +34,7 @@ std::vector<GeoLib::Point*> *RapidStnInterface::readStationFile(const std::strin
     if (in.fail())
     {
         ERR("XmlStnInterface::rapidReadFile() - Can't open xml-file.");
-        return NULL;
+        return nullptr;
     }
 
     // buffer file
@@ -54,7 +54,7 @@ std::vector<GeoLib::Point*> *RapidStnInterface::readStationFile(const std::strin
     if (std::string(doc.first_node()->name()).compare("OpenGeoSysSTN") != 0)
     {
         ERR("XmlStnInterface::readFile() - Unexpected XML root.");
-        return NULL;
+        return nullptr;
     }
 
     // iterate over all station lists
@@ -146,7 +146,8 @@ void RapidStnInterface::readStations(const rapidxml::xml_node<>* station_root, s
         {
             double zVal(0.0);
             if (station_node->first_attribute("z"))
-                zVal = strtod(station_node->first_attribute("z")->value(), 0);
+                zVal = strtod(station_node->first_attribute("z")->value(),
+                              nullptr);
 
             std::string station_name(""), sensor_data_file_name(""), bdate_str("0000-00-00");
             double station_value(0.0), borehole_depth(0.0);
@@ -155,16 +156,19 @@ void RapidStnInterface::readStations(const rapidxml::xml_node<>* station_root, s
             if (station_node->first_node("sensordata"))
                 sensor_data_file_name = station_node->first_node("sensordata")->value();
             if (station_node->first_node("value"))
-                station_value = strtod(station_node->first_node("value")->value(), 0);
+                station_value =
+                    strtod(station_node->first_node("value")->value(), nullptr);
             /* add other station features here */
 
             if (std::string(station_node->name()).compare("station") == 0)
             {
                 GeoLib::Station* s = new GeoLib::Station(
-                            strtod(station_node->first_attribute("x")->value(), 0),
-                            strtod(station_node->first_attribute("y")->value(), 0),
-                            zVal,
-                            station_name);
+                    strtod(station_node->first_attribute("x")->value(),
+                           nullptr),
+                    strtod(station_node->first_attribute("y")->value(),
+                           nullptr),
+                    zVal,
+                    station_name);
                 s->setStationValue(station_value);
                 if (!sensor_data_file_name.empty())
                     s->addSensorDataFromCSV(BaseLib::copyPathToFileName(sensor_data_file_name, file_name));
@@ -173,15 +177,19 @@ void RapidStnInterface::readStations(const rapidxml::xml_node<>* station_root, s
             else if (std::string(station_node->name()).compare("borehole") == 0)
             {
                 if (station_node->first_node("bdepth"))
-                    borehole_depth = strtod(station_node->first_node("bdepth")->value(), 0);
+                    borehole_depth = strtod(
+                        station_node->first_node("bdepth")->value(), nullptr);
                 if (station_node->first_node("bdate"))
                     bdate_str = station_node->first_node("bdate")->value();
                 /* add other borehole features here */
 
-                GeoLib::StationBorehole* s = GeoLib::StationBorehole::createStation(
+                GeoLib::StationBorehole* s =
+                    GeoLib::StationBorehole::createStation(
                         station_name,
-                        strtod(station_node->first_attribute("x")->value(), 0),
-                        strtod(station_node->first_attribute("y")->value(), 0),
+                        strtod(station_node->first_attribute("x")->value(),
+                               nullptr),
+                        strtod(station_node->first_attribute("y")->value(),
+                               nullptr),
                         zVal,
                         borehole_depth,
                         bdate_str);
@@ -217,13 +225,17 @@ void RapidStnInterface::readStratigraphy( const rapidxml::xml_node<>* strat_root
                 horizon_name = horizon_node->first_node("name")->value();
             /* add other horizon features here */
 
-            double depth (strtod(horizon_node->first_attribute("z")->value(), 0));
+            double depth(
+                strtod(horizon_node->first_attribute("z")->value(), nullptr));
             if (fabs(depth - depth_check) > std::numeric_limits<double>::epsilon()) // skip soil-layer if its thickness is zero
             {
-                borehole->addSoilLayer(strtod(horizon_node->first_attribute("x")->value(), 0),
-                                       strtod(horizon_node->first_attribute("y")->value(), 0),
-                                       depth,
-                                       horizon_name);
+                borehole->addSoilLayer(
+                    strtod(horizon_node->first_attribute("x")->value(),
+                           nullptr),
+                    strtod(horizon_node->first_attribute("y")->value(),
+                           nullptr),
+                    depth,
+                    horizon_name);
                 depth_check = depth;
             }
             else
diff --git a/GeoLib/SensorData.cpp b/GeoLib/SensorData.cpp
index 04614f348d6..32c035b723f 100644
--- a/GeoLib/SensorData.cpp
+++ b/GeoLib/SensorData.cpp
@@ -140,7 +140,8 @@ int SensorData::readDataFromFile(const std::string &file_name)
             this->_time_steps.push_back(current_time_step);
 
             for (std::size_t i=0; i<nDataArrays; i++)
-                this->_data_vecs[i]->push_back(static_cast<float>(strtod((it++)->c_str(), 0)));
+                this->_data_vecs[i]->push_back(
+                    static_cast<float>(strtod((it++)->c_str(), nullptr)));
         }
         else
             return 0;
diff --git a/GeoLib/StationBorehole.cpp b/GeoLib/StationBorehole.cpp
index 24c05347380..fd11a39a4a5 100644
--- a/GeoLib/StationBorehole.cpp
+++ b/GeoLib/StationBorehole.cpp
@@ -123,7 +123,9 @@ int StationBorehole::addLayer(std::list<std::string> fields, StationBorehole* bo
             fields.pop_front();
 
             ERR("StationBorehole::addLayer - assuming correct order");
-            double thickness(strtod(BaseLib::replaceString(",", ".", fields.front()).c_str(), 0));
+            double thickness(
+                strtod(BaseLib::replaceString(",", ".", fields.front()).c_str(),
+                       nullptr));
             fields.pop_front();
             borehole->addSoilLayer(thickness, fields.front());
         }
@@ -178,8 +180,9 @@ int StationBorehole::addStratigraphies(const std::string &path, std::vector<Poin
                 fields.pop_front();
                 //the method just assumes that layers are read in correct order
                 fields.pop_front();
-                double thickness (strtod(BaseLib::replaceString(",", ".",
-                                                       fields.front()).c_str(), 0));
+                double thickness(strtod(
+                    BaseLib::replaceString(",", ".", fields.front()).c_str(),
+                    nullptr));
                 fields.pop_front();
                 std::string soil_name (fields.front());
                 fields.pop_front();
diff --git a/MeshLib/Elements/Element.h b/MeshLib/Elements/Element.h
index 1aefc52267a..3c39f55ff9c 100644
--- a/MeshLib/Elements/Element.h
+++ b/MeshLib/Elements/Element.h
@@ -62,7 +62,7 @@ public:
      * @param i local index of node, at most the number of nodes of the
      * element that you can obtain with Element::getNumberOfBaseNodes()
      * @return a pointer to the appropriate (and constant, i.e. not
-     * modifiable by the user) instance of class Node or a NULL pointer
+     * modifiable by the user) instance of class Node or a nullptr
      * @sa Element::getNodeIndex()
      */
     const Node* getNode(unsigned i) const;
diff --git a/MeshLib/IO/Legacy/MeshIO.cpp b/MeshLib/IO/Legacy/MeshIO.cpp
index f68335d9133..da3d5465407 100644
--- a/MeshLib/IO/Legacy/MeshIO.cpp
+++ b/MeshLib/IO/Legacy/MeshIO.cpp
@@ -251,7 +251,7 @@ MeshLib::Element* MeshIO::readElement(std::istream& in,
         break;
     }
     default:
-        elem = NULL;
+        elem = nullptr;
         break;
     }
 
diff --git a/MeshLib/Vtk/VtkMeshNodalCoordinatesTemplate-impl.h b/MeshLib/Vtk/VtkMeshNodalCoordinatesTemplate-impl.h
index 0d4364d08f9..1627200757e 100644
--- a/MeshLib/Vtk/VtkMeshNodalCoordinatesTemplate-impl.h
+++ b/MeshLib/Vtk/VtkMeshNodalCoordinatesTemplate-impl.h
@@ -44,9 +44,9 @@ template <class Scalar> void VtkMeshNodalCoordinatesTemplate<Scalar>
 template <class Scalar> void VtkMeshNodalCoordinatesTemplate<Scalar>
 ::Initialize()
 {
-    this->_nodes = NULL;
+    this->_nodes = nullptr;
     delete [] this->TempDoubleArray;
-    this->TempDoubleArray = NULL;
+    this->TempDoubleArray = nullptr;
     this->MaxId = -1;
     this->Size = 0;
     this->NumberOfComponents = 1;
@@ -114,7 +114,7 @@ template <class Scalar> vtkArrayIterator* VtkMeshNodalCoordinatesTemplate<Scalar
 ::NewIterator()
 {
     vtkErrorMacro(<<"Not implemented.");
-    return NULL;
+    return nullptr;
 }
 
 template <class Scalar> vtkIdType VtkMeshNodalCoordinatesTemplate<Scalar>
@@ -373,9 +373,9 @@ template <class Scalar> void VtkMeshNodalCoordinatesTemplate<Scalar>
     return;
 }
 
-template <class Scalar> VtkMeshNodalCoordinatesTemplate<Scalar>
-::VtkMeshNodalCoordinatesTemplate()
-    : _nodes(NULL), TempDoubleArray(NULL)
+template <class Scalar>
+VtkMeshNodalCoordinatesTemplate<Scalar>::VtkMeshNodalCoordinatesTemplate()
+    : _nodes(nullptr), TempDoubleArray(nullptr)
 {
 
 }
diff --git a/Tests/MeshLib/TestMoveMeshNodes.cpp b/Tests/MeshLib/TestMoveMeshNodes.cpp
index b1b940a9528..c6971f01235 100644
--- a/Tests/MeshLib/TestMoveMeshNodes.cpp
+++ b/Tests/MeshLib/TestMoveMeshNodes.cpp
@@ -19,7 +19,7 @@
 TEST(MeshLib, moveMeshNodes)
 {
     /* initialize random seed: */
-    srand ( static_cast<unsigned>(time(NULL)) );
+    srand(static_cast<unsigned>(time(nullptr)));
 
     std::size_t const size (16384);
 
-- 
GitLab