[Chart Legend] Change cursor when over the legend

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
bertrod
Advanced
Posts: 151
Joined: Wed Sep 07, 2005 4:00 am

[Chart Legend] Change cursor when over the legend

Post by bertrod » Wed Feb 15, 2006 9:31 am

Hello,

Is it possible to change the cursor when the mouse is floating over the legend, like with the axis and series ? I can't find any cursor property in the legend class.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Wed Feb 15, 2006 10:00 am

Hi bertrod,

Yes, you can do this:

Code: Select all

procedure TForm1.Chart1MouseMove(Sender: TObject; Shift: TShiftState; X,
  Y: Integer);
begin
  if Chart1.Legend.Clicked(X,Y) <> -1 then Chart1.OriginalCursor:=crNoDrop;
end;
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

bertrod
Advanced
Posts: 151
Joined: Wed Sep 07, 2005 4:00 am

Post by bertrod » Wed Feb 15, 2006 11:04 am

Thanks.

I have also a problem with the annotations : if I change the annotation's cursor, the dragging action is not fluently anymore.

You can see this in the ChartOffice program : if you create an annotation and then change its cursor to handpoing, you'll see that there are little problems when you drag it. Is it a bug ? And is there a way to correct it ?

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Wed Feb 15, 2006 11:46 am

Hi bertrod,

I'm not able to reproduce that problem using TeeChartOffice v3 (the version shipped with TeeChart Pro v7 VCL). Which TeeChartOffice version are you using?
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

bertrod
Advanced
Posts: 151
Joined: Wed Sep 07, 2005 4:00 am

Post by bertrod » Wed Feb 15, 2006 12:02 pm

I have the version 3.0 of TeeChartOffice.

1. Create an annotation
2. Move it somewhere
3. Dbl-click on it to edit it
4. Change the cursor to Handpoint
5. Now click on the left of the annotation, and move it to the right

In my version, the annotation is moved only the mouse pointer is leaving the shape. So when i move the mouse, the annotation is moving in a jerky way, like stepwise, instead of fluently.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Wed Feb 15, 2006 12:13 pm

Hi bertrod,

I'm still unable to reproduce the problem here following your steps and using TeeChart Pro v7.06 VCL. Which TeeChart version are you using?

Thanks in advance.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

bertrod
Advanced
Posts: 151
Joined: Wed Sep 07, 2005 4:00 am

Post by bertrod » Wed Feb 15, 2006 1:16 pm

I have TeeChart Pro v7 , i can't find the exact version number.

I noticed that this "jerky" dragging happens when I'm using a cursor which is not the default one. It happens only for annotations.

Is the annotation moving fluently in your version ?

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Wed Feb 15, 2006 1:34 pm

Hi bertrod,

Yes, it moves fluently in my version whichever the cursor is. To know which TeeChart version you have you can right-click on a TChart in a form. However, you could try downloading v7.06 from our Customer Download Area.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

bertrod
Advanced
Posts: 151
Joined: Wed Sep 07, 2005 4:00 am

Post by bertrod » Wed Feb 15, 2006 2:06 pm

I have the 7.04 version.

Can I be sure that upgrading my current version won't cause problems with the current code :?:

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Wed Feb 15, 2006 3:15 pm

Yes, v7.06 is fully backwards compatible with v7.04 and has some additional features and bug fixes.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

bertrod
Advanced
Posts: 151
Joined: Wed Sep 07, 2005 4:00 am

Post by bertrod » Thu Feb 16, 2006 12:18 pm

Ok thanks. I will try to install the latest version.

Post Reply