Merged revision(s) 59197 #a88125b782 from trunk:

TAChart: deprecate all reticule-related methods and properties (was incomplete). Less hints and warnings.
........

git-svn-id: branches/fixes_2_0@59204 -
This commit is contained in:
maxim 2018-09-30 22:49:09 +00:00
parent c24c009636
commit 2f7d13cd91
7 changed files with 19 additions and 18 deletions

View File

@ -780,6 +780,8 @@ var
i : ArbInt;
dks : array of ArbFloat;
begin
Assert(hst <> hstMonotone);
term:=1;
if n < 1 then
begin

View File

@ -268,7 +268,7 @@ type
procedure SetMarkPositions(AValue: TLinearMarkPositions);
procedure SetPointer(AValue: TSeriesPointer);
procedure SetStacked(AValue: Boolean);
procedure SetUseReticule(AValue: Boolean);
procedure SetUseReticule(AValue: Boolean); deprecated 'Use DatapointCrosshairTool instead';
strict protected
FGraphPoints: array of TDoublePoint;
FLoBound: Integer;
@ -337,6 +337,7 @@ type
property ToolTargets default [nptPoint, nptYList];
property UseReticule: Boolean
read FUseReticule write SetUseReticule default false;
deprecated 'Use DatapointCrosshairTool instead';
property ExtentPointIndexFirst: Integer read FLoBound;
property ExtentPointIndexLast: Integer read FUpBound;
end;

View File

@ -60,7 +60,7 @@ function LinearFit(const x, y, dy: TArbFloatArray;
FitParams: TFitParamArray): TFitResults;
// Some basic fit basis functions for linear least-squares fitting
function FitBaseFunc_Const(x: ArbFloat; Param: Integer): ArbFloat;
function FitBaseFunc_Const({%H-}x: ArbFloat; {%H-}Param: Integer): ArbFloat;
function FitBaseFunc_Linear(x: ArbFloat; {%H-}Param: Integer): ArbFloat;
function FitBaseFunc_Square(x: ArbFloat; {%H-}Param: Integer): ArbFloat;
function FitBaseFunc_Cube(x: ArbFloat; {%H-}Param: Integer): ArbFloat;
@ -212,7 +212,7 @@ var
n, m, mfit: Integer;
i, j, k, jk, kj: Integer;
hasSig: Boolean;
ym, wt, sig2, totalsig2, chi2: ArbFloat;
ym, wt, sig2, chi2: ArbFloat;
ca: ArbFloat = 0.0;
term: ArbInt = 0;
begin

View File

@ -1513,6 +1513,7 @@ end;
comprehensive property "FitStatistics".}
function TFitSeries.CalcGoodnessOfFit(var x,y: ArbFloat; n: Integer): Double;
begin
Unused(x, y, n);
Result := FFitStatistics.R2;
end;
@ -1645,13 +1646,12 @@ var
procedure TryFit;
var
i, j, ns, np, n: Integer;
i, j, ns, n: Integer;
xv, yv, dy: array of ArbFloat;
yp, yn: Double;
fitRes: TFitResults;
hasErrorBars: Boolean;
begin
np := ParamCount;
ns := Source.Count;
CalcXRange(xmin, xmax);
@ -1731,11 +1731,9 @@ end;
procedure TFitSeries.GetConfidenceLimits(AIndex: Integer; out ALower, AUpper: Double);
var
val, sig, t: Double;
alpha: Double;
begin
val := GetParam_RawValue(AIndex);
sig := GetParam_RawError(AIndex);
alpha := 1.0 - FConfidenceLevel;
t := FitStatistics.tValue;
ALower := val - sig*t;
AUpper := val + sig*t;

View File

