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

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 fit image in oncreate form event don't work

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

View 
UserName:
Password:
Format  Bold Italicized Underline  Align Left Centered Align Right  Horizontal Rule  Insert Hyperlink   Browse for an image to attach to your post Browse for a zip to attach to your post Insert Code  Insert Quote Insert List
   
Message 

 

Emoji
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Black Eye [B)]
Frown [:(] Shocked [:0] Angry [:(!] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
apresa Posted - Mar 09 2018 : 06:15:20
Hello all

I try fit image in oncreate form event with this code, but don't work :


Twndimagen.FormCreate(Sender: TObject);
begin
   imagenvisor.Fit;
end;


I try fit and not autofit since I want to have the zoom levels with the mouse interact.

TIA

Alfonso
3   L A T E S T    R E P L I E S    (Newest First)
xequte Posted - Mar 11 2018 : 18:31:07
Hi Alfons

The handle may not yet be available in OnCreate. Try using OnShow.



Nigel
Xequte Software
www.imageen.com
apresa Posted - Mar 10 2018 : 03:56:12
Hi Nigel:

I try with:

procedure Twndimagen.FormCreate(Sender: TObject);
begin
  
   // imagen.Fit(); 
   imagenvisor.Assign(imagen);
   imagenvisor.Fit;
end;


and don't work.

Image it's load but don't fit.

Alfonso
xequte Posted - Mar 09 2018 : 23:58:48
Hi Alfonso

The Fit command can only be used *after* you have loaded an image. Also, the handle may not yet be available in OnCreate. Try using OnShow.

Nigel
Xequte Software
www.imageen.com