Chart Axes

  • Labels can be fully customized using Items[ ] array property.
    This makes easier to customize axis labels without using events like OnGetAxisLabel, etc. 
    Also, each label item is a full object with properties like Color, Font, etc.

Chart1.Axes.Left.Items.Clear; 
Chart1.Axes.Left.Items.Add( 123, 'Hello' ); 

  • Axes can be positioned along the Z (depth) direction when showing in 3D mode:

Chart1.Axes.Left.ZPosition := 100; 

  • Axes can have Offsets (in pixels) for both Minimum and Maximum scales:

Chart1.Axes.Left.MaximumOffset := 4 ;
Chart1.Axes.Left.MinimumOffset := 4 ;

  • Axis labels are now individual objects derived from TeeShape object.
    By default they are set to transparent, and can be configured to display a filled background, shadow, gradient, etc.

Chart1.Axes.Left.LabelsFormat.Color := clYellow ;

  • Axis in Logarithmic mode now accept floating point values for Logarithmic base.
    This allows, for example, setting a logarithmic axis of base "e" ( e = Exp(1) = 2.71...)

Chart1.Axes.Left.Logarithmic := True ;
Chart1.Axes.Left.LogarithmicBase := Exp(1) ;  // 2.71...

  • New PositionUnits property to specify PositionPercent as percentage or pixels.
     
 

Canvas

  • Charts can be rotated 180 degrees along the horizontal (x) axis.
    In previous versions, canvas was allowed to rotate 90 degrees only.
    Using OpenGL charts can be fully rotated 360 degree.
    Example to show how to "auto-hide" left and right walls while rotating the chart.

 

  • The center position of Radial gradients can be customized with the new Gradient.RadialX and RadialY properties:

Chart1.Walls.Back.Gradient.RadialX := 123;
Chart1.Walls.Back.Gradient.RadialY := -321;

 

  • Gradients provide a Balance property to apply more Start or more End colors:

Chart1.Walls.Back.Gradient.Balance := 40;  // %, default is 50 %

  • Canvas include new properties, methods and new overload methods:

Chart1.Canvas.FontZoom := 110; // % global font size zoom

Chart1.Canvas.Rectangle( R );

Chart1.Canvas.StretchDraw( R, Bitmap, Z ); // 3D stretch of pictures

Chart1.Canvas.Line( P0, P1 );   // P0 and P1 are TPoint 

Chart1.Canvas.PolyLine( [P0,P1,P2...] );

Chart1.Canvas.PolyLine( [P0,P1,P2...] , Z);  // for 3D 

Chart1.Canvas.Pixels[x,y] := clRed;  // now is read-write

Chart1.Canvas.RotatedEllipse( Left,Top,Right,Bottom,Z,Angle );

// returns if points are faced to viewer
TeeCull( P0,P1,P2 ):Boolean; 

PointAtDistance( FromPoint, ToPoint, Distance ):TPoint;

 

  • Anti-Aliasing. 
    Example of use of TeeAntiAlias procedure, to smooth curved lines on screen display.
  • Rotated Ellipses. 
    New Canvas RotatedEllipse method to draw ellipses in 3D mode with rotation.
  • Polyline method.
    New Canvas Polyline method to draw multiple lines at once, passing an array of TPoint.
  • StretchDraw 3D. 
    New Canvas method to display a bitmap in 3D mode with rotation.
  • RichText drawing.
    Example showing how to display RTF (RichText) formatted text over a Chart Canvas.
  • OrthogonalAngle now supports from 0 to 180 degree.

Chart Legend

  • Legend symbols can now display using a customized border.
    By default, legend symbols use the Series border.

Chart1.Legend.Symbol.DefaultPen := False ;
Chart1.Legend.Symbol.Pen.Color  := clRed ;

  • Legend symbols can now be "squared" (same width as height).

Chart1.Legend.Symbol.Squared := True ;

Chart Walls

  • The four chart walls now support transparency, even with gradient filling:

Chart1.Walls.Left.Transparency := 70 ; // % of transparency

  • The Back wall can now be filled with an image in 3D display mode (orthogonal or not).

 

Chart Panel

  • New Border pen and BorderRound properties, 
    to draw borders around chart panel in rectangular or rounded mode.
    This new Border is drawn outside the current bevels.
    The old "BorderStyle" property is now obsolete.

Chart1.Border.Color := clBlue ;
Chart1.BorderRound := 50 ;  // pixels 

 

  • Chart Margins can be expressed as percentage or pixels.

Chart1.MarginUnits := muPixels ;
Chart1.MarginLeft  := 10 ; // <--- 10 pixels

  • Chart Panel now includes a Shadow property.

Chart1.Shadow.VertSize := 6 ;

All Series

  • All Series styles now provide OnMouseEnter and OnMouseLeave events.
    These events are triggered when the mouse enters and exits a series point.

  • All Series now provide a new method to order points by their corresponding "Label" (point text):

Series1.SortByLabels( loAscending );  // default is ascending

 

All Series Marks

  • Series Marks new CallOut property, to change the appearance of lines connecting marks to series points.
    New styles: Callout, rectangle, ellipse... and new properties: size, brush, distance.

Series1.Marks.ArrowShape.Style := asArrowHead ;

  • Series Marks can now be individually customized (font, color, etc)

with Series1.Marks[3] do
begin
 
Font.Size:=14;
  Color:=clSilver;
end;

 

Bar and Horizontal Bar Series

  • Bar and Horizontal Bar series provide a new stacking style to display a single series "self stacked".

Series1.MultiBar:=mbSelfStack;

  • New bar style: "bsBevel" and BevelSize property, to draw a rectangular bevel (in 2D and orthogonal 3D modes only).

Bubble Series

  • Bubble series can now fill points using a gradient, with a default "radial" gradient style.

Series1.Pointer.Gradient.Visible := True ;

  • Bubble Transparency

Series1.Transparency := 50 ;

  • Small code to adjust left and rigth margins for Bubble charts:

var tmp : Integer;
begin
  with
Series1 do // (Series1 is a Bubble series)
  begin
   
tmp := GetVertAxis.CalcSizeValue(RadiusValues.First);
    GetHorizAxis.MinimumOffset := tmp;
    tmp : =GetVertAxis.CalcSizeValue(RadiusValues.Last);
    GetHorizAxis.MaximumOffset := tmp;
  end;
end;

 

Candle Series

  • New drawing style "csLine" to display a simple line using Close values.
     

ColorGrid Series

  • ColorGrid series can now display Marks.

Series1.Marks.Visible := True ;

  • ColorGrid can be displayed in "centered mode".
    This mode means cells will correspond to grid values. This is now the default mode.
    Previous version was "non-centered", thus eliminating one top-side row and one right-side column.

Series1.CenteredPoints := True ;

  • ColorGrid now accepts a Bitmap image as a datasource of grid values

var tmp : TBitmap;
begin
 
// temporary bitmap:
 
tmp:=TBitmap.Create;
  try
   
tmp.Assign(Image1.Picture.Graphic);
    Series1.Bitmap:=tmp;
  finally
 
tmp.Free;
end;

 

Contour Series

  • Contour series calculation of "levels" now provide a collection of "segments" (lines) per level.
    Each segment is composed of normal XY points.
    This permits mouse hit detection (Clicked function) and OnMouseEnter events.
  • A new property "Smoothing" draws level lines using a fitting spline function:

Series1.Smoothing.Active := True ;

  • New event in Contour series "OnBeforeDrawLevel".
    This event is called just before each contour level is going to be displayed.
    One example of use is to change the level Pen for some particular level lines.

FastLine Series

  • FastLine series now supports null points and can draw in "stairs" mode:

Series1.SetNull( 123 );   // <-- make null (empty) point index 123
Series1.IgnoreNulls := False; // <-- allow null points
Series1.Stairs := True;       // <-- set "stairs" mode

Pie Series

  • Pie series marks are now automatically positioned to avoid overlap as much as possible.

Series1.AutoMarkPosition := True ; 

  • New Pie Legend property to display "other" pie slice sub-elements in an extra legend

Series1.OtherSlice.Legend.Visible := True ;

  • New property to draw Pie slice borders using each slice color (instead of same Pen color for all slices)

