From 964e088979f153e4bf7d6a188d9bf3926c453d2e Mon Sep 17 00:00:00 2001 From: vsv Date: Mon, 25 Jun 2018 14:57:30 +0300 Subject: [PATCH] Extend precision up to 12 symbols after comma --- src/ModuleBase/ModuleBase_ParamSpinBox.cpp | 2 +- src/ModuleBase/ModuleBase_ParamSpinBox.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ModuleBase/ModuleBase_ParamSpinBox.cpp b/src/ModuleBase/ModuleBase_ParamSpinBox.cpp index 992e9dd26..08d373d5d 100644 --- a/src/ModuleBase/ModuleBase_ParamSpinBox.cpp +++ b/src/ModuleBase/ModuleBase_ParamSpinBox.cpp @@ -66,7 +66,7 @@ ModuleBase_ParamSpinBox::ModuleBase_ParamSpinBox(QWidget* theParent, int thePrec myValidator = new QDoubleValidator(this); myValidator->setLocale(locale()); myValidator->setRange(myMinimum, myMaximum); - myValidator->setDecimals(3); + myValidator->setDecimals(myPrecision); } void ModuleBase_ParamSpinBox::setCompletionList(QStringList& theList) diff --git a/src/ModuleBase/ModuleBase_ParamSpinBox.h b/src/ModuleBase/ModuleBase_ParamSpinBox.h index 696bf0cd7..09a10ca3c 100644 --- a/src/ModuleBase/ModuleBase_ParamSpinBox.h +++ b/src/ModuleBase/ModuleBase_ParamSpinBox.h @@ -51,7 +51,7 @@ public: \param theParent a parent object \param thePrecision a precision of values display */ - ModuleBase_ParamSpinBox( QWidget* theParent = 0, int thePrecision = -12 ); + ModuleBase_ParamSpinBox( QWidget* theParent = 0, int thePrecision = 12 ); /// Set list of completion strings void setCompletionList(QStringList&); -- 2.39.2