home *** CD-ROM | disk | FTP | other *** search
/ CD Actual Thematic 25: Programming / pc_actual_25.iso / Delphi / TeeChartPro / TeeChart5Delphi5Eval.exe / %MAINDIR% / Examples / Features / Zoom_Pen.pas < prev    next >
Encoding:
Pascal/Delphi Source File  |  2001-09-10  |  1006 b   |  50 lines

  1. unit Zoom_Pen;
  2.  
  3. interface
  4.  
  5. uses
  6.   Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
  7.   Base, StdCtrls, TeCanvas, TeePenDlg, TeEngine, Series, ExtCtrls, TeeProcs,
  8.   Chart;
  9.  
  10. type
  11.   TZoomPen = class(TBaseForm)
  12.     Series1: TFastLineSeries;
  13.     ButtonPen1: TButtonPen;
  14.     Button1: TButton;
  15.     Label1: TLabel;
  16.     procedure FormCreate(Sender: TObject);
  17.     procedure Button1Click(Sender: TObject);
  18.   private
  19.     { Private declarations }
  20.   public
  21.     { Public declarations }
  22.   end;
  23.  
  24. implementation
  25.  
  26. {$R *.DFM}
  27.  
  28. Uses TeeBrushDlg;
  29.  
  30. procedure TZoomPen.FormCreate(Sender: TObject);
  31. begin
  32.   inherited;
  33.   Chart1.Zoom.Pen.Color := clWhite ;
  34.   Chart1.Zoom.Brush.Style:= bsSolid;
  35.   Chart1.Zoom.Brush.Color:= clBlue;
  36.  
  37.   ButtonPen1.LinkPen(Chart1.Zoom.Pen);
  38.  
  39.   Series1.FillSampleValues(200);
  40. end;
  41.  
  42. procedure TZoomPen.Button1Click(Sender: TObject);
  43. begin
  44.   EditChartBrush(Self,Chart1.Zoom.Brush);
  45. end;
  46.  
  47. initialization
  48.   RegisterClass(TZoomPen);
  49. end.
  50.