mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-11-12 05:59:26 +01:00
TAChart: Use drawer everywhere instead of canvas in tools
git-svn-id: trunk@38433 -
This commit is contained in:
parent
ad680a75f4
commit
c5350721c8
@ -525,7 +525,7 @@ implementation
|
|||||||
|
|
||||||
uses
|
uses
|
||||||
GraphMath, InterfaceBase, Math, SysUtils,
|
GraphMath, InterfaceBase, Math, SysUtils,
|
||||||
TAChartAxis, TACustomSeries, TADrawerCanvas, TAEnumerators, TAGeometry, TAMath;
|
TACustomSeries, TAEnumerators, TAGeometry, TAMath;
|
||||||
|
|
||||||
function InitBuiltinTools(AChart: TChart): TBasicChartToolset;
|
function InitBuiltinTools(AChart: TChart): TBasicChartToolset;
|
||||||
var
|
var
|
||||||
@ -587,7 +587,7 @@ end;
|
|||||||
|
|
||||||
procedure TChartTool.Activate;
|
procedure TChartTool.Activate;
|
||||||
begin
|
begin
|
||||||
inherited Activate;
|
inherited;
|
||||||
SetCursor;
|
SetCursor;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
@ -619,7 +619,7 @@ end;
|
|||||||
procedure TChartTool.Deactivate;
|
procedure TChartTool.Deactivate;
|
||||||
begin
|
begin
|
||||||
RestoreCursor;
|
RestoreCursor;
|
||||||
inherited Deactivate;
|
inherited;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
destructor TChartTool.Destroy;
|
destructor TChartTool.Destroy;
|
||||||
@ -1030,11 +1030,11 @@ procedure TZoomDragTool.MouseMove(APoint: TPoint);
|
|||||||
begin
|
begin
|
||||||
if not IsActive or IsAnimating then exit;
|
if not IsActive or IsAnimating then exit;
|
||||||
case EffectiveDrawingMode of
|
case EffectiveDrawingMode of
|
||||||
tdmXor: begin
|
tdmXor: with FChart.Drawer do begin
|
||||||
FChart.Drawer.SetXorPen(Frame);
|
SetXorPen(Frame);
|
||||||
FChart.Canvas.Rectangle(FSelectionRect);
|
Rectangle(FSelectionRect);
|
||||||
FSelectionRect.BottomRight := APoint;
|
FSelectionRect.BottomRight := APoint;
|
||||||
FChart.Canvas.Rectangle(FSelectionRect);
|
Rectangle(FSelectionRect);
|
||||||
end;
|
end;
|
||||||
tdmNormal: begin
|
tdmNormal: begin
|
||||||
FSelectionRect.BottomRight := APoint;
|
FSelectionRect.BottomRight := APoint;
|
||||||
@ -1091,7 +1091,7 @@ begin
|
|||||||
Unused(APoint);
|
Unused(APoint);
|
||||||
|
|
||||||
FChart.Drawer.SetXorPen(Frame);
|
FChart.Drawer.SetXorPen(Frame);
|
||||||
FChart.Canvas.Rectangle(FSelectionRect);
|
FChart.Drawer.Rectangle(FSelectionRect);
|
||||||
with FSelectionRect do begin
|
with FSelectionRect do begin
|
||||||
dragDir := DRAG_DIR[Sign(Right - Left), Sign(Bottom - Top)];
|
dragDir := DRAG_DIR[Sign(Right - Left), Sign(Bottom - Top)];
|
||||||
if
|
if
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user