TAChart: Update dragdrop demo to use TDataPointHintTool with the modifier key

git-svn-id: trunk@37210 -
This commit is contained in:
ask 2012-05-07 07:39:35 +00:00
parent c0db15a654
commit 28475d565d
3 changed files with 11 additions and 3 deletions

View File

@ -54,13 +54,14 @@
<Filename Value="main.pas"/>
<IsPartOfProject Value="True"/>
<ComponentName Value="Form1"/>
<HasResources Value="True"/>
<ResourceBaseClass Value="Form"/>
<UnitName Value="Main"/>
</Unit1>
</Units>
</ProjectOptions>
<CompilerOptions>
<Version Value="10"/>
<Version Value="11"/>
<PathDelim Value="\"/>
<SearchPaths>
<IncludeFiles Value="$(ProjOutDir)"/>

View File

@ -3,12 +3,13 @@ object Form1: TForm1
Height = 481
Top = 180
Width = 483
ActiveControl = Chart1
Caption = 'Form1'
ClientHeight = 481
ClientWidth = 483
OnCreate = FormCreate
Position = poScreenCenter
LCLVersion = '0.9.31'
LCLVersion = '1.1'
object Chart1: TChart
Left = 0
Height = 447
@ -25,11 +26,16 @@ object Form1: TForm1
end>
Foot.Brush.Color = clBtnFace
Foot.Font.Color = clBlue
Margins.Left = 8
Margins.Top = 8
Margins.Right = 8
Margins.Bottom = 8
Title.Brush.Color = clBtnFace
Title.Font.Color = clBlue
Title.Text.Strings = (
'Drag data points while holding Shift key'
'Change point color by right-click'
'Show hint while holding ctrl key'
)
Title.Visible = True
Toolset = ChartToolset1
@ -82,7 +88,7 @@ object Form1: TForm1
OnPointClick = ChartToolset1DataPointClickTool1PointClick
end
object ChartToolset1DataPointHintTool1: TDataPointHintTool
Shift = []
Shift = [ssCtrl]
GrabRadius = 10
ActiveCursor = crHandPoint
OnHint = ChartToolset1DataPointHintTool1Hint

View File

@ -46,6 +46,7 @@ uses
procedure TForm1.cbSortedChange(Sender: TObject);
begin
Chart1LineSeries1.ListSource.Sorted := cbSorted.Checked;
Chart1.SetFocus;
end;
procedure TForm1.Chart1LineSeries1GetMark(