diff --git a/components/tachart/demo/3d/main.lfm b/components/tachart/demo/3d/main.lfm
index 3aec3b3501..0175185daf 100644
--- a/components/tachart/demo/3d/main.lfm
+++ b/components/tachart/demo/3d/main.lfm
@@ -1,16 +1,17 @@
object Form1: TForm1
Left = 318
- Height = 300
+ Height = 347
Top = 150
Width = 560
Caption = 'Form1'
- ClientHeight = 300
+ ClientHeight = 347
ClientWidth = 560
+ OnShow = FormShow
Position = poScreenCenter
LCLVersion = '0.9.29'
object Chart1: TChart
Left = 0
- Height = 300
+ Height = 297
Top = 0
Width = 560
AxisList = <
@@ -62,6 +63,32 @@ object Form1: TForm1
Source = RandomChartSource1
end
end
+ object pnControls: TPanel
+ Left = 0
+ Height = 50
+ Top = 297
+ Width = 560
+ Align = alBottom
+ ClientHeight = 50
+ ClientWidth = 560
+ TabOrder = 1
+ object seDepth: TSpinEdit
+ Left = 52
+ Height = 21
+ Top = 7
+ Width = 74
+ OnChange = seDepthChange
+ TabOrder = 0
+ end
+ object lblDepth: TLabel
+ Left = 4
+ Height = 14
+ Top = 7
+ Width = 34
+ Caption = 'Depth:'
+ ParentColor = False
+ end
+ end
object RandomChartSource1: TRandomChartSource
PointsNumber = 7
RandSeed = 545516281
diff --git a/components/tachart/demo/3d/main.pas b/components/tachart/demo/3d/main.pas
index f2f43933a8..9b0f441393 100644
--- a/components/tachart/demo/3d/main.pas
+++ b/components/tachart/demo/3d/main.pas
@@ -5,7 +5,7 @@ unit main;
interface
uses
- Forms,
+ ExtCtrls, Forms, Spin, StdCtrls,
TAGraph, TASeries, TASources;
type
@@ -17,8 +17,13 @@ type
Chart1BarSeries1: TBarSeries;
Chart1BarSeries2: TBarSeries;
Chart1LineSeries1: TLineSeries;
+ lblDepth: TLabel;
+ pnControls: TPanel;
RandomChartSource1: TRandomChartSource;
RandomChartSource2: TRandomChartSource;
+ seDepth: TSpinEdit;
+ procedure FormShow(Sender: TObject);
+ procedure seDepthChange(Sender: TObject);
end;
var
@@ -28,5 +33,24 @@ implementation
{$R *.lfm}
+uses
+ Math;
+
+{ TForm1 }
+
+procedure TForm1.FormShow(Sender: TObject);
+begin
+ seDepth.Value := Chart1.Depth;
+end;
+
+procedure TForm1.seDepthChange(Sender: TObject);
+var
+ i: Integer;
+begin
+ Chart1.Depth := seDepth.Value;
+ for i := 0 to Chart1.SeriesCount - 1 do
+ Chart1.Series[i].Depth := Min(seDepth.Value, 10);
+end;
+
end.
diff --git a/components/tachart/demo/3d/zdemo.lpi b/components/tachart/demo/3d/zdemo.lpi
index 2c7fd1dbcc..4f5610e25a 100644
--- a/components/tachart/demo/3d/zdemo.lpi
+++ b/components/tachart/demo/3d/zdemo.lpi
@@ -15,7 +15,7 @@
-
+