@ -244,7 +244,7 @@ type
FClipRectLock: Integer;
procedure CalculateTransformationCoeffs(const AMargin: TRect);
procedure DrawReticule(ADrawer: IChartDrawer);
procedure DrawReticule(ADrawer: IChartDrawer); deprecated 'Use DatapointCrosshairTool instead';
procedure FindComponentClass(
AReader: TReader; const AClassName: String; var AClass: TComponentClass);
function GetChartHeight: Integer;
@ -253,7 +253,7 @@ type
function GetRenderingParams: TChartRenderingParams;
function GetSeriesCount: Integer;
function GetToolset: TBasicChartToolset;
procedure HideReticule;
procedure HideReticule; deprecated 'Use DatapointCrosshairTool instead';
procedure SetAntialiasingMode(AValue: TChartAntialiasingMode);
procedure SetAxisList(AValue: TChartAxisList);
@ -281,11 +281,11 @@ type
procedure SetOnBeforeDrawBackWall(AValue: TChartBeforeDrawEvent);
procedure SetOnChartPaint(AValue: TChartPaintEvent);
procedure SetOnDrawLegend(AValue: TChartDrawLegendEvent);
procedure SetOnDrawReticule(AValue: TDrawReticuleEvent);
procedure SetOnDrawReticule(AValue: TDrawReticuleEvent); deprecated 'Use DatapointCrosshairTool instead';
procedure SetProportional(AValue: Boolean);
procedure SetRenderingParams(AValue: TChartRenderingParams);
procedure SetReticuleMode(AValue: TReticuleMode);
procedure SetReticulePos(const AValue: TPoint);
procedure SetReticuleMode(AValue: TReticuleMode); deprecated 'Use DatapointCrosshairTool instead';
procedure SetReticulePos(const AValue: TPoint); deprecated 'Use DatapointCrosshairTool instead';
procedure SetTitle(Value: TChartTitle);
procedure SetToolset(AValue: TBasicChartToolset);
procedure VisitSources(
@ -388,7 +388,7 @@ type
property PrevLogicalExtent: TDoubleRect read FPrevLogicalExtent;
property RenderingParams: TChartRenderingParams
read GetRenderingParams write SetRenderingParams;
property ReticulePos: TPoint read FReticulePos write SetReticulePos; deprecated;
property ReticulePos: TPoint read FReticulePos write SetReticulePos; deprecated 'Use DatapointCrosshairTool instead';
property SeriesCount: Integer read GetSeriesCount;
property XGraphMax: Double read FCurrentExtent.b.X;
property XGraphMin: Double read FCurrentExtent.a.X;

View File

@ -119,7 +119,7 @@ begin
expanded_data[2*(i + j*ATextureWidth) + 1] := 0 // Alpha
else begin
c := FImg.Colors[i,j];
expanded_data[2*(i + j*ATextureWidth) + 1] := FImg.Colors[i, j].Alpha shr 8;
expanded_data[2*(i + j*ATextureWidth) + 1] := c.Alpha shr 8;
end;
end;

View File

@ -101,7 +101,7 @@ type
property Stacked default true;
property Styles;
property ToolTargets default [nptPoint, nptYList, nptCustom];
property UseReticule;
property UseReticule; deprecated 'Use DatapointCrosshairTool instead';
property ZeroLevel: Double
read FZeroLevel write SetZeroLevel stored IsZeroLevelStored;
published
@ -177,7 +177,7 @@ type
property Stacked default true;
property Styles;
property ToolTargets;
property UseReticule;
property UseReticule; deprecated 'Use DatapointCrosshairTool instead';
property UseZeroLevel: Boolean
read FUseZeroLevel write SetUseZeroLevel default false;
property ZeroLevel: Double
@ -242,7 +242,7 @@ type
property Source;
property Styles;
property ToolTargets;
property UseReticule default true;
property UseReticule default true; deprecated 'Use DatapointCrosshairTool instead';
property XErrorBars;
property YErrorBars;
// Events
@ -275,7 +275,7 @@ type
property SeriesColor: TColor
read FSeriesColor write SetSeriesColor default clBlack;
property Source;
property UseReticule;
property UseReticule; deprecated 'Use DatapointCrosshairTool instead';
end;
TLineStyle = (lsVertical, lsHorizontal);