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
 Suggestion: TIEMetaListView.CollapseGroups/ExpandGroups etc.
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

PeterPanino

982 Posts

Posted - Dec 19 2022 :  07:01:21  Show Profile  Reply
Using this HACK, I managed to collapse the TIEMetaListView Groups:

type
  TMyIEMetaListView = class(TIEMetaListView);

  IEMetaListViewImage.Items.BeginUpdate;
  try
    for var i := 0 to TMyIEMetaListView(IEMetaListViewImage).Groups.Count - 1 do
      TMyIEMetaListView(IEMetaListViewImage).Groups[i].State :=
        TMyIEMetaListView(IEMetaListViewImage).Groups[i].State + [lgsCollapsed];
  finally
    IEMetaListViewImage.Items.EndUpdate;
  end;


In this way, in my app I can toggle between expanded and collapsed metadata Groups:
https://www.screencast.com/t/szS0aDGZr8hj
https://www.screencast.com/t/NQuVGwP4Elz

1. Please implement TIEMetaListView.CollapseGroups/ExpandGroups methods

2. Please implement user click on Group headers to expand/collapse a single Group

3. Please mark Headers of Groups containing fields with metadata (e.g., with a specific icon or with an asterisk)

xequte

39053 Posts

Posted - Dec 20 2022 :  00:12:17  Show Profile  Reply
Hi

I have added all these features to the latest beta.

Note: You will need to use the OnGetHeadingText event to mark headers...

procedure TMainForm.IEMetaListGetHeadingText(Sender: TObject; MetaType: TIEMetaType; var Title: string; var Skip: Boolean);
begin
  // Add asterisk to the title if the file contains that type
  if IEContainsMetaData( ImageEnView1.IO.Params, MetaType ) then
    Title := Title + '*';
end;


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