Odd whole screen flicker on TChartEditorPanelCreation

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
rtaylor
Newbie
Newbie
Posts: 5
Joined: Thu Oct 18, 2007 12:00 am
Contact:

Odd whole screen flicker on TChartEditorPanelCreation

Post by rtaylor » Sat Aug 28, 2010 7:22 am

Hello,

I use TeeChart pro 8.07 with source and RAD Studio 2010 running on a Windows 7 machine/64 bit system. The program is a C++Builder .exe Application. Everything works just fine. However, since updating to 2010 and and 8.07 I've noticed that if I create any form which has contains a "TChartEditorPanel" component on it, when the program runs and does this in the main initialization code:

Application->CreateForm(__classid(TChartEditorF), &ChartEditorF);

The whole screen goes white and flickers for a 1/2 second before returning to normal. It looks very weird. If I delete the component off the form it stops doing it, or if I change the form to not be auto create it stops, until I later create the form when I need it at which time it does it again. In the above case "ChartEditorF" is a form which has a TChartEditorPanel" component on it.

Note that there is no functionality issue, everything works fine, but customers are wondering what this bizarre flicker is everytime the program is run (and so am I). I've tried sticking the TChartEditorPanel inside a small panel, setting it's state to not visible, and doing some other things to get it to stop doing it, but no luck.

Any suggestions? Would some kind of update to 2010 of Teechart solve this, or is that just a guess? Thank you in advance for any clues to this issue.

- Rebecca Taylor

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

Re: Odd whole screen flicker on TChartEditorPanelCreation

Post by Yeray » Mon Aug 30, 2010 1:56 pm

Hi Rebecca,

This could be related with the problem discussed here and here (TV52014993). It has been already fixed for the next maintenance release.

However, if you can arrange a simple example project we can run as-is to reproduce your problem here, we'll test it in the problematic release and with the actual sources to confirm it.
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

rtaylor
Newbie
Newbie
Posts: 5
Joined: Thu Oct 18, 2007 12:00 am
Contact:

Re: Odd whole screen flicker on TChartEditorPanelCreation

Post by rtaylor » Mon Aug 30, 2010 6:03 pm

Hello again,

Thank you for the quick reply. Here are the steps to recreate (and I've also attached a version for you that does it, both the source and a compiled version):

1) Create new C++ VCL Application
2) On the main form put a TDBChart component.
3) Set it's alignment to alRight and andjusted it to take up about 1/2 the form space on the right side (I don't know if this is necessary, it's just what I did).
4) Put a TeeChartEditorPanel on the left side of the form, and set it's alignment to the alClient (to take up the rest of the Form).
5) Set the TeeChartEditorPanel->Chart to point to the TDBChart.

Run it. That's it. It's works fine, but during the form creation the whole screen will flash for a tenth of a second and then go back to normal.

The issue is definitely with TCharEditorPanel. Leave it out and no problem. I've tried waiting and only creating it after a button press and the same problem, a big flash when that component is created. It does this regardless of the operating system (Vista, XP, and Win 7 machines all do the Flash).

Any help would be greatly appreciated, as customers are complaining about the weird flash when the program starts up.

- Rebecca

(I'm not sure my attachment worked, so you can also get it here: http://www.detllc.com/downloads/TeeChartEditorTest.zip

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

Re: Odd whole screen flicker on TChartEditorPanelCreation

Post by Yeray » Thu Sep 02, 2010 1:44 pm

Hi Rebecca,

I could reproduce it so I've added it to the defect list to be fixed in future releases (TV52015135).
I'm afraid I can't think on a workaround for this because as you say it happens simply creating the TChartEditorPanel.
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

rtaylor
Newbie
Newbie
Posts: 5
Joined: Thu Oct 18, 2007 12:00 am
Contact:

Re: Odd whole screen flicker on TChartEditorPanelCreation

Post by rtaylor » Thu Sep 02, 2010 3:59 pm

Hi Yeray,

Thank you for looking into it. I can tell you that as a temporary measure I've changed the code to create the component at runtime only when someone accesses this particular function, which fortunately is not a super commonly used part of my program, although I think it's a very cool function :), but not everybody uses it.

So the end result is that the flicker is gone on startup and now only seen when someone clicks the function to edit the chart. Everything still works great, and I've informed my tech support people that the flicker has moved. They seem happier, because they don't get a lot of calls about people using the Chart Editor part, but everyone was calling and asking about the weird flash on program startup.

It's a pretty simple solution, but here is the code that does that. First defined a pointer to a TChartEditorPanel:

TChartEditorPanel *ChartEditorPanel;

Then in the "FormShow" event I added this code:

if (ChartEditorPanel == NULL) {
ChartEditorPanel = new TChartEditorPanel(this);
ChartEditorPanel->Parent = this;
ChartEditorPanel->Chart = DBChart;
}

Note that "DBChart" is the TDBChart component I'm using the Editor Panel On. Now what happens is when this form is first shown I get a big flash, but it works fine, so it's kind of wash I guess. Overall better for most users.

- Rebecca

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

Re: Odd whole screen flicker on TChartEditorPanelCreation

Post by Yeray » Fri Sep 03, 2010 3:01 pm

Hi Rebecca,

I'm glad to hear that you've found how to (at least) minimize the problem.
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