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. php mysqli 的使用方法

    原文链接:https://blog.csdn.net/solly793755670/article/details/52217456 Mysqli是php5之后才有的功能 需要修改php.ini的配置 ...

  2. topcoder srm 661 div1

    problem1 link $N+1$到$M$ 之间的数字要包含所有1到$N$之间出现的质因子的最高幂即可. problem2 link 从第一个节点到第$N$个节点依次考虑.对于第$i$个节点来说, ...

  3. Linux服务器搭建Nexus-Maven私服(适合新手比较基础)

    背景 在使用maven构建项目的时候,几乎都会涉及到一个“私服”的概念,那么到底什么是私服?使用私服有能够带来哪些益处? 私服:私服是指私有服务器,是架设在局域网的一种特殊的远程仓库,目的是代理远程仓 ...

  4. linux内核中的最简单的输入输出调度算法noop

    1. noop是什么? noop是一种输入输出调度算法 2. noop的别称 又称为电梯调度算法 3. noop原理是怎样的? 将输入输出请求放到一个FIFO队列中,然后按次序执行队列中的输入输出请求 ...

  5. mysql数据库连接的测试代码语句片断

    手动连接数据库 的代码片断, 用于各种数据库的测试... $conn = mysql_connect('localhost', 'root', '') or die('failed to connec ...

  6. Docker 编排工具Rancher 1.6.18

    使用docker获取rancher [root@localhost /]# docker pull rancher/server:stable [root@localhost /]# docker i ...

  7. 通过WSL在Windows下安装子Linux系统

    一.开启开发者模式 步骤: -> 系统设置 -> 更新和安全 -> 针对开发人员 -> 选择开发者模式 点击后会自动安装环境 二.启用WSL 步骤: -> 系统设置 -& ...

  8. mvc扩展HtmlHelper功能

    HtmlHelper详细介绍 简单示例 自定义HtmlHelper 解决: 直接写HTML的话如果语句有语法错误,如缺少结尾标记</b>,编译器不会报错,出来的页面可能会很乱且难以查出错误 ...

  9. 正则匹配-URL-域名

    DNS规定,域名中的标号都由英文字母和数字组成,每一个标号不超过63个字符,也不区分大小写字母.标号中除连字符(-)外不能使用其他的标点符号.级别最低的域名写在最左边,而级别最高的域名写在最右边.由多 ...

  10. jQuery中的$(window).load()与$(document).ready()以及jquery $(document).ready() 与window.onload的区别

    大多数jQuery实例或教程都告诉我们绑定我们的jQuery代码到$(document).ready事件.虽然$(document).ready 事件在大多数情况下都OK,但是它的解析顺序是在文档准备 ...