diff --git a/GUI/Model/Descriptor/DoubleProperty.cpp b/GUI/Model/Descriptor/DoubleProperty.cpp index c19a0e9462c34a4bbac5f60f3d996dccaad4bd83..190df5a907baec7106f8635bf8a13ab4fe097bc1 100644 --- a/GUI/Model/Descriptor/DoubleProperty.cpp +++ b/GUI/Model/Descriptor/DoubleProperty.cpp @@ -37,12 +37,6 @@ void DoubleProperty::init(const QString& label, const QString& tooltip, double v } -void DoubleProperty::init(const QString& label, const QString& tooltip, double value, - const variant<QString, Unit>& unit, const QString& uidPrefix) -{ - init(label, tooltip, value, unit, 3, RealLimits::nonnegative(), uidPrefix); -} - void DoubleProperty::init(const QString& label, const QString& tooltip, double value, const variant<QString, Unit>& unit, uint decimals, const RealLimits& limits, const QString& uidPrefix) diff --git a/GUI/Model/Descriptor/DoubleProperty.h b/GUI/Model/Descriptor/DoubleProperty.h index 8faa2680fc9a3ac1757c83139138c83c4700e9fb..9e2a50d655b45e2224a83c4769545f1f7c9b56f7 100644 --- a/GUI/Model/Descriptor/DoubleProperty.h +++ b/GUI/Model/Descriptor/DoubleProperty.h @@ -37,6 +37,7 @@ //! also when serializing the link. Right now, this uid is a UUID. class DoubleProperty { +private: public: void init(const QString& label, const QString& tooltip, double value, const QString& uidPrefix); void init(const QString& label, const QString& tooltip, double value, uint decimals, @@ -44,8 +45,6 @@ public: void init(const QString& label, const QString& tooltip, double value, uint decimals, double step, const RealLimits& limits, const QString& uidPrefix); - void init(const QString& label, const QString& tooltip, double value, - const std::variant<QString, Unit>& unit, const QString& uidPrefix); void init(const QString& label, const QString& tooltip, double value, const std::variant<QString, Unit>& unit, uint decimals, const RealLimits& limits, const QString& uidPrefix); diff --git a/GUI/Model/Detector/DetectorItem.cpp b/GUI/Model/Detector/DetectorItem.cpp index 14e220a4845250de7e07f7b9839f01cc16aaf859..4b2c95c8bbc95bfcb6a35af456e4e18c1b47c46f 100644 --- a/GUI/Model/Detector/DetectorItem.cpp +++ b/GUI/Model/Detector/DetectorItem.cpp @@ -56,9 +56,9 @@ DetectorItem::DetectorItem() m_xSize = 100; m_ySize = 100; - m_width.init("Width (x-axis)", "Width of the detector", default_detector_width, "mm", + m_width.init("Width (mm)", "Width of the detector", default_detector_width, 3 /* decimals */, RealLimits::positive(), "width"); - m_height.init("Height (y-axis)", "Height of the detector", default_detector_height, "mm", + m_height.init("Height (mm)", "Height of the detector", default_detector_height, 3 /* decimals */, RealLimits::positive(), "height"); m_normalVector.init( @@ -71,11 +71,11 @@ DetectorItem::DetectorItem() "directionVector"); m_directionVector.setY(-1.0); - m_u0.init("u0", "", default_detector_width / 2., "mm", 3 /* decimals */, + m_u0.init("u0 (mm)", "", default_detector_width / 2., 3 /* decimals */, RealLimits::limitless(), "u0"); - m_v0.init("v0", "", 0.0, "mm", 3 /* decimals */, RealLimits::limitless(), "v0"); - m_distance.init("Distance", "Distance from the sample origin to the detector plane", - default_detector_distance, "mm", "distance"); + m_v0.init("v0 (mm)", "", 0.0, 3 /* decimals */, RealLimits::limitless(), "v0"); + m_distance.init("Distance (mm)", "Distance from the sample origin to the detector plane", + default_detector_distance, "distance"); m_detectorAlignment = ComboProperty::fromList(alignment_names_map.values(), alignment_names_map.value(FlatDetector::T));