using System;
using System.Collections;
using System.ComponentModel;
using System.Drawing;

using System.Windows.Forms;

namespace Steema.TeeChart.Samples
{
public class SeriesType_Point : Samples.BaseForm
{
private System.Windows.Forms.CheckBox checkBox1;
private System.Windows.Forms.CheckBox checkBox2;
private System.Windows.Forms.Timer timer1;
private Steema.TeeChart.Styles.Points pointSeries1;
private Steema.TeeChart.Styles.Points pointSeries2;
private Steema.TeeChart.Styles.Points pointSeries3;
private Steema.TeeChart.Styles.Points pointSeries4;
private Steema.TeeChart.Styles.Points pointSeries5;
private Steema.TeeChart.Styles.Points pointSeries6;
private System.ComponentModel.IContainer components = null;
private Steema.TeeChart.Tools.GridBand gridBand1;
private Random r;
public SeriesType_Point()
{
// This call is required by the Windows Form Designer.
InitializeComponent();
foreach(Steema.TeeChart.Styles.Series s in tChart1.Series)
s.FillSampleValues(20);

r = new Random();
}

/// <summary>
/// Clean up any resources being used.
/// </summary>
protected override void Dispose( bool disposing )
{
if( disposing )
{
if (components != null)
{
components.Dispose();
}
}
base.Dispose( disposing );
}

#region Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
this.checkBox1 = new System.Windows.Forms.CheckBox();
this.checkBox2 = new System.Windows.Forms.CheckBox();
this.timer1 = new System.Windows.Forms.Timer(this.components);
this.pointSeries1 = new Steema.TeeChart.Styles.Points();
this.pointSeries2 = new Steema.TeeChart.Styles.Points();
this.pointSeries3 = new Steema.TeeChart.Styles.Points();
this.pointSeries4 = new Steema.TeeChart.Styles.Points();
this.pointSeries5 = new Steema.TeeChart.Styles.Points();
this.pointSeries6 = new Steema.TeeChart.Styles.Points();
this.gridBand1 = new Steema.TeeChart.Tools.GridBand();
this.panel1.SuspendLayout();
this.SuspendLayout();
//
// textBox1
//
this.textBox1.Name = "textBox1";
this.textBox1.Size = new System.Drawing.Size(466, 63);
this.textBox1.Text = "Point series displays XY values using a Pointer.\r\n\r\nEach pointer has many differe" +
"nt properties, like color, 3D, shadow, style, marks, pattern, border, width, hei" +
"ght, etc.";
//
// panel1
//
this.panel1.Controls.Add(this.checkBox2);
this.panel1.Controls.Add(this.checkBox1);
this.panel1.Location = new System.Drawing.Point(0, 63);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(466, 33);
//
// tChart1
//
//
// tChart1.Aspect
//
this.tChart1.Aspect.Chart3DPercent = 35;
this.tChart1.Aspect.Elevation = 350;
this.tChart1.Aspect.Orthogonal = false;
this.tChart1.Aspect.Perspective = 55;
this.tChart1.Aspect.Rotation = 322;
this.tChart1.Aspect.SmoothingMode = System.Drawing.Drawing2D.SmoothingMode.HighQuality;
this.tChart1.Aspect.TextRenderingHint = System.Drawing.Text.TextRenderingHint.ClearTypeGridFit;
this.tChart1.Aspect.Zoom = 72;
//
// tChart1.Header
//
this.tChart1.Header.Bottom = 26;
this.tChart1.Header.CustomPosition = true;
//
// tChart1.Header.Font
//
this.tChart1.Header.Font.Bold = true;
//
// tChart1.Header.Font.Brush
//
this.tChart1.Header.Font.Brush.Color = System.Drawing.Color.Teal;
this.tChart1.Header.Font.Size = 10;
this.tChart1.Header.Left = 10;
this.tChart1.Header.Lines = new string[] {
"Point series"};
this.tChart1.Header.Right = 110;
this.tChart1.Header.Top = 9;
//
// tChart1.Legend
//
this.tChart1.Legend.Alignment = Steema.TeeChart.LegendAlignments.Bottom;
//
// tChart1.Legend.Brush
//
this.tChart1.Legend.Brush.Color = System.Drawing.Color.FromArgb(((System.Byte)(192)), ((System.Byte)(192)), ((System.Byte)(192)));
//
// tChart1.Legend.Pen
//
this.tChart1.Legend.Pen.Color = System.Drawing.Color.FromArgb(((System.Byte)(255)), ((System.Byte)(0)), ((System.Byte)(0)));
//
// tChart1.Legend.Shadow
//
//
// tChart1.Legend.Shadow.Brush
//
this.tChart1.Legend.Shadow.Brush.Color = System.Drawing.Color.FromArgb(((System.Byte)(192)), ((System.Byte)(192)), ((System.Byte)(192)));
this.tChart1.Legend.Shadow.Height = 4;
this.tChart1.Legend.Shadow.Width = 4;
this.tChart1.Location = new System.Drawing.Point(0, 96);
this.tChart1.Name = "tChart1";
//
// tChart1.Panel
//
//
// tChart1.Panel.Brush
//
this.tChart1.Panel.Brush.Color = System.Drawing.Color.FromArgb(((System.Byte)(254)), ((System.Byte)(255)), ((System.Byte)(255)), ((System.Byte)(255)));
this.tChart1.Series.Add(this.pointSeries1);
this.tChart1.Series.Add(this.pointSeries2);
this.tChart1.Series.Add(this.pointSeries3);
this.tChart1.Series.Add(this.pointSeries4);
this.tChart1.Series.Add(this.pointSeries5);
this.tChart1.Series.Add(this.pointSeries6);
this.tChart1.Size = new System.Drawing.Size(466, 190);
this.tChart1.Tools.Add(this.gridBand1);
//
// tChart1.Walls
//
//
// tChart1.Walls.Bottom
//
//
// tChart1.Walls.Bottom.Brush
//
this.tChart1.Walls.Bottom.Brush.Color = System.Drawing.Color.FromArgb(((System.Byte)(76)), ((System.Byte)(255)), ((System.Byte)(255)), ((System.Byte)(255)));
//
// tChart1.Walls.Bottom.Gradient
//
this.tChart1.Walls.Bottom.Brush.Gradient.Transparency = 70;
//
// tChart1.Walls.Bottom.Gradient
//
this.tChart1.Walls.Bottom.Gradient.Transparency = 70;
//
// tChart1.Walls.Bottom.Pen
//
this.tChart1.Walls.Bottom.Pen.Visible = false;
this.tChart1.Walls.Bottom.Size = 3;
//
// tChart1.Walls.Left
//
//
// tChart1.Walls.Left.Brush
//
this.tChart1.Walls.Left.Brush.Color = System.Drawing.Color.FromArgb(((System.Byte)(76)), ((System.Byte)(255)), ((System.Byte)(255)), ((System.Byte)(224)));
//
// tChart1.Walls.Left.Gradient
//
this.tChart1.Walls.Left.Brush.Gradient.Transparency = 70;
//
// tChart1.Walls.Left.Gradient
//
this.tChart1.Walls.Left.Gradient.Transparency = 70;
//
// tChart1.Walls.Left.Pen
//
this.tChart1.Walls.Left.Pen.Visible = false;
this.tChart1.Walls.Left.Size = 3;
//
// checkBox1
//
this.checkBox1.Checked = true;
this.checkBox1.CheckState = System.Windows.Forms.CheckState.Checked;
this.checkBox1.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.checkBox1.Location = new System.Drawing.Point(16, 8);
this.checkBox1.Name = "checkBox1";
this.checkBox1.Size = new System.Drawing.Size(40, 21);
this.checkBox1.TabIndex = 0;
this.checkBox1.Text = "&3D";
this.checkBox1.CheckedChanged += new System.EventHandler(this.checkBox1_CheckedChanged);
//
// checkBox2
//
this.checkBox2.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.checkBox2.Location = new System.Drawing.Point(93, 8);
this.checkBox2.Name = "checkBox2";
this.checkBox2.Size = new System.Drawing.Size(67, 21);
this.checkBox2.TabIndex = 1;
this.checkBox2.Text = "&Animate";
this.checkBox2.CheckedChanged += new System.EventHandler(this.checkBox2_CheckedChanged);
//
// timer1
//
this.timer1.Interval = 1;
this.timer1.Tick += new System.EventHandler(this.timer1_Tick);
//
// pointSeries1
//
//
// pointSeries1.Marks
//
//
// pointSeries1.Marks.Symbol
//
//
// pointSeries1.Marks.Symbol.Shadow
//
this.pointSeries1.Marks.Symbol.Shadow.Height = 1;
this.pointSeries1.Marks.Symbol.Shadow.Visible = true;
this.pointSeries1.Marks.Symbol.Shadow.Width = 1;
//
// pointSeries1.Pointer
//
//
// pointSeries1.Pointer.Brush
//
this.pointSeries1.Pointer.Brush.Color = System.Drawing.Color.Red;
this.pointSeries1.Pointer.Style = Steema.TeeChart.Styles.PointerStyles.Rectangle;
this.pointSeries1.Title = "point6";
//
// pointSeries1.XValues
//
this.pointSeries1.XValues.DataMember = "X";
this.pointSeries1.XValues.Order = Steema.TeeChart.Styles.ValueListOrder.Ascending;
//
// pointSeries1.YValues
//
this.pointSeries1.YValues.DataMember = "Y";
//
// pointSeries2
//
//
// pointSeries2.Marks
//
//
// pointSeries2.Marks.Symbol
//
//
// pointSeries2.Marks.Symbol.Shadow
//
this.pointSeries2.Marks.Symbol.Shadow.Height = 1;
this.pointSeries2.Marks.Symbol.Shadow.Visible = true;
this.pointSeries2.Marks.Symbol.Shadow.Width = 1;
//
// pointSeries2.Pointer
//
//
// pointSeries2.Pointer.Brush
//
this.pointSeries2.Pointer.Brush.Color = System.Drawing.Color.Green;
this.pointSeries2.Pointer.Style = Steema.TeeChart.Styles.PointerStyles.Rectangle;
this.pointSeries2.Title = "point6";
//
// pointSeries2.XValues
//
this.pointSeries2.XValues.DataMember = "X";
this.pointSeries2.XValues.Order = Steema.TeeChart.Styles.ValueListOrder.Ascending;
//
// pointSeries2.YValues
//
this.pointSeries2.YValues.DataMember = "Y";
//
// pointSeries3
//
//
// pointSeries3.Marks
//
//
// pointSeries3.Marks.Symbol
//
//
// pointSeries3.Marks.Symbol.Shadow
//
this.pointSeries3.Marks.Symbol.Shadow.Height = 1;
this.pointSeries3.Marks.Symbol.Shadow.Visible = true;
this.pointSeries3.Marks.Symbol.Shadow.Width = 1;
//
// pointSeries3.Pointer
//
//
// pointSeries3.Pointer.Brush
//
this.pointSeries3.Pointer.Brush.Color = System.Drawing.Color.Yellow;
this.pointSeries3.Pointer.Style = Steema.TeeChart.Styles.PointerStyles.Rectangle;
this.pointSeries3.Title = "point6";
//
// pointSeries3.XValues
//
this.pointSeries3.XValues.DataMember = "X";
this.pointSeries3.XValues.Order = Steema.TeeChart.Styles.ValueListOrder.Ascending;
//
// pointSeries3.YValues
//
this.pointSeries3.YValues.DataMember = "Y";
//
// pointSeries4
//
//
// pointSeries4.Marks
//
//
// pointSeries4.Marks.Symbol
//
//
// pointSeries4.Marks.Symbol.Shadow
//
this.pointSeries4.Marks.Symbol.Shadow.Height = 1;
this.pointSeries4.Marks.Symbol.Shadow.Visible = true;
this.pointSeries4.Marks.Symbol.Shadow.Width = 1;
//
// pointSeries4.Pointer
//
//
// pointSeries4.Pointer.Brush
//
this.pointSeries4.Pointer.Brush.Color = System.Drawing.Color.Blue;
this.pointSeries4.Pointer.Style = Steema.TeeChart.Styles.PointerStyles.Rectangle;
this.pointSeries4.Title = "point6";
//
// pointSeries4.XValues
//
this.pointSeries4.XValues.DataMember = "X";
this.pointSeries4.XValues.Order = Steema.TeeChart.Styles.ValueListOrder.Ascending;
//
// pointSeries4.YValues
//
this.pointSeries4.YValues.DataMember = "Y";
//
// pointSeries5
//
//
// pointSeries5.LinePen
//
this.pointSeries5.LinePen.Color = System.Drawing.Color.FromArgb(((System.Byte)(153)), ((System.Byte)(153)), ((System.Byte)(122)));
//
// pointSeries5.Marks
//
//
// pointSeries5.Marks.Symbol
//
//
// pointSeries5.Marks.Symbol.Shadow
//
this.pointSeries5.Marks.Symbol.Shadow.Height = 1;
this.pointSeries5.Marks.Symbol.Shadow.Visible = true;
this.pointSeries5.Marks.Symbol.Shadow.Width = 1;
//
// pointSeries5.Pointer
//
//
// pointSeries5.Pointer.Brush
//
this.pointSeries5.Pointer.Brush.Color = System.Drawing.Color.FromArgb(((System.Byte)(255)), ((System.Byte)(255)), ((System.Byte)(204)));
//
// pointSeries5.Pointer.Pen
//
this.pointSeries5.Pointer.Pen.Color = System.Drawing.Color.FromArgb(((System.Byte)(153)), ((System.Byte)(153)), ((System.Byte)(122)));
this.pointSeries5.Pointer.Style = Steema.TeeChart.Styles.PointerStyles.Rectangle;
this.pointSeries5.Title = "point6";
//
// pointSeries5.XValues
//
this.pointSeries5.XValues.DataMember = "X";
this.pointSeries5.XValues.Order = Steema.TeeChart.Styles.ValueListOrder.Ascending;
//
// pointSeries5.YValues
//
this.pointSeries5.YValues.DataMember = "Y";
//
// pointSeries6
//
//
// pointSeries6.Marks
//
//
// pointSeries6.Marks.Symbol
//
//
// pointSeries6.Marks.Symbol.Shadow
//
this.pointSeries6.Marks.Symbol.Shadow.Height = 1;
this.pointSeries6.Marks.Symbol.Shadow.Visible = true;
this.pointSeries6.Marks.Symbol.Shadow.Width = 1;
//
// pointSeries6.Pointer
//
//
// pointSeries6.Pointer.Brush
//
this.pointSeries6.Pointer.Brush.Color = System.Drawing.Color.Gray;
this.pointSeries6.Pointer.Style = Steema.TeeChart.Styles.PointerStyles.Rectangle;
this.pointSeries6.Title = "point6";
//
// pointSeries6.XValues
//
this.pointSeries6.XValues.DataMember = "X";
this.pointSeries6.XValues.Order = Steema.TeeChart.Styles.ValueListOrder.Ascending;
//
// pointSeries6.YValues
//
this.pointSeries6.YValues.DataMember = "Y";
//
// gridBand1
//
this.gridBand1.Axis = this.tChart1.Axes.Left;
//
// gridBand1.Band1
//
this.gridBand1.Band1.Color = System.Drawing.Color.FromArgb(((System.Byte)(76)), ((System.Byte)(128)), ((System.Byte)(128)), ((System.Byte)(0)));
//
// gridBand1.Band2
//
this.gridBand1.Band2.Color = System.Drawing.Color.FromArgb(((System.Byte)(76)), ((System.Byte)(255)), ((System.Byte)(255)), ((System.Byte)(255)));
//
// SeriesType_Point
//
this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
this.ClientSize = new System.Drawing.Size(466, 286);
this.Name = "SeriesType_Point";
this.panel1.ResumeLayout(false);
this.ResumeLayout(false);

}
#endregion

private void checkBox1_CheckedChanged(object sender, System.EventArgs e)
{
tChart1.Aspect.View3D = checkBox1.Checked;
}

private void checkBox2_CheckedChanged(object sender, System.EventArgs e)
{
timer1.Enabled = checkBox2.Checked;
}

private void timer1_Tick(object sender, System.EventArgs e)
{
timer1.Stop();
try
{
double tmpX;
foreach(Steema.TeeChart.Styles.Series s in tChart1.Series)
{
// add a new point to each series
tmpX = s.XValues[1] - s.XValues[0];
s.Delete(0);
s.Add(s.XValues.Last + tmpX, s.YValues.Last + r.Next(100)-50);
}
}
finally
{
timer1.Start();
}

}
}
}

