Kaydet (Commit) 7704f811 authored tarafından Laurent Balland-Poirier's avatar Laurent Balland-Poirier Kaydeden (comit) Noel Grandin

Trend line equation: remove useless defines

Change-Id: I9a2089f1f7e3b0e881d4136293d557efb3c1ef1c
Reviewed-on: https://gerrit.libreoffice.org/19001Reviewed-by: 's avatarNoel Grandin <noelgrandin@gmail.com>
Tested-by: 's avatarNoel Grandin <noelgrandin@gmail.com>
üst d721cc51
...@@ -26,9 +26,6 @@ ...@@ -26,9 +26,6 @@
#include <functional> #include <functional>
#include <vector> #include <vector>
#define UC_SPACE (sal_Unicode(' '))
#define UC_MINUS_SIGN (sal_Unicode('-'))
namespace chart namespace chart
{ {
namespace RegressionCalculationHelper namespace RegressionCalculationHelper
......
...@@ -141,12 +141,12 @@ OUString LogarithmicRegressionCurveCalculator::ImplGetRepresentation( ...@@ -141,12 +141,12 @@ OUString LogarithmicRegressionCurveCalculator::ImplGetRepresentation(
if( ::rtl::math::approxEqual( fabs( m_fSlope ), 1.0 )) if( ::rtl::math::approxEqual( fabs( m_fSlope ), 1.0 ))
{ {
if( m_fSlope < 0 ) if( m_fSlope < 0 )
aBuf.append( UC_MINUS_SIGN ); aBuf.append( "-" );
} }
else else
{ {
aBuf.append( getFormattedString( xNumFormatter, nNumberFormatKey, m_fSlope )); aBuf.append( getFormattedString( xNumFormatter, nNumberFormatKey, m_fSlope ));
aBuf.append( UC_SPACE ); aBuf.append( " " );
} }
aBuf.append( "ln(x)" ); aBuf.append( "ln(x)" );
bHaveSlope = true; bHaveSlope = true;
...@@ -156,9 +156,7 @@ OUString LogarithmicRegressionCurveCalculator::ImplGetRepresentation( ...@@ -156,9 +156,7 @@ OUString LogarithmicRegressionCurveCalculator::ImplGetRepresentation(
{ {
if( m_fIntercept < 0.0 ) if( m_fIntercept < 0.0 )
{ {
aBuf.append( UC_SPACE ); aBuf.append( " - " );
aBuf.append( UC_MINUS_SIGN );
aBuf.append( UC_SPACE );
aBuf.append( getFormattedString( xNumFormatter, nNumberFormatKey, fabs( m_fIntercept ))); aBuf.append( getFormattedString( xNumFormatter, nNumberFormatKey, fabs( m_fIntercept )));
} }
else if( m_fIntercept > 0.0 ) else if( m_fIntercept > 0.0 )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment