Page 1 of 1

TPolar is only 1 color and printing wrong

Posted: Tue Apr 26, 2005 7:23 am
by 4207510
Hi,

I'm using TeeChart 5.02 with Delphi 6 and want to use a TPolar series. I've encountered the folowing problems :

1) I'm unable to change line color from one point to another.
2) When printing the plots arn't circular even with proportional on.

Is there any tricks that I can use, or are the issues solved in a later release ?

Posted: Tue Apr 26, 2005 8:32 am
by narcis
Hi York,
1) I'm unable to change line color from one point to another.

You can do it changing series pen color:

Code: Select all

Series1.Pen.Color:=clBlue;
2) When printing the plots arn't circular even with proportional on.


You should set circled property to true:

Code: Select all

Series1.Circled:=true;
Also notice that both properties can be configured using the chart editor at design-time.
Is there any tricks that I can use, or are the issues solved in a later release ?
What I suggested can be done using v5.02, however current version (v7.04) has many more features, enhancements, ... If you are interested you can download the fully functional evaluation version which includes a features demo that has examples of almost all features.

Posted: Tue Apr 26, 2005 9:44 am
by 4207510
Hi Narcis,

Thank You for the answer, but...

If I use Series1.Pen.Color:=clBlue the entire line will change color. I just want a segment between two points to change color like a TLineSeries can do it.

I'm using the property Series1.Circled:=true and the series is a circle on screen, but not when printed. Even with proportional on.

Can version v7.04 function with Delphi 6 or do I have to upgrade ?

Posted: Tue Apr 26, 2005 2:07 pm
by Pep
Hi,
If I use Series1.Pen.Color:=clBlue the entire line will change color. I just want a segment between two points to change color like a TLineSeries can do it.
This cannot be done with the existing version, you only can change the entire line or the a specific pointer using Series1.ValueColor[x] property.
I'm using the property Series1.Circled:=true and the series is a circle on screen, but not when printed. Even with proportional on.
This is a known bug, already added on our bug list. The whole problem is on screen ratio is not fully respected (because some circles are adjusted to fit in specific rectangle). We are aware of this problem and will try to find a better solution for nexr releases.

In the meantime, try using the StretchDraw print trick :

Code: Select all

var tmpMeta: TMetafile;
begin
  Chart1.BevelOuter := bvNone;
  Chart1.Frame.Visible := False;
  tmpMeta := Chart1.TeeCreateMetafile(True,Chart1.ClientRect);
  try
    Printer.Orientation := poLandscape;
    Printer.BeginDoc;
    try
      Printer.Canvas.StretchDraw(Rect(10,10,Printer.PageWidth - 10,
Printer.PageHeight - 10),tmpMeta);
    finally
      Printer.EndDoc;
    end;
  finally
    tmpMeta.Free;
  end;
end;
The key point is your printer drawing rectangle has the same proportions as original chart. If this is obeyed, then the circles will be round when printed too.
Can version v7.04 function with Delphi 6 or do I have to upgrade ?
Yes, the TeeChart v7.04 can work work Delphi6 (with all the updates).

Posted: Wed Apr 27, 2005 1:04 pm
by 4207510
Hi Pep,

Thank You very much. I'll look forward to the bug fix and try to convince our financial department to buy an opgrade :)