ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 How do I activate the pan cursor?
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

stwizard

USA
46 Posts

Posted - Nov 04 2013 :  09:40:22  Show Profile  Reply
Greetings,

Delphi
TImageEnVect

In an older version of ImageEn (3.1.2) any time an image was larger than the component viewing area and the user would move the mouse over the image, the mouse cursor would automatically change to the pan cursor (1782 - Hand), of course if the image was smaller then the viewing area of the component the mouse cursor would not change when left clicked.


80.78 KB

I have not tried the latest version just released, but in version 4.1.3 this does not seem to work any longer.

I brought up an old demo app I had on my OLD computer which uses verson 3.1.2 and this works fine. Then I bring up a current project on my NEW computer which uses version 4.1.3 and it does not work.

I carefully checked all of the properties on the OLD demo app against the properties of my current app on the NEW computer and do not see any differences on how the component is setup up.

I also checked to see if I had any events setup and I do not on either application.

So has something changed between the two versions or am I missing something?

Any help would be appreciated.

Thanks,
Mike

w2m

USA
1990 Posts

Posted - Nov 04 2013 :  10:31:07  Show Profile  Reply
AutoCursors did not work with my copy of Version 5.0 either, so I investigated my version and found two lines of code were remarked. When I removed the remarks autocursors preformed as expected.

For Autocursors to work as you describe you must do the following:

1. The AutoCursors property must be true:
ImageEnView.AutoCursors := True;
2. MouseInteract must be miScroll
ImageEnView1.MouseInteract := [miScroll];

Then change this if your versions code is the same:
ImageEnView.pas:
procedure TImageEnView.SetCursor(Value: TCursor);
begin
  if assigned(fOnSetCursor) then
    fOnSetCursor(self, Value);
  fLCursor := Value;
  inherited Cursor := Value;
  fCursor := Value;
  Windows.SetCursor(Screen.Cursors[Value]);  {was remarked so AutoCursors fail}
end;

procedure TImageEnView.SetTempCursor(Value: TCursor);
begin
  if assigned(fOnSetCursor) then
    fOnSetCursor(self, Value);
  if fAutoCursors then
  begin
    inherited Cursor := Value;
    fCursor := Value;
    Windows.SetCursor(Screen.Cursors[Value]); {[b]was remarked so AutoCursors fail}[\b]
  [b]end;
end;

ImageEnVect is a descendent of ImageEnView so this should fix ImageEnVect as well.

William Miller
Adirondack Software & Graphics
Email: w2m@frontiernet.net
EBook: http://www.imageen.com/ebook/
Apprehend: http://www.frontiernet.net/~w2m/index.html
Go to Top of Page

stwizard

USA
46 Posts

Posted - Nov 04 2013 :  11:19:16  Show Profile  Reply
ImageEnVect does not have an AutoCursors property in either version
Go to Top of Page

xequte

39109 Posts

Posted - Nov 04 2013 :  12:04:08  Show Profile  Reply
Hi Mike

TImageEnVect is a descendent of TImageEnView, so it has all its properties, including AutoCursors.

This issue is fixed in v5.0.1 which will be ready shortly.



Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page

w2m

USA
1990 Posts

Posted - Nov 04 2013 :  12:09:15  Show Profile  Reply
You have to edit ImageEnView not ImageEnVect as I suggested.

William Miller
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: