Steema Issues Database

Note: This database is for bugs and wishes only. For technical support help, if you are a customer please visit our online forums;
otherwise you can use StackOverflow.
Before using this bug-tracker we recommend a look at this document, Steema Bug Fixing Policy.



Bug 197

Summary: [TV52014958] GradientRelative property for TAreaSeries as in TeeChart for .NET. TB...
Product: VCL TeeChart Reporter: narcís calvet <narcis>
Component: CanvasAssignee: Steema Issue Manager <issuemanager>
Status: CONFIRMED ---    
Severity: major    
Priority: Normal    
Version: unspecified   
Target Milestone: ---   
Hardware: All   
OS: All   
Chart Series: --- Delphi / C++ Builder RAD IDE Version:

Description narcís calvet 2013-11-20 10:03:04 EST
GradientRelative property for TAreaSeries as in TeeChart for .NET. TBarSeries already has it.
In v2010.00 the gradients were refactored, at Series.pas 1.54, breaking the gradient for the area in a TLineSeries (DrawArea:=true), and making the TAreaSeries gradient to be drawn for each value, not a unique gradient grom the max YValue to the bottom.
In .NET you can't set TLineSeries DrawArea property, it's always false.
In VCL we should decide if we allow this or not, and enable the GradientRelative property if we decide to have the DrawArea.
Code to reproduce the problem. See the result in the actual version and in v8 (images attached).
The fucsia color isn't used, the TLineSeries area doesn't draw any gradient, and the TAreaSeries gradient is "per value".
  Chart1.View3D:=false;
  with Chart1.AddSeries(TLineSeries) as TLineSeries do
  begin
    DrawArea:=true;
    Gradient.Visible:=true;
    Gradient.StartColor:=clWhite;
    Gradient.EndColor:=clFuchsia;
    AreaLinesPen.Visible:=false;
    GradientRelative:=false;
  end;
  with Chart1.AddSeries(TAreaSeries) as TAreaSeries do
  begin
    Gradient.Visible:=True;
    Gradient.StartColor:=clWhite;
    Gradient.EndColor:=clFuchsia;
    AreaLinesPen.Visible:=false;
    GradientRelative:=true;
  end;
  for i:=0 to 9 do
  begin
    Chart1[0].AddXY(i,i);
    Chart1[1].AddXY(i+9,10-(i+1));
  end; [created:2010-06-10T16:14:00.000+01:00 reported by:narcis@steema.com reported in version:2010.00.00407 (TeeChart VCL)]