Skip to content

Commit

Permalink
small fix in formatUnits
Browse files Browse the repository at this point in the history
  • Loading branch information
VitorVieiraZ committed Oct 18, 2024
1 parent 7a7deb4 commit 7afd49f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/inpututils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ QString InputUtils::formatDistanceHelper( const double distanceInMeters, int pre
const double distance = distanceInMeters * factor;
const QString abbreviation = QgsUnitTypes::toAbbreviatedString( destUnit );

return QString( "%L1 %2" ).arg( distance, 0, 'f', precision ).arg( abbreviation );
return QString( "%L1 %2" ).arg( QString::number( distance, 'f', precision ), abbreviation );
}

QString InputUtils::formatAreaInProjectUnit( const double areaInSquareMeters, int precision, QgsProject *project )
Expand All @@ -209,7 +209,7 @@ QString InputUtils::formatAreaHelper( const double areaInSquareMeters, int preci
const double area = areaInSquareMeters * factor;
const QString abbreviation = QgsUnitTypes::toAbbreviatedString( destUnit );

return QString( "%L1 %2" ).arg( area, 0, 'f', precision ).arg( abbreviation );
return QString( "%L1 %2" ).arg( QString::number( area, 'f', precision ), abbreviation );
}

QString InputUtils::formatDateTimeDiff( const QDateTime &tMin, const QDateTime &tMax )
Expand Down

1 comment on commit 7afd49f

@inputapp-bot
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

iOS - version 24.10.686911 just submitted!

Please sign in to comment.