problem with Transparency, TColorGridSeries, IrregularGrid
Posted: Thu Feb 05, 2009 1:27 am
Hello,
I am having trouble with the following code (put in the formCreate of a form with a TChart called Chart1):
If I have IrregularGrid set to True, then I just get a grey box where the blue pixels should be.
If I set IrregularGrid to false, I get blue pixels with no transparency.
is there something I can do to make this work?
I am having trouble with the following code (put in the formCreate of a form with a TChart called Chart1):
Code: Select all
var
xcntr: Integer;
ycntr: Integer;
newSeries: TColorGridSeries;
begin
newSeries:=TColorGridSeries.Create(chart1);
newSeries.ParentChart:=chart1;
newSeries.Pen.Visible:=False;
newSeries.BeginUpdate;
for xcntr := 0 to 100 do
for ycntr := 0 to 100 do
newSeries.AddXYZ(xcntr,0,ycntr,'',clYellow);
newSeries.EndUpdate;
newSeries:=TColorGridSeries.Create(chart1);
newSeries.ParentChart:=chart1;
newSeries.Pen.Visible:=False;
newSeries.IrregularGrid:=True;
newSeries.Transparency:=50;
newSeries.BeginUpdate;
for xcntr := 50 to 100 do
for ycntr := 50 to 100 do
newSeries.AddXYZ(xcntr,0,ycntr,'',clBlue);
newSeries.EndUpdate;
If I set IrregularGrid to false, I get blue pixels with no transparency.
is there something I can do to make this work?