TAChart: Invert ZOrder.

git-svn-id: trunk@19610 -
This commit is contained in:
ask 2009-04-24 14:09:33 +00:00
parent 3db771a856
commit 563f244d92
4 changed files with 60 additions and 60 deletions

View File

@ -11,6 +11,26 @@ object Form1: TForm1
object Chart1: TChart
Height = 392
Width = 585
BottomAxis.Grid.Color = clGray
BottomAxis.Grid.Style = psDot
BottomAxis.Grid.Visible = True
BottomAxis.Title.Font.Height = -11
BottomAxis.Title.Font.Name = 'MS Sans Serif'
Foot.Brush.Color = clBtnFace
Foot.Font.Color = clRed
Foot.Font.Height = -13
Foot.Font.Name = 'MS Sans Serif'
Foot.Font.Style = [fsBold]
Foot.Text.Strings = (
'This a LeftAligned Footer'
)
Frame.Visible = True
LeftAxis.Grid.Color = clGray
LeftAxis.Grid.Style = psDot
LeftAxis.Grid.Visible = True
LeftAxis.Title.Angle = 90
LeftAxis.Title.Font.Height = -11
LeftAxis.Title.Font.Name = 'MS Sans Serif'
Legend.Font.Height = -11
Legend.Font.Name = 'MS Sans Serif'
Title.Brush.Color = clBtnFace
@ -21,26 +41,6 @@ object Form1: TForm1
'Centered Chart Title'
)
Title.Visible = True
Foot.Brush.Color = clBtnFace
Foot.Font.Color = clRed
Foot.Font.Height = -13
Foot.Font.Name = 'MS Sans Serif'
Foot.Font.Style = [fsBold]
Foot.Text.Strings = (
'This a LeftAligned Footer'
)
LeftAxis.Grid.Color = clGray
LeftAxis.Grid.Style = psDot
LeftAxis.Grid.Visible = True
LeftAxis.Title.Angle = 90
LeftAxis.Title.Font.Height = -11
LeftAxis.Title.Font.Name = 'MS Sans Serif'
BottomAxis.Grid.Color = clGray
BottomAxis.Grid.Style = psDot
BottomAxis.Grid.Visible = True
BottomAxis.Title.Font.Height = -11
BottomAxis.Title.Font.Name = 'MS Sans Serif'
Frame.Visible = True
Align = alClient
ParentColor = False
object Chart1LineHor: TLine

View File