Series1.DarkPen := True ;

Polar & Radar Series

  • New Gradient property to fill polar (and radar) interior.
     
  • New DrawZone method to fill circular background portions.
     
  • Support for Logarithmic axis.

Surface Series

  • Surface series can now display cells with transparency:

Series1.Transparency := 50 ; 

All 3D Series

  • All 3D Series (surface, contour, colorgrid, etc) include a new method
    to add a bi-dimensional array (x by z grid of values).

var A   : TArrayGrid;   // = array of array of double
    x,z : Integer;
begin
  SetLength( A, 5, 7 ) ; 
  for x:=0 to 4 do 
      for z:= 0 to 6 do 
          A[x,z] := Random ;
  Series1.AddArray( A );
end;

  • Custom Colors for individual points are no longer overriden by ColorRange or ColorPalette.
  • Small routine to perform "gridding".  
    The "Gridding" algorithm creates a regular grid (ie: surface) from arbitrary floating xyz points.

 

Chart Tools

  • Annotation Callout
    The annotation tool now provides a "Callout" sub-property, to display a line and a pointer shape, from the annotation to a given XY coordinate.
  • ColorLine 3D
    The ColorLine tool can optionally display the 3D part of the line (when in 3D display mode).

    New Style property to automatically display a line at axis Minimum, Center or Maximum.
     
  • Rotate Outline
    New pen property in Rotate tool to display a wireframe chart outline while rotating (while mouse is pressed), to avoid repainting the whole chart when rotating it.

    ChartTool1.Pen.Visible := True ;

Database Chart

  • Automatic Summary Order.  
    Summaries from databases can now be automatically sorted (in ascending or descending order) by summary calculation (value) or by summary group (text).
    The summary editor dialog includes new comboboxes to configure ordering at design-time or run-time.

 

Series1.XValueSource := '#SORTASC#GroupField' ;
Series1.YValues.ValueSource := '#SUM#ValueField' ;

  • Crosstab source component.
    Enables displaying a multi-series chart from a DataSet, grouping by a desired field.

Chart Editor

  • Example to show how to hide datasets in chart editor (series datasource tab)
     
  • New "RememberPosition" boolean property to persist the chart editor dialog position at runtime into registry.
     
  • New Series property to show desired Series editor when setting DefaultTab property to "General" or "Marks".

 

ChartGrid component

  • Grid 3D mode

ChartGrid component can now display XYZ series (3D series) data in "grid mode", instead of showing xyz data as three columns.

ChartGrid1.Series:=Series1; // <-- must be XYZ grid series
ChartGrid1.Grid3DMode:=True ;

New Chart Tools

  • 3D Transpose tool

3D Transpose tool "rotates" any 3D series 90 degrees.
It does exchange x with z values. 
Works with any Grid3D series (surface, etc).

A similar visual effect can also be obtained setting the Bottom and Depth axes Inverted 
property to True, although the transpose tool modifies the real xyz data.

  • Extra Legend tool

ExtraLegend tool displays additional legend objects.
The tool has a Series property to display legend with series values and / or texts.

  • Series Animation tool

The SeriesAnimation tool displays an animated growing chart:

ChartTool1.Execute; 

  • Gantt Mouse dragging tool

New tool ( GanttTool ) offers mouse interaction to drag and resize Gantt bars.

  • Grid Bands tool

The GridBand tool enables filling axis grid space with alternate color bands, each one using a different brush.

  • Pie focus tool

Displays a border around pie slice currently under mouse cursor.

New Components

  • TTeeXMLSource

New XML source component, to import xml data from files or web URL's into chart series.
The XML format to import data is the same as when exporting chart series data to XML.
Use of MSXML DOM activex object is done as late-bound, to avoid using typelibraries.
Please follow this web link for a Tutorial on using TeeXMLSource component.

The examples show how import one series from a Memo containing xml data,
and one full Chart from a URL pointing to a file with several series data in xml format.

  • TDBCrossTabSource

Enables creating crosstab charts from database datasets at design-time and runtime.

 

New Tee Functions

  • Smoothing Spline function

