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 to suspend SetNavigator temporarily?
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

Uwe

284 Posts

Posted - Oct 27 2012 :  12:15:54  Show Profile  Reply
I have two ImageEnVect's which are connected to each other via


ImageEnVect1.SetNavigator(ImageEnVect2, [ienoMOUSEWHEELZOOM, ienoMARKOUTER])


How can I temporarily suspend the connection between the two ImageEnVect's?

I tried

ImageEnVect1.SetNavigator(nil, [ienoMOUSEWHEELZOOM, ienoMARKOUTER])

but that doesn't seem to do the trick even though it compiles.


Thx
Uwe

w2m

USA
1990 Posts

Posted - Oct 27 2012 :  16:21:14  Show Profile  Reply
Just set Navigator to nil...ImageEnView1.SetNavigator(nil);
This works as expected in the ...Samples\Display\Navigator example.

procedure Tfmain.ToggleNavigator1Click(Sender: TObject);
begin
  if ToggleNavigator1.Checked = True then
  begin
    ImageEnView1.SetNavigator(fnav.ImageEnView1);
    fnav.ImageEnView1.SelectionOptions := fnav.ImageEnView1.SelectionOptions+[iesoMarkOuter];
  end
  else
  begin
    ImageEnView1.SetNavigator(nil);
  end;
end;

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

Uwe

284 Posts

Posted - Oct 28 2012 :  10:05:01  Show Profile  Reply
Hi William


EDIT:

Found the culprit! I have some custom code that scales the image to a certain percentage of the main ImageEnVect's size before displaying it. Even though this code is very fast and quite simple, the calculation of the new image size slows down the navigator significantly - almost to a point where it becomes unusable.

So, what have I learned from this? Do not use an image navigator unless the image is displayed at 100%.

Hope this helps someone in the future

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