@ -4,44 +4,44 @@ LazarusResources.Add('TForm1','FORMDATA',[
'TPF0'#6'TForm1'#5'Form1'#4'Left'#3'U'#1#6'Height'#3#238#1#3'Top'#3#225#0#5'W'
+'idth'#3'I'#2#7'Caption'#6#5'Form1'#12'ClientHeight'#3#238#1#11'ClientWidth'
+#3'I'#2#8'Position'#7#14'poScreenCenter'#10'LCLVersion'#6#6'0.9.27'#0#6'TCha'
+'rt'#6'Chart1'#6'Height'#3#136#1#5'Width'#3'I'#2#18'Legend.Font.Height'#2#245
+#16'Legend.Font.Name'#6#13'MS Sans Serif'#17'Title.Brush.Color'#7#9'clBtnFac'
+'e'#16'Title.Font.Color'#7#6'clBlue'#17'Title.Font.Height'#2#245#15'Title.Fo'
+'nt.Name'#6#13'MS Sans Serif'#18'Title.Text.Strings'#1#6#20'Centered Chart T'
+'itle'#0#13'Title.Visible'#9#16'Foot.Brush.Color'#7#9'clBtnFace'#15'Foot.Fon'
+'t.Color'#7#5'clRed'#16'Foot.Font.Height'#2#243#14'Foot.Font.Name'#6#13'MS S'
+'ans Serif'#15'Foot.Font.Style'#11#6'fsBold'#0#17'Foot.Text.Strings'#1#6#25
+'This a LeftAligned Footer'#0#19'LeftAxis.Grid.Color'#7#6'clGray'#19'LeftAxi'
+'s.Grid.Style'#7#5'psDot'#21'LeftAxis.Grid.Visible'#9#20'LeftAxis.Title.Angl'
+'e'#2'Z'#26'LeftAxis.Title.Font.Height'#2#245#24'LeftAxis.Title.Font.Name'#6
+#13'MS Sans Serif'#21'BottomAxis.Grid.Color'#7#6'clGray'#21'BottomAxis.Grid.'
+'Style'#7#5'psDot'#23'BottomAxis.Grid.Visible'#9#28'BottomAxis.Title.Font.He'
+'ight'#2#245#26'BottomAxis.Title.Font.Name'#6#13'MS Sans Serif'#13'Frame.Vis'
+'ible'#9#5'Align'#7#8'alClient'#11'ParentColor'#8#0#5'TLine'#13'Chart1LineHo'
+'r'#12'ShowInLegend'#8#9'Pen.Style'#7#6'psDash'#11'SeriesColor'#7#7'clBlack'
+#0#0#5'TLine'#14'Chart1LineVert'#12'ShowInLegend'#8#9'LineStyle'#7#10'lsVert'
+'ical'#9'Pen.Style'#7#6'psDash'#11'SeriesColor'#7#7'clBlack'#0#0#0#6'TPanel'
+#6'Panel1'#6'Height'#2'f'#3'Top'#3#136#1#5'Width'#3'I'#2#5'Align'#7#8'alBott'
+'om'#12'ClientHeight'#2'f'#11'ClientWidth'#3'I'#2#8'TabOrder'#2#0#0#6'TLabel'
+#6'lblAdd'#4'Left'#2#13#6'Height'#2#14#3'Top'#2#10#5'Width'#2#24#7'Caption'#6
+#4'Add:'#11'ParentColor'#8#0#0#6'TLabel'#8'lblClear'#4'Left'#2#13#6'Height'#2
+#14#3'Top'#2'('#5'Width'#2#30#7'Caption'#6#6'Clear:'#11'ParentColor'#8#0#0#6
+'TLabel'#11'lblAddCount'#4'Left'#3' '#1#6'Height'#2#14#3'Top'#2#8#5'Width'#2
+':'#7'Caption'#6#12'Multiple add'#11'ParentColor'#8#0#0#6'TLabel'#12'lblMark'
+'Style'#4'Left'#2'0'#6'Height'#2#14#3'Top'#2'P'#5'Width'#2'N'#7'Caption'#6#15
+'Add with marks:'#11'ParentColor'#8#0#0#6'TLabel'#11'lblReticule'#4'Left'#3
+'h'#1#6'Height'#2#14#3'Top'#2'P'#5'Width'#2'+'#7'Caption'#6#9'Reticule:'#11
+'ParentColor'#8#0#0#7'TButton'#9'btnAddPie'#4'Left'#2'0'#6'Height'#2#24#3'To'
+'p'#2#8#5'Width'#2'4'#25'BorderSpacing.InnerBorder'#2#4#7'Caption'#6#3'Pie'#7
+'OnClick'#7#14'btnAddPieClick'#8'TabOrder'#2#0#0#0#7'TButton'#10'btnAddLine'
+#4'Left'#3#216#0#6'Height'#2#24#3'Top'#2#8#5'Width'#2'4'#25'BorderSpacing.In'
+'nerBorder'#2#4#7'Caption'#6#4'Line'#7'OnClick'#7#15'btnAddLineClick'#8'TabO'
+'rder'#2#1#0#0#7'TButton'#10'btnAddArea'#4'Left'#2'h'#6'Height'#2#24#3'Top'#2
+#8#5'Width'#2'4'#25'BorderSpacing.InnerBorder'#2#4#7'Caption'#6#4'Area'#7'On'
+'Click'#7#15'btnAddAreaClick'#8'TabOrder'#2#2#0#0#7'TButton'#9'btnAddBar'#4
+'Left'#3#160#0#6'Height'#2#24#3'Top'#2#8#5'Width'#2'4'#25'BorderSpacing.Inne'
+'rBorder'#2#4#7'Caption'#6#3'Bar'#7'OnClick'#7#14'btnAddBarClick'#8'TabOrder'
+#2#3#0#0#9'TCheckBox'#8'cbLegend'#4'Left'#3#128#1#6'Height'#2#17#3'Top'#2#8#5
+'rt'#6'Chart1'#6'Height'#3#136#1#5'Width'#3'I'#2#21'BottomAxis.Grid.Color'#7
+#6'clGray'#21'BottomAxis.Grid.Style'#7#5'psDot'#23'BottomAxis.Grid.Visible'#9
+#28'BottomAxis.Title.Font.Height'#2#245#26'BottomAxis.Title.Font.Name'#6#13
+'MS Sans Serif'#16'Foot.Brush.Color'#7#9'clBtnFace'#15'Foot.Font.Color'#7#5
+'clRed'#16'Foot.Font.Height'#2#243#14'Foot.Font.Name'#6#13'MS Sans Serif'#15
+'Foot.Font.Style'#11#6'fsBold'#0#17'Foot.Text.Strings'#1#6#25'This a LeftAli'
+'gned Footer'#0#13'Frame.Visible'#9#19'LeftAxis.Grid.Color'#7#6'clGray'#19'L'
+'eftAxis.Grid.Style'#7#5'psDot'#21'LeftAxis.Grid.Visible'#9#20'LeftAxis.Titl'
+'e.Angle'#2'Z'#26'LeftAxis.Title.Font.Height'#2#245#24'LeftAxis.Title.Font.N'
+'ame'#6#13'MS Sans Serif'#18'Legend.Font.Height'#2#245#16'Legend.Font.Name'#6
+#13'MS Sans Serif'#17'Title.Brush.Color'#7#9'clBtnFace'#16'Title.Font.Color'
+#7#6'clBlue'#17'Title.Font.Height'#2#245#15'Title.Font.Name'#6#13'MS Sans Se'
+'rif'#18'Title.Text.Strings'#1#6#20'Centered Chart Title'#0#13'Title.Visible'
+#9#5'Align'#7#8'alClient'#11'ParentColor'#8#0#5'TLine'#13'Chart1LineHor'#12
+'ShowInLegend'#8#9'Pen.Style'#7#6'psDash'#11'SeriesColor'#7#7'clBlack'#0#0#5
+'TLine'#14'Chart1LineVert'#12'ShowInLegend'#8#9'LineStyle'#7#10'lsVertical'#9
+'Pen.Style'#7#6'psDash'#11'SeriesColor'#7#7'clBlack'#0#0#0#6'TPanel'#6'Panel'
+'1'#6'Height'#2'f'#3'Top'#3#136#1#5'Width'#3'I'#2#5'Align'#7#8'alBottom'#12
+'ClientHeight'#2'f'#11'ClientWidth'#3'I'#2#8'TabOrder'#2#0#0#6'TLabel'#6'lbl'
+'Add'#4'Left'#2#13#6'Height'#2#14#3'Top'#2#10#5'Width'#2#24#7'Caption'#6#4'A'
+'dd:'#11'ParentColor'#8#0#0#6'TLabel'#8'lblClear'#4'Left'#2#13#6'Height'#2#14
+#3'Top'#2'('#5'Width'#2#30#7'Caption'#6#6'Clear:'#11'ParentColor'#8#0#0#6'TL'
+'abel'#11'lblAddCount'#4'Left'#3' '#1#6'Height'#2#14#3'Top'#2#8#5'Width'#2':'
+#7'Caption'#6#12'Multiple add'#11'ParentColor'#8#0#0#6'TLabel'#12'lblMarkSty'
+'le'#4'Left'#2'0'#6'Height'#2#14#3'Top'#2'P'#5'Width'#2'N'#7'Caption'#6#15'A'
+'dd with marks:'#11'ParentColor'#8#0#0#6'TLabel'#11'lblReticule'#4'Left'#3'h'
+#1#6'Height'#2#14#3'Top'#2'P'#5'Width'#2'+'#7'Caption'#6#9'Reticule:'#11'Par'
+'entColor'#8#0#0#7'TButton'#9'btnAddPie'#4'Left'#2'0'#6'Height'#2#24#3'Top'#2
+#8#5'Width'#2'4'#25'BorderSpacing.InnerBorder'#2#4#7'Caption'#6#3'Pie'#7'OnC'
+'lick'#7#14'btnAddPieClick'#8'TabOrder'#2#0#0#0#7'TButton'#10'btnAddLine'#4
+'Left'#3#216#0#6'Height'#2#24#3'Top'#2#8#5'Width'#2'4'#25'BorderSpacing.Inne'
+'rBorder'#2#4#7'Caption'#6#4'Line'#7'OnClick'#7#15'btnAddLineClick'#8'TabOrd'
+'er'#2#1#0#0#7'TButton'#10'btnAddArea'#4'Left'#2'h'#6'Height'#2#24#3'Top'#2#8
+#5'Width'#2'4'#25'BorderSpacing.InnerBorder'#2#4#7'Caption'#6#4'Area'#7'OnCl'
+'ick'#7#15'btnAddAreaClick'#8'TabOrder'#2#2#0#0#7'TButton'#9'btnAddBar'#4'Le'
+'ft'#3#160#0#6'Height'#2#24#3'Top'#2#8#5'Width'#2'4'#25'BorderSpacing.InnerB'
+'order'#2#4#7'Caption'#6#3'Bar'#7'OnClick'#7#14'btnAddBarClick'#8'TabOrder'#2
+#3#0#0#9'TCheckBox'#8'cbLegend'#4'Left'#3#128#1#6'Height'#2#17#3'Top'#2#8#5
+'Width'#2'8'#7'Caption'#6#6'Legend'#8'OnChange'#7#14'cbLegendChange'#8'TabOr'
+'der'#2#4#0#0#9'TCheckBox'#12'cbBottomAxis'#4'Left'#3#128#1#6'Height'#2#17#3
+'Top'#2#24#5'Width'#2'K'#7'Caption'#6#11'Bottom Axis'#7'Checked'#9#8'OnChang'

View File

@ -85,7 +85,7 @@ var
i: Integer;
begin
for i := 0 to Chart1.SeriesCount - 1 do
Chart1.Series[i].ZPosition := Ord(Chart1.Series[i] <> ASeries);
Chart1.Series[i].ZPosition := Ord(Chart1.Series[i] = ASeries);
end;
procedure TForm1.btnAddAreaClick(Sender: TObject);

View File

@ -299,7 +299,7 @@ uses
function CompareZPosition(AItem1, AItem2: Pointer): Integer;
begin
Result :=
TBasicChartSeries(AItem2).ZPosition - TBasicChartSeries(AItem1).ZPosition;
TBasicChartSeries(AItem1).ZPosition - TBasicChartSeries(AItem2).ZPosition;
end;
procedure Register;