TeeChart使用心得(一)
TeeChart是Delphi里面一个标准的图形显示控件。它可以静态设计(at design time)也可以动态生成。下面是我在使用过程中的一些心得体会,比较杂,但也许对你有用。
TeeChart的继承关系
TObject
TPersistent
TComponent
TControl
TCustomControl
TWedgetControl
TChart
TCustomPanel
TeeChart常见问题及使用技巧
1、TChart中如何实现只有Y轴的放大与缩小功能?
设置BottomAxis或者LeftAxis的Automatic:=false并同时设置Minimum,Maximum属性
2、如何固定TChart中的坐标,不使TChart中的坐标跟随Series的变化而变化?
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
//设置底座标
with do
begin
Automatic:=false;
Minimum:=0;
LabelStyle := talText;
end;
//设置左坐标
with do
begin
Automatic:=false;
Minimum:=0;
:=270;
:=;
:=ANSI_CHARSET;
:='@宋体';
:= False;
end;
19
20
21
22
23
24
25
26
27
28
29
//设置右坐标
with do
begin
Automatic:=false;
:=;
:=ANSI_CHARSET;
:='@宋体';
:='累计百分比(%)';
Maximum:=100;
Minimum:=0;
end;
3、如何删除一个图形中的一个点?
使用Series的delete方法
4、如何修改一个点的X或者Y值?
1
2
3
4
5
[3] := ;
{In Bubble Series}
[ 8 ] := ;
{In Pie Series}
[ 3 ] := 111 ;
5、如果横坐标是时间(日期),如何进行设置?
1
2
3
4
{First, you need to set the DateTime property to True in the desired X and/or Y values list.}
:= T
TeeChart使用心得一 来自淘豆网m.daumloan.com转载请标明出处.