From 9ded297cb0075c49d43c40437264a99b11f9ddb7 Mon Sep 17 00:00:00 2001
From: Joachim Wuttke <j.wuttke@fz-juelich.de>
Date: Sun, 3 Dec 2023 17:12:37 +0100
Subject: [PATCH 1/2] Detector2D simpler arg name

---
 Device/Detector/Detector2D.cpp | 10 +++++-----
 Device/Detector/Detector2D.h   |  4 ++--
 2 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/Device/Detector/Detector2D.cpp b/Device/Detector/Detector2D.cpp
index 1df83444d00..d4885b70e74 100644
--- a/Device/Detector/Detector2D.cpp
+++ b/Device/Detector/Detector2D.cpp
@@ -24,13 +24,13 @@
 
 using std::numbers::pi;
 
-Detector2D::Detector2D(double phi_full_width, double alpha_full_width, size_t n_phi, size_t n_alpha,
+Detector2D::Detector2D(double phi_span, double alpha_span, size_t n_phi, size_t n_alpha,
                        double phi_center, double alpha_center)
     : IDetector(
-        new Frame(newEquiDivision("phi_f (rad)", n_phi, phi_center - phi_full_width / 2,
-                                  phi_center + phi_full_width / 2),
-                  newEquiDivision("alpha_f (rad)", n_alpha, alpha_center - alpha_full_width / 2,
-                                  alpha_center + alpha_full_width / 2)))
+        new Frame(newEquiDivision("phi_f (rad)", n_phi, phi_center - phi_span / 2,
+                                  phi_center + phi_span / 2),
+                  newEquiDivision("alpha_f (rad)", n_alpha, alpha_center - alpha_span / 2,
+                                  alpha_center + alpha_span / 2)))
 {
     ASSERT(-pi / 2 < axis(0).min() && axis(0).max() < +pi / 2);
     ASSERT(-pi / 2 < axis(1).min() && axis(1).max() < +pi / 2);
diff --git a/Device/Detector/Detector2D.h b/Device/Detector/Detector2D.h
index ba03919eeb3..954bf7603b3 100644
--- a/Device/Detector/Detector2D.h
+++ b/Device/Detector/Detector2D.h
@@ -21,8 +21,8 @@ class Pixel;
 
 class Detector2D : public IDetector {
 public:
-    Detector2D(double phi_full_width, double alpha_full_width, size_t n_phi, size_t n_alpha,
-               double center_phi, double center_alpha);
+    Detector2D(double phi_span, double alpha_span, size_t n_phi, size_t n_alpha,
+               double phi_center, double alpha_center);
 
     ~Detector2D() override = default;
 
-- 
GitLab


From 853d586726817ddf7c587dfae5547a2b73f2aca2 Mon Sep 17 00:00:00 2001
From: Joachim Wuttke <j.wuttke@fz-juelich.de>
Date: Sun, 3 Dec 2023 17:16:57 +0100
Subject: [PATCH 2/2] clang-format

---
 Device/Detector/Detector2D.cpp | 9 ++++-----
 Device/Detector/Detector2D.h   | 4 ++--
 2 files changed, 6 insertions(+), 7 deletions(-)

diff --git a/Device/Detector/Detector2D.cpp b/Device/Detector/Detector2D.cpp
index d4885b70e74..71cd41c65ac 100644
--- a/Device/Detector/Detector2D.cpp
+++ b/Device/Detector/Detector2D.cpp
@@ -26,11 +26,10 @@ using std::numbers::pi;
 
 Detector2D::Detector2D(double phi_span, double alpha_span, size_t n_phi, size_t n_alpha,
                        double phi_center, double alpha_center)
-    : IDetector(
-        new Frame(newEquiDivision("phi_f (rad)", n_phi, phi_center - phi_span / 2,
-                                  phi_center + phi_span / 2),
-                  newEquiDivision("alpha_f (rad)", n_alpha, alpha_center - alpha_span / 2,
-                                  alpha_center + alpha_span / 2)))
+    : IDetector(new Frame(
+        newEquiDivision("phi_f (rad)", n_phi, phi_center - phi_span / 2, phi_center + phi_span / 2),
+        newEquiDivision("alpha_f (rad)", n_alpha, alpha_center - alpha_span / 2,
+                        alpha_center + alpha_span / 2)))
 {
     ASSERT(-pi / 2 < axis(0).min() && axis(0).max() < +pi / 2);
     ASSERT(-pi / 2 < axis(1).min() && axis(1).max() < +pi / 2);
diff --git a/Device/Detector/Detector2D.h b/Device/Detector/Detector2D.h
index 954bf7603b3..de7c57323c1 100644
--- a/Device/Detector/Detector2D.h
+++ b/Device/Detector/Detector2D.h
@@ -21,8 +21,8 @@ class Pixel;
 
 class Detector2D : public IDetector {
 public:
-    Detector2D(double phi_span, double alpha_span, size_t n_phi, size_t n_alpha,
-               double phi_center, double alpha_center);
+    Detector2D(double phi_span, double alpha_span, size_t n_phi, size_t n_alpha, double phi_center,
+               double alpha_center);
 
     ~Detector2D() override = default;
 
-- 
GitLab