Page 1 of 1

Wish: Sort Method: natural Like Explorer

Posted: 2023-05-07, 02:05 UTC
by Sir_SiLvA
[A]
Until TC Version 6.58 final, TC would sort and display files the same way the Explorer and DOS do.
With TC 7.0 "natural" sorting was implemented so that the sorting of files is NEVER the same way as it is in explorer:
https://imgur.com/a/pP0S2g2
(displayed are the wrong sort order of TC8/10 [that TC11 also uses]) and the correct sort order in explorer, dos and tc pre 7.0)

Therefor I wish for the "sort method: like explorer" aka windows natural sort order to be implemented.


Example with the following files (sort order in tc natural code and numbers) and IrfanView is called upon enter to view an image:
Apple.jpeg
Apple_TV_Plus_Logo.png
Apple_TV_Plus_Logo.svg
apple tv+.png
Download.jpg

I press enter on the file "apple tv+.png" and IrfanView opens with the picture.
Upon pressing space I now get the file Apple.jpeg displayed instead of download.jpg

Thanks for reading!

PS: even Double Commander displays them out of the box in the explorer-order

(maybe this is even a bug as I can only replicate the sort order of in D7 & function StrCmpLogicalW from Shlwapi.dll
when I compare the filenames without extension.)

Re: Wish: Sort Method: natural Like Explorer

Posted: 2023-05-07, 10:31 UTC
by ghisler(Author)
Total Commander splits file names into name and extension. It then sorts by name first, and if they are the same, by extension. The Explorer seems to sort by the combined name+extension string directly.

Re: Wish: Sort Method: natural Like Explorer

Posted: 2023-05-07, 12:41 UTC
by tuska
See also:
Topic in Forum „Total Commander (Deutsch)“: "Falsche Sortierung bei Punktgetrennten Dateierweiterung"
Topic-title translated .............................: "Wrong sorting with dot delimited file extension"
tuska wrote: 2023-04-27, 22:15 UTC Solange es unter Konfigurieren > Ansicht > keine entsprechende Sortiermethode gibt,
wird man weder mit einer benutzerdef. Spaltenansicht noch mit einem Ansichtsmodus
eine Freude haben, denn die Namen und Dateiextensions würden in so einem Fall doppelt angezeigt.
---
As long as there is no corresponding sorting method under Configuration > Options... > Display > Sort method,
you will not be happy with either a 'Custom columns view' or a 'View mode' ... [=tc.fullname]
because the names and file extensions would be displayed twice in such a case.

Re: Wish: Sort Method: natural Like Explorer

Posted: 2023-05-07, 18:21 UTC
by petermad
2Sir_SiLvA

Here is the order I get in TC with "Natural sorting: alphabetical and numbers" set:
Apple.jpeg
apple tv+.png
Apple_TV_Plus_Logo.png
Apple_TV_Plus_Logo.svg
Download.jpg

Here is the order in TC with "Natural sorting: by character code and numbers" set (this looks like what you show):
Apple.jpeg
Apple_TV_Plus_Logo.png
Apple_TV_Plus_Logo.svg
apple tv+.png
Download.jpg

Here is the order in TC when sort order set to Unsorted (hence using the NTFS filesystem's order)
apple tv+.png
Apple.jpeg
Apple_TV_Plus_Logo.png
Apple_TV_Plus_Logo.svg
Download.jpg

And here is what I see in Windows Explorer:
apple tv+.png
Apple.jpeg
Apple_TV_Plus_Logo.png
Apple_TV_Plus_Logo.svg
Download.jpg

And here is the order I get when pressing Space in IrfanView:
apple tv+.png
Apple.jpeg
Apple_TV_Plus_Logo.png
Download.jpg

Notice that the sequence Irfanview is showing the files in is unrelated to the curent order of the files in TC

Iin Lister-view on the other hand the sequence the pictures are shown in when pressing N, is like it is shown in the file panel.

So on NTFS drives you can use Unsorted view in TC to get the same as Explorer - except that numbers like 1,2,10 will not be sorted naturally but like1, 10, 2.

On FAT drives Unsorted order will show the files more or less in the sequence they were placed in the folder.

So you can improve the situation by changing from "Natural sorting: by character code and numbers" to "Natutal sorting: alphabetical and numbers" but still and Apple.jpeg and apple tv+.png are switched.

"Natural sorting: alphabetical and numbers" is supposed to be the same used by windows, but then not apparent because of what Ghisler writes:
Ghisler wrote:The Explorer seems to sort by the combined name+extension string directly.

Re: Wish: Sort Method: natural Like Explorer

Posted: 2023-05-07, 20:14 UTC
by Sir_SiLvA
petermad wrote: 2023-05-07, 18:21 UTC Here is the order in TC when sort order set to Unsorted (hence using the NTFS filesystem's order)
apple tv+.png
Apple.jpeg
Apple_TV_Plus_Logo.png
Apple_TV_Plus_Logo.svg
Download.jpg
Where do you see the option UNSORTED? I dont have that in my drop down menu in Configuration -> Options -> Display -> sort method?
petermad wrote: 2023-05-07, 18:21 UTC in Lister-view on the other hand the sequence the pictures are shown in when pressing N, is like it is shown in the file panel.
which lister addon do you use for pictures? imagine for example (where N doesnt work only Space) uses the same order as irfanview.
(Edith: and the same order as double and one commander use)
petermad wrote: 2023-05-07, 18:21 UTC "Natural sorting: alphabetical and numbers" is supposed to be the same used by windows, but then not apparent because of what Ghisler writes:
Ghisler wrote:The Explorer seems to sort by the combined name+extension string directly.
As I wrote in my start post it was the same as windows till 6.58 and thats why I ask for an option "Natural sorting: like Explorer"
cause thats the way double commander/irfan view/etc show the file order.

@Ghisler: yes explorer sort filenames including the extension.

Re: Wish: Sort Method: natural Like Explorer

Posted: 2023-05-08, 07:59 UTC
by petermad
Where do you see the option UNSORTED? I dont have that in my drop down menu in Configuration -> Options -> Display -> sort method?
Ctrl+F7 or menu: Show -> Unsorted.
which lister addon do you use for pictures? imagine for example (where N doesnt work only Space) uses the same order as irfanview.
(Edith: and the same order as double and one commander use)
By me N works in Imagine, but not alt+rightarrow

Re: Wish: Sort Method: natural Like Explorer

Posted: 2023-05-12, 19:10 UTC
by Sir_SiLvA
@Ghisler: so is that a thing that wont be added?

So far I tested Double Commander, Speed Commander, Free Commander and (*shiver*) Directory Opus:
The first 3 show the files in Explorer order and only DO displays them in TC order (that alone should be a reason to add it :P)