Skip to content

Commit

Permalink
Fix for not resetting numberOf(left)Segments when switching scalebar …
Browse files Browse the repository at this point in the history
…unit
  • Loading branch information
rduivenvoorde authored and nyalldawson committed Aug 17, 2021
1 parent f8317f6 commit 25b43f5
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/gui/layout/qgslayoutscalebarwidget.cpp
Expand Up @@ -650,6 +650,8 @@ void QgsLayoutScaleBarWidget::mUnitsComboBox_currentIndexChanged( int index )
mScalebar->applyDefaultSize( static_cast< QgsUnitTypes::DistanceUnit >( unitData.toInt() ) );
mScalebar->update();

mNumberOfSegmentsSpinBox->setValue( mScalebar->numberOfSegments() );
mSegmentsLeftSpinBox->setValue( mScalebar->numberOfSegmentsLeft() );
mUnitLabelLineEdit->setText( mScalebar->unitLabel() );
mSegmentSizeSpinBox->setValue( mScalebar->unitsPerSegment() );
mMapUnitsPerBarUnitSpinBox->setValue( mScalebar->mapUnitsPerScaleBarUnit() );
Expand Down

0 comments on commit 25b43f5

Please sign in to comment.