tchart...的更多相关文章

  1. 利用TCHART做分离饼形图

    https://www.cnblogs.com/gaodu2003/archive/2009/06/18/1505720.html unit Unit1; interface ……type  TFor ...

  2. 图表控件Tchart的使用总结

    用了一段时间的Tchart,做下记录总结,以便日后查用,有新的记录会及时添加更新 鼠标右键选择Edit可以对图表进行编辑 添加所需图表: Chart --> Series--> Add 1 ...

  3. tchart example

    Random random = new Random(); // Color SeriesColor; int SeriesIndex=0; tChart1.Series.Clear(); Steem ...

  4. TCHART FROM DATATABLE

    using System;using System.Collections;using System.ComponentModel;using System.Drawing;using System. ...

  5. TCHART类型

    private Steema.TeeChart.Styles.Pie pieSeries1; private Steema.TeeChart.Styles.Pie pieSeries2; privat ...

  6. delphi teechrt中TChart 一些属性设置

    把图片设置成黑白 2.设置颜色

  7. Delphi编程建议遵守的规范2---命名规范

    1.1.形参命名建议 所有形参的名称都应当表达出它的用途.如果合适的话,形参的名称最好以字母a 为前缀,例如: procedure SomeProc(aUserName:string; aUserAg ...

  8. 主窗体里面打开子窗体&&打印饼图《Delphi 6数据库开发典型实例》--图表的绘制

    \Delphi 6数据库开发典型实例\图表的绘制 1.在主窗体里面打开子窗体:ShowForm(Tfrm_Print); procedure Tfrm_Main.ShowForm(AFormClass ...

  9. C#源码500份

    C Sharp  短信发送平台源代码.rar http://1000eb.com/5c6vASP.NET+AJAX基础示例 视频教程 http://1000eb.com/89jcC# Winform ...

随机推荐

  1. 学习MFC的建议

    1.继续深入学习C++的内容,打好面向对象的程序综合设计与编程基础,参考书籍<C++Primer>. 2.打好Windows编程基础(参考书<Windows程序设计>(第五版) ...

  2. 20165310 NstSec2019 Week1 Exp0 Kali安装

    20165310 NstSec2019 Week1 Exp0 Kali安装 Kali下载与安装 进入Kali官网 ,进入Download选项,选择Kali Linux 64 bit VMware VM ...

  3. PyCharm笔记之搭建Python开发环境

    新建一个空helloworld项目,然后新建一个main.py文件: 此时还无法运行,因为没有配置项目的入口脚本,通过下图的步骤指定一个: 在scrip框里填入你的入口脚本 之后就可以点击绿色的播放按 ...

  4. java利用poi解析excel文件

    首先需要引入以下jar包 如果使用maven,需要添加两个依赖 <dependencies> <dependency> <groupId>org.apache.po ...

  5. LD_RUN_PATH和LD_LIBRARY_PATH是干什么的?

    1. 使用场合 LD_RUN_PATH在链接时使用 LD_LIBRARY_PATH在执行时使用 2. 如何指定环境变量 export LD_LIBRARY_PATH=/opt/jello/lib:$L ...

  6. 微生物增殖|2012年蓝桥杯B组题解析第一题-fishers

    (3')微生物增殖 假设有两种微生物 X 和 Y X出生后每隔3分钟分裂一次(数目加倍),Y出生后每隔2分钟分裂一次(数目加倍). 一个新出生的X,半分钟之后吃掉1个Y,并且,从此开始,每隔1分钟吃1 ...

  7. C# DateTime判断时间

    两种情况: 1 DateTime? dtTemp = null; if(dtTime != null) { //wawawa } 刚刚学会的,可空值类型,可判断是否赋值 2 DateTime dtTe ...

  8. vue项目从引入vue.js 改为使用vue-cil (webpack)时修改的一些内容

    在元素属性中不要写js关键字,会报使用关键字的错如@click='if(){}else{}', if-else 语句可以使用三元表达式或短路运算符来实现 v-for 不写:key  会有警告 ,使用: ...

  9. (转载)MySQl数据库-批量添加数据的两种方法

    方法一:使用excel表格 方法二:使用insert语句(FileWriter批量写入) 使用excel表格 1.打开数据表,按照表的字段在excel中添加数据.注意:表中字段名必须和excel中的名 ...

  10. Codeforces 855C. Helga Hufflepuff's Cup----树形DP

    z最近在学习树形DP...好难啊. 在cf上找到了一题c题当模版马克一下. 题目不贴了..>>http://codeforces.com/problemset/problem/855/C& ...