Closed flywire closed 4 years ago
I do know what you mean, and this has annoyed me too. I will take a look.
Yes, this is doable.
The proposed rule is: last sort clicked, dominates. So if you want sort by sender, then subject, then date you would click the headers for date, subject and sender in that order, toggling each as you go to get ascending or descending as required. Does that sound right?
One question in my mind is to whether to limit the number of sorts applied, so that, say, sorts are applied to only the last two headers clicked, out of the four available (including attachments). What do you think?
Dijji
Applying a sort that preserves the previous sort order is called conservative (vs non conservative sort).
From an algorithm point of view, a conservative sort would preserve all the previous sorts that are applied. If you are concerned about the depth of the previous sorts, it suggests you are using non conservative sorting and then comparing on multiple fields. This doesn’t sound the efficient way to do it.
Best Regards
Ek
From: Dijji [mailto:notifications@github.com] Sent: 20 May 2020 11:49 To: Dijji/XstReader XstReader@noreply.github.com Cc: Subscribed subscribed@noreply.github.com Subject: Re: [Dijji/XstReader] Use Non-destructive Sort (#23)
Yes, this is doable.
The proposed rule is: last sort clicked, dominates. So if you want sort by sender, then subject, then date you would click the headers for date, subject and sender in that order, toggling each as you go to get ascending or descending as required. Does that sound right?
One question in my mind is to whether to limit the number of sorts applied, so that, say, sorts are applied to only the last two headers clicked, out of the four available (including attachments). What do you think?
Dijji
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/Dijji/XstReader/issues/23#issuecomment-631399002 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AFBBCXSUOOTUXDLWQSCOQNLRSOYQXANCNFSM4NET672A . https://github.com/notifications/beacon/AFBBCXSALXJTQF7YWM76Y6TRSOYQXA5CNFSM4NET672KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEWRGEWQ.gif
No, I wasn't worried about efficiency, but rather comprehensibility. The 'last one wins'approach seems to be a fairly standard solution, with the main drawbacks being discoverability and being required to think in reverse order. I was thinking that maybe restricting it to two levels (and making this visible by showing sort direction arrows on only two columns) might make the behaviour deducible to the uninitiated.
I was thinking about delegating the actual sort to the built-in capabilities of the WPF ListView, which actually seem to be acceptably efficient.
Dijji
Thinking open folder in the existing default order (Date?). A user could sort any field, repeating to toggle ascending/descending, for as many fields and times as they like. The effect would be if the sort order is not as required then the user keeps sorting until it is.
flywire okay, unlimited it will be. Thanks
Ek Good challenge, thank you. I completely omitted to say what I was worried about.
Changes released as version 1.11
Nice work.
I assume this is understood,
Say sort required by Name then Time. Sorting by
Date
thenFrom or To
should leave all records for eachFrom or To
inDate
order.