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
 Selection with background
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

graph_man

328 Posts

Posted - Jun 01 2017 :  19:10:33  Show Profile  Reply
Hi,
Is ability to set background color to selection?
This feature should work at selection only (not IEView->Pro->Fill)

xequte

38615 Posts

Posted - Jun 02 2017 :  16:01:12  Show Profile  Reply
Hi

Not a built in method, but just get the selection(ImageEnView1.SelectedRect) and draw a rect directly to the canvas (ImageEnView1.IEBitmap.Canvas)

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

graph_man

328 Posts

Posted - Jun 02 2017 :  19:50:11  Show Profile  Reply
I need to get it automatically at selection, resizing and moving selection.
Go to Top of Page

xequte

38615 Posts

Posted - Jun 04 2017 :  02:10:02  Show Profile  Reply
Hi

In that case, just paint it onto the canvas in the OnDrawCanvas event:

https://www.imageen.com/help/TImageEnView.OnDrawCanvas.html

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

graph_man

328 Posts

Posted - Jun 04 2017 :  08:05:29  Show Profile  Reply
How to be at moving, resizing and clearing?
Go to Top of Page

xequte

38615 Posts

Posted - Jun 04 2017 :  21:00:32  Show Profile  Reply
Resizing and clearing should automatically call the OnDrawCanvas event. For movement of the mouse you will need to invalidate the control to trigger OnDrawCanvas.



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

graph_man

328 Posts

Posted - Jun 05 2017 :  06:09:56  Show Profile  Reply
Send me please an example.
Go to Top of Page

xequte

38615 Posts

Posted - Jun 06 2017 :  17:54:57  Show Profile  Reply
Hi

Please try using the instructions above and let us know if you have any difficulty.

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

graph_man

328 Posts

Posted - Jun 06 2017 :  18:01:04  Show Profile  Reply
> Please try it

What I need to try?
Go to Top of Page

graph_man

328 Posts

Posted - Jun 11 2017 :  15:25:10  Show Profile  Reply
Send me please an example code.
Go to Top of Page

xequte

38615 Posts

Posted - Jun 11 2017 :  19:35:16  Show Profile  Reply
Hi

The process should be quite straightforward. Which part are you having difficulty with?


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

graph_man

328 Posts

Posted - Jun 12 2017 :  03:58:05  Show Profile  Reply
I need a selection area to be colored.
But not canvas. Only selected area.
If you deselect - the colored area should not remain.

How to do that?


ps
> For movement of the mouse you will need to invalidate the control to trigger OnDrawCanvas.

How to do that?
Go to Top of Page

xequte

38615 Posts

Posted - Jun 12 2017 :  17:51:29  Show Profile  Reply
> I need a selection area to be colored. But not canvas. Only selected area.
> If you deselect - the colored area should not remain.

The canvas in the OnDrawCanvas event is not the image canvas, but the control canvas, so it does not affect the image.


>> For movement of the mouse you will need to invalidate the control to trigger OnDrawCanvas.
>
> How to do that?

ImageEnView1.Invalidate();

Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: