]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
Set 'CorrectToNearestValue' mode as default correction mode.
authorakl <akl@opencascade.com>
Fri, 25 Apr 2008 11:35:16 +0000 (11:35 +0000)
committerakl <akl@opencascade.com>
Fri, 25 Apr 2008 11:35:16 +0000 (11:35 +0000)
src/Qtx/QtxIntSpinBox.cxx

index 175a297ae73ccc829c7e96dd6e60aef03b918d90..b4cff2238432cb09041f9060a5e200e1b87eaac8 100755 (executable)
@@ -57,6 +57,7 @@ QtxIntSpinBox::QtxIntSpinBox( QWidget* parent )
 : QSpinBox( parent ),
   myCleared( false )
 {
+  setCorrectionMode( QSpinBox::CorrectToNearestValue );
   connect( lineEdit(), SIGNAL( textChanged( const QString& ) ), 
           this, SLOT( onTextChanged( const QString& ) ) );
 }
@@ -79,6 +80,7 @@ QtxIntSpinBox::QtxIntSpinBox( int min, int max, int step, QWidget* parent )
   setMinimum( min );
   setMaximum( max );
   setSingleStep( step );
+  setCorrectionMode( QSpinBox::CorrectToNearestValue );
 
   connect( lineEdit(), SIGNAL( textChanged( const QString& ) ), 
           this, SLOT( onTextChanged( const QString& ) ) );