TAChart: Move ExpandRange procedure to TAMath unit

git-svn-id: trunk@32699 -
This commit is contained in:
ask 2011-10-05 10:03:34 +00:00
parent f69330e51e
commit 9c33a8ec42
5 changed files with 14 additions and 14 deletions

View File

@ -265,8 +265,6 @@ procedure Exchange(var A, B: Double); overload; inline;
procedure Exchange(var A, B: TDoublePoint); overload; inline;
procedure Exchange(var A, B: String); overload; inline;
procedure ExpandRange(var ALo, AHi: Double; ACoeff: Double); inline;
function FormatIfNotEmpty(AFormat, AStr: String): String; inline;
function InterpolateRGB(AColor1, AColor2: Integer; ACoeff: Double): Integer;
@ -359,15 +357,6 @@ begin
B := t;
end;
procedure ExpandRange(var ALo, AHi: Double; ACoeff: Double);
var
d: Double;
begin
d := AHi - ALo;
ALo -= d * ACoeff;
AHi += d * ACoeff;
end;
function FormatIfNotEmpty(AFormat, AStr: String): String;
begin
if AStr = '' then

View File

@ -29,6 +29,8 @@ function InvCumulNormDistr(AX: Double): Double;
procedure EnsureOrder(var A, B: Integer); overload; inline;
procedure EnsureOrder(var A, B: Double); overload; inline;
procedure ExpandRange(var ALo, AHi: Double; ACoeff: Double);
function SafeInfinity: Double; inline;
function SafeInRange(AValue, ABound1, ABound2: Double): Boolean;
function SafeMin(A, B: Double): Double;
@ -131,6 +133,15 @@ begin
Exchange(A, B);
end;
procedure ExpandRange(var ALo, AHi: Double; ACoeff: Double);
var
d: Double;
begin
d := AHi - ALo;
ALo -= d * ACoeff;
AHi += d * ACoeff;
end;
function SafeInfinity: Double;
begin
{$PUSH}{$R-}{$Q-}

View File

@ -151,7 +151,7 @@ type
implementation
uses
Math, SysUtils, TAGeometry, TAGraph;
Math, SysUtils, TAGeometry, TAGraph, TAMath;
type

View File

@ -320,7 +320,7 @@ implementation
uses
GraphMath, LResources, Math, PropEdits, SysUtils,
TADrawerCanvas, TAGeometry, TAGraph;
TADrawerCanvas, TAGeometry, TAGraph, TAMath;
{ TLineSeries }

View File

@ -469,7 +469,7 @@ implementation
uses
Forms, GraphMath, InterfaceBase, Math, SysUtils,
TACustomSeries, TADrawerCanvas, TAEnumerators, TAGeometry;
TACustomSeries, TADrawerCanvas, TAEnumerators, TAGeometry, TAMath;
function InitBuitlinTools(AChart: TChart): TBasicChartToolset;
var