The new Smoothing function interpolates points using a B-Spline algorithm.
Several properties control the Spline calculation.
The smoothed points can optionally pass just exactly over the source points.

  • Custom y=f(x) function

New Custom function to calculate y = f(x) values using an OnCalculate event:

procedure TForm1.TeeFunction1Calculate(Sender: TCustomTeeFunction;
                          const x: Double; var y: Double);
begin
  y: = Sin(x / 10);
end;

  • Compression OHLC (Candle) function

Compression function calculates high and low values for a group of points.
Results are plotted using a Candle series.

Suitable for displaying Candle OHLC data "weekly", "monthly", etc.

  • Cross Points function

CrossPoints function calculates XY coordinates for crossing points of source line series.
The example shows a yellow line Series3 with points where Series1 and Series2 cross.

  • CLV (Accumulation/Distribution) financial function

  • OBV (On Balance Volume) financial function

  • CCI (Commodity Channel Index) financial function

  • PVO (Percentage Volume Oscillator) financial function

  • Performance function

Performance function calculate the percentage of difference between each source point and the first source point.
Calculation starts always at zero.

 

New Series styles

  • Point & Figure (financial)

  • Horizontal Area

  • Vector 3D

  • Tower 3D

  • Gauges (Instrumentation indicators)

New Export formats

  • Adobe Acrobat PDF (Portable Document Format)

  • PostScript format (EPS)

Miscellaneous

 

  • Delphi 7 support.
     
  • Delphi 3 support removed

  • Several Property aliases
     
  • Fixed bugs
     
  • StringGrid data to Chart example

  • Removed TeeProcs functions MaxLong, MinLong, MaxDouble and MinDouble.
    Replaced with equivalents Min and Max from Borland's Math unit.

  • New Series1.Clicked overload method (accepts a TPoint instead of x,y)

  • New function Series1.YValues.ToString( 123 )
    Same as calling: FloatToStr( Series1.YValues[123] )

  • Removed grid size limit in all 3D series (was 2000 x 2000).
    Internal xyz grid data is stored into dynamically growing arrays, with no limit on size.

  • Shadow object now provides transparency.
    TTeeShadow class is used by many other classes.

  • Area series displays Gradients when in Stairs mode.

  • New Series1.SetNull(123) method
    Equivalent to set: Series1.ValueColor[123]:=clNone

  • Removed special define TEENOCHECKOVER
    This define is no longer necessary. See below the new FastCalc property.

  • New Chart1.Axes.FastCalc property (to use fast assembler code)
    This property enables axis calculations (from values to screen pixels), using a faster code in assembler. Suitable for FastLine real-time charts.

  • Annotation tool now has TextAlignment (left , center or right)

  • Export data formats (Text,XML,HTML, etc) can now export series point Colors.

  • TeeCommander new property: EnablePieExploding (boolean, default True).
    This new property controls whether Pie series will be exploded or not when dragging pie slices with the mouse.

  • Axis LogarithmicBase property is now of type "double", thus allowing for example logarithmic axis of base "e" (2.71...)

  • ADX function provides two new properties of type TChartPen: DownLinePen and UpLinePen, to control display of ADX upper and lower lines.

  • Candle series improvement in Clicked function. Now correctly calculates if mouse XY is over a candle or candle-stick point.

  • ColorPalette[ ] array (TeeProcs.pas unit) is now a dynamic array variable to allow changing colors and expand the number of predefined colors for points and series. (ie: When Series ColorEachPoint is True).

  • Histogram series now correctly implements Clicked function, for mouse hit detection, etc.

  • Bar and Horiz. Bar Series with "Rect.Gradient" style, display in 3D too.

  • OnClick event at Axis Arrow tool.

  • Donut series can now display in 3D.

  • Canvas provides new method to draw images with 3D rotation. (StretchDraw)
    The Chart BackImage (in Inside mode), ColorGrid series and ChartImage tool benefit from this new method.

  • TeeChart Wizard now installed at Delphi / C++ Builder Help menu.
    It now allows loading Chart templates (*.tee files) at design-time for better reusability.
     
  • Transparency and export / print preview support in OpenGL canvas.