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
 Position TImageEnVect1 to show lower right image

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
stwizard Posted - Mar 17 2017 : 09:54:26
Greetings All,

I load the image of a Bank Check into a TImageEnVect component, set the zoom to 75% and show just the upper right portion of the check where the payor name and address is shown.

procedure TfrmBalanceInnovationsImport.LoadImage;
var
  sFileName: String;
begin
  inherited;
  if bProcessingImport then
    Exit;

  sFileName := sReceiveDir + cdsBalanceInnovationsProcessingIMAGE_FILENAME.AsString + '.tif';

  ImageEnVect1.IO.LoadFromFileTIFF(sFileName);
  ImageEnVect1.AutoFit := False;
  ImageEnVect1.Zoom := 75;

  //* Position to top left of image
  ImageEnVect1.ViewX := 0;
  ImageEnVect1.ViewY := 0;

  Application.ProcessMessages;
end;

I would then like to be able to show at the zoom level the lower right corner of the check where the signature line is. How do I code this?

I tried the following and it did drop to the bottom of the check fine, but only scroll over to the right about 3/4 of the check image. So I have to manually finish moving the check image to the left to see this information.

procedure TfrmBalanceInnovationsImport.btnSignatureClick(Sender: TObject);
begin
  inherited;
  //* Position to bottom right of image
  ImageEnVect1.ViewX := ImageEnVect1.Height;
  ImageEnVect1.ViewY := ImageEnVect1.Width;
end;
1   L A T E S T    R E P L I E S    (Newest First)
stwizard Posted - Mar 17 2017 : 09:57:15
Shortly after posting this I figured it out and thought I would share in case others would like to know:

  //* Position to bottom right of image
  ImageEnVect1.ViewX := ImageEnVect1.IEBitmap.Height -1;
  ImageEnVect1.ViewY := ImageEnVect1.IEBitmap.Width -1;