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 2035

Summary: Painting artefacts when some values = 0 between non-zero values in pie chart in ReportBuilder
Product: VCL TeeChart Reporter: Toni Grabmayr <toni.grabmayr>
Component: SeriesAssignee: Steema Issue Manager <issuemanager>
Status: RESOLVED FIXED    
Severity: major CC: toni.grabmayr, yeray
Priority: ---    
Version: 24.180321   
Target Milestone: ---   
Hardware: PC   
OS: Windows   
Chart Series: --- Delphi / C++ Builder RAD IDE Version:
Attachments: Screenshot, RB-RTM-file
GDI+ Configuration in RB designer

Description Toni Grabmayr 2018-05-14 04:58:58 EDT
Hi

Please see attached screen shot and RB-RTM-file. Whenever there's a zero-value between non-zero-values there are painting artefacts with a line painted outside the graph.

regards

Toni
Comment 1 Toni Grabmayr 2018-05-14 05:00:16 EDT
Created attachment 829 [details]
Screenshot, RB-RTM-file
Comment 2 yeray alonso 2018-05-23 06:58:44 EDT
I can reproduce the problem with this simple example:

uses Series, TeCanvas;

procedure TForm1.FormCreate(Sender: TObject);
begin
  with Chart1 do
  begin
    View3D := False;
    Canvas := TTeeCanvas3D.Create;
    with Chart1.AddSeries(TPieSeries) as TPieSeries do
    begin
      AddPie(0);
      AddPie(9);
      AddPie(0);
      AddPie(0);
      AddPie(1);
    end;
  end;
end;

Note this is reproducible in GDI, but works fine in GDIPlus. Try changing the DefaultCanvas property in your .rtm as follows:

DefaultCanvas = 'TGDIPlusCanvas'
Comment 3 Toni Grabmayr 2018-05-23 09:56:29 EDT
Hi

I tried to set this via RB's designer. However, the GDI+ option in tab "Render" can be set but this value seems not to be stored as always when I re-enter the original values remain (GDI).

Have I got to extend the underlying uses clause to be able to set this? Which units should there be?

Regards

Toni
Comment 4 Toni Grabmayr 2018-05-23 09:58:10 EDT
Created attachment 831 [details]
GDI+ Configuration in RB designer
Comment 5 yeray alonso 2018-05-23 10:16:19 EDT
TGDIPlusCanvas is defined in TeeGDIPlus unit. Try adding it to the uses clause.

Other alternatives I see here:

- Contact Digital Metaphors to check if they are forcing GDI in the charts in their reports and, in that case, check if there's a way to activate GDIPlus.

- Generate an image from a hidden (or without parent) TChart and use that image in  the report.
Comment 6 Toni Grabmayr 2018-05-24 04:21:47 EDT
I added TeeGDIPlus to the uses. This results in bringing other options when I choose GDI+ in the chart's configuration. However, this setting is not taken over when clicking "close"-button.

The concerning report is designed withen RB's designer at runtime using your (additional) component to design/configure the chart. Beside TeeGDIPlus which units have to be added to the uses clause to achive at least a saving of the chosen options?

Further when I try to change an option within GDI+ settings I run into an Exception what indicates that either this all doesn't work at all or there are missing units. Please advise which additional units have to be in my uses clause.

If this all is not achievable isn't it possible for you to fix the problem with the 0-lines in GDI as well?

Regards

Toni
Comment 7 yeray alonso 2018-05-25 07:18:17 EDT
(In reply to Toni Grabmayr from comment #6)
> I added TeeGDIPlus to the uses. This results in bringing other options when
> I choose GDI+ in the chart's configuration. However, this setting is not
> taken over when clicking "close"-button.

> Further when I try to change an option within GDI+ settings I run into an
> Exception what indicates that either this all doesn't work at all or there
> are missing units. Please advise which additional units have to be in my
> uses clause.

Can any of these problems be reproduced without Report Builder? If not, I'd contact Digital Metaphors to see if they can do anything at their side.

(In reply to Toni Grabmayr from comment #6)
> The concerning report is designed withen RB's designer at runtime using your
> (additional) component to design/configure the chart. Beside TeeGDIPlus
> which units have to be added to the uses clause to achive at least a saving
> of the chosen options?

With just a Chart on the form, without RB, you can activate GDIPlus by just adding TeeGDIPlus to the uses clause. I'm not sure if there's any other requirement in the integration of TeeChart into RB. Digital Metaphors supports this integration.

(In reply to Toni Grabmayr from comment #6)
> If this all is not achievable isn't it possible for you to fix the problem
> with the 0-lines in GDI as well?

I've just fixed for the next maintenance release, so I'll close this ticket.