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
 TImageEnFolderMView Custom Sort Order
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

keithml

USA
18 Posts

Posted - Oct 02 2013 :  07:17:11  Show Profile  Reply
Hi. I love the new TImageEnFolderMView control. I just wanted to make a quick feature request. If you could add a custom sort option for sorts not on your sort order types, that would be VERY helpful.

Thanks,
Keith

xequte

38182 Posts

Posted - Oct 02 2013 :  21:04:00  Show Profile  Reply
Hi Keith

Sorry, it is not obvious, but you can still use TImageEnMView.Sort if you need custom sorting:

http://www.imageen.com/help/TImageEnMView.Sort.html

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

keithml

USA
18 Posts

Posted - Oct 11 2013 :  11:48:04  Show Profile  Reply
Its not clear how this would work properly with FolderMView. The problem is that when I set the Folder property, the component sorts and displays the thumbnails, I would then have to sort which seems to confuse things greatly. And updates for files complicates things more. The Help entry for Sort even states:

"DO NOT USE for TImageEnFolderMView! Use properties SortOrder and SortAscending instead."

Obviously having a SortOrder of custom would be the cleanest method of handling this, but in the meantime, how would I get this to work properly?

Thanks,
Keith
Go to Top of Page

xequte

38182 Posts

Posted - Oct 13 2013 :  23:07:25  Show Profile  Reply
Hi Keith

Thanks for reminding me what I wrote in the help file.

To use the use custom sort of TImageEnMView you need only call it after filling the content:

In Create:
IEFolderMView1.SortOrder := iesbNone;

Whenever setting folder:
IEFolderMView1.LockUpdate;
try
  IEFolderMView1.Folder := sNewFolder;
  IEFolderMView1.Sort(MyCustomSortCompare);
finally
  IEFolderMView1.UnlockUpdate;
end;


I'll look into a custom sort option for a coming update.

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

keithml

USA
18 Posts

Posted - Oct 14 2013 :  06:34:11  Show Profile  Reply
Thanks, couldn't be any easier. I think it was the warning in the help file that stopped blood from flowing to my brain on that one.

Keith
Go to Top of Page

xequte

38182 Posts

Posted - Oct 17 2013 :  18:34:59  Show Profile  Reply
Hi

In v5.0.1 we have added a SortOrder of iesbCustom, to use in conjunction with TImageEnFolderMView.OnCustomSortCompare



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

keithml

USA
18 Posts

Posted - Oct 19 2013 :  13:46:42  Show Profile  Reply
GREAT! Thanks. That makes it nice and tidy.

Keith
Go to Top of Page

supersk

95 Posts

Posted - Oct 21 2013 :  00:00:23  Show Profile  Reply
How to display own defined format image in the TImageEnFolderMView?
Go to Top of Page

xequte

38182 Posts

Posted - Oct 21 2013 :  02:03:07  Show Profile  Reply
Hi

For unknown formats you can use the OnWrongImage event to fill the thumbnail.

http://www.imageen.com/help/TIEWrongImageEvent.html

Alternatively you can use one of the custom drawing events.



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

mmiranda

Chile
13 Posts

Posted - Feb 16 2017 :  09:37:43  Show Profile  Reply
Hi

I'm using TImageEnFolderMView and ImageEn ver 6.3.2

My question is:
How to keep the new order when moving objects on a TImageEnFolderMView?

I Mean, if i move a picture on a TImageEnFolderMView to a diferent position, how to keep that picture in that new position even refreshing FileList or reopening the imagefolder?

(Working with Delphi 7)

Thanks for your time
Go to Top of Page

xequte

38182 Posts

Posted - Feb 16 2017 :  15:23:37  Show Profile  Reply
Hi

That would be your own custom sorting order, so you would need to set the SortOrder to iesbCustom, and use the TImageEnFolderMView.OnCustomSortCompare event to set the position of "moved" files according to your rules.



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: