THighLowSeries with Gradient

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
davidnovo
Newbie
Newbie
Posts: 15
Joined: Mon Nov 30, 2009 12:00 am

THighLowSeries with Gradient

Post by davidnovo » Tue Feb 23, 2010 11:27 am

Hello,

I just noticed that you can fill the area between the high and low lines in a THighLow series. But it seems you can only fill it with a solid color. Is it possible to fill it with a gradient, such that the middle between the high-low is the darkest and as it approaches the high or the low it becomes lighter (or transitions to whatever the secondary gradient color is)?

Ideally there should be a few gradient options, left to right, right to left, top to bottom, bottom to top, center to outside, outside to center...

I will be happy with just center to outside :-)

If this series won't do it, is there another I can use. I have varying high-low Y values as I go across the X axis, so a horizontal bar won't work

Yeray
Site Admin
Site Admin
Posts: 9613
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia
Contact:

Re: THighLowSeries with Gradient

Post by Yeray » Tue Feb 23, 2010 2:42 pm

Hi davidnovo,

The following seems to work fine here for THighLowSeries:

Code: Select all

procedure TForm1.FormCreate(Sender: TObject);
begin
  Chart1.View3D:=false;

  Series1.FillSampleValues();
  with Series1.HighBrush do
  begin
    Style:=bsSolid;
    Gradient.Visible:=true;
    Gradient.StartColor:=clRed;
    Gradient.EndColor:=clYellow;
    Gradient.Direction:=gdTopBottom;
  end;
end;
Best Regards,
ImageYeray Alonso
Development & Support
Steema Software
Av. Montilivi 33, 17003 Girona, Catalonia (SP)
Image Image Image Image Image Image Please read our Bug Fixing Policy

Post Reply