Page 1 of 1

TChart transparency bug

Posted: Wed Oct 27, 2010 4:10 pm
by 16557452
I think there is a pretty obvious bug in TChart, but of course, I may well be wrong!

Anyway, if you just create a chart, display it on a form, set Align to alClient and then make it transparent (Chart.Color := clNone). Then when you resize the form the chart fails to repaint correctly. The problem is that the background doesn't get redrawn at all (TCustomTeePanelExtended.PaintBack) and this is all compounded by the including of WS_EX_TRANSPARENT in Params.ExStyle in TCustomTeePanel.CreateParams.

What I found was that it seemed better to comment out the WS_EX_TRANSPARENT code and then include some extra code in TCustomTeePanelExtended.PaintBack to call ThemeServices.DrawParentBackground if the window is transparent.

I'd appreciate it if one of the developers could look into this and at the very least confirm that my hack is a reasonable solution.

Re: TChart transparency bug

Posted: Thu Oct 28, 2010 11:34 am
by narcis
Hi David,

Thanks for your feedback. I have been able to reproduce the problem here and added it (TV52015252) to the defect list to be investigated. At this moment I'm not able to tell you if this is a good solution, I'd need some more time for investigating it but we don't have any inconvenient in you using it if it works fine for you.