Briefly turn off visual update.

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
MVBobj
Newbie
Newbie
Posts: 34
Joined: Fri Jul 17, 2015 12:00 am
Contact:

Briefly turn off visual update.

Post by MVBobj » Tue Sep 15, 2015 9:42 pm

Hi,

There are times in my project where I need to update the chart in more than one way - for example: I may want to update the bottom axis Min and Max values and also the left axis Min and Max values. There is a somewhat noticeable jump in between those due to the chart visually updating after the bottom axis update and then again after the left axis update. Is there any way to have the chart disable updating and then re-enable updating when all current updates are complete?

Thank you.
.

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

Re: Briefly turn off visual update.

Post by Yeray » Wed Sep 16, 2015 12:14 pm

Hello,

Yes, you can turn off/on AutoRepaint property:

Code: Select all

  Chart1.AutoRepaint:=false;
  Chart1.Axes.Bottom.SetMinMax(xmin, xmax);
  Chart1.Axes.Left.SetMinMax(ymin, ymax);
  Chart1.AutoRepaint:=true;
  Chart1.Draw;
Don't forget to force a chart repaint after enabling AutoRepaint or the changes won't take effect.
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