We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ae19eef commit 6e007bfCopy full SHA for 6e007bf
src/gui/editorwidgets/qgsrangewidget.cpp
@@ -43,9 +43,16 @@ QWidget* QgsRangeWidget::createWidget( QWidget* parent )
43
switch ( layer()->pendingFields()[fieldIdx()].type() )
44
{
45
case QVariant::Double:
46
- editor = new QDoubleSpinBox( parent );
+ {
47
+ QDoubleSpinBox* spin = new QDoubleSpinBox( parent );
48
+ int precision = layer()->pendingFields()[fieldIdx()].precision();
49
+ if ( precision > 0 )
50
51
+ spin->setDecimals( layer()->pendingFields()[fieldIdx()].precision() );
52
+ }
53
+ editor = spin;
54
break;
-
55
56
case QVariant::Int:
57
case QVariant::LongLong:
58
default:
0 commit comments