#18319 [CEA 18318] Display of a field with negative value

This commit is contained in:
vsr 2019-11-18 14:12:24 +03:00
parent c9d3c88044
commit 4784596a38

View File

@ -2900,7 +2900,10 @@ QList<QVariant> GEOM_Displayer::groupFieldData( const QList<QVariant>& theFieldS
aValue = double( aVariant.toLongLong() );
else if( aVariant.type() == QVariant::Double )
aValue = aVariant.toDouble();
if ( theFieldNbComponents > 1 )
aNorm += aValue * aValue;
else
aNorm += aValue;
}
}
}
@ -2911,7 +2914,7 @@ QList<QVariant> GEOM_Displayer::groupFieldData( const QList<QVariant>& theFieldS
{
if( anIsBoolean )
aNorm /= theFieldNbComponents;
else
else if ( theFieldNbComponents > 1 )
aNorm = pow( aNorm, 0.5 );
if( aGroupedList.isEmpty() )