SortDirExt kinda broken in v9 or..?

Here you can propose new features, make suggestions etc.

Moderators: white, Hacker, petermad, Stefan2

Post Reply
Partial
Junior Member
Junior Member
Posts: 25
Joined: 2009-09-08, 07:27 UTC

SortDirExt kinda broken in v9 or..?

Post by *Partial »

nice option SortDirExt=1 in TC was meant purely to sort directories by extension. So that clicking on Ext tab would sort all dirs according to extension (yeah, I'm using extensions for dirs to sort things out). It didn't influence normal sorting order by name.

However in TC v9 if SortDirExt=1 is set in windcmd.ini it starts to influence normal sorting order by Name.

E.g. directories "v6.4" and "v6.3 X.5" will be sorted like this

v6.4
v6.3 X.5

or did I miss some "hidden" option like "natural sorting order" or something else :?:
User avatar
Hacker
Moderator
Moderator
Posts: 13052
Joined: 2003-02-06, 14:56 UTC
Location: Bratislava, Slovakia

Post by *Hacker »

Partial,
What do you see as the problem? "4" is sorted before "5" as expected.
Also, any reason why you posted this in the Suggestions forum?

Roman
Mal angenommen, du drückst Strg+F, wählst die FTP-Verbindung (mit gespeichertem Passwort), klickst aber nicht auf Verbinden, sondern fällst tot um.
User avatar
Dalai
Power Member
Power Member
Posts: 9364
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Post by *Dalai »

2Partial
The extension is everything after the last dot. In your case it's "4" and "5", so if TC lists them in this order, I don't see why this would be wrong.

Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64

Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
Partial
Junior Member
Junior Member
Posts: 25
Joined: 2009-09-08, 07:27 UTC

Post by *Partial »

Hacker wrote:Partial,
Also, any reason why you posted this in the Suggestions forum?
Roman
Uhm... I'm not sure it's a bug. May be some kind of transition to "natural sort order" or something else. Welcome to place it anywhere or suggest where should it go - I'll move or re-post.
Partial
Junior Member
Junior Member
Posts: 25
Joined: 2009-09-08, 07:27 UTC

Post by *Partial »

Guys, please check my post - I said this behaviour happens when dirs are sorted by NAME.

Should happen only when sorted by EXTENSION.

I compared sorting behaviour with SortDirExt=1 with TC versions 8 and 9 - and in v9 it seems to be "broken" or just different.
User avatar
Dalai
Power Member
Power Member
Posts: 9364
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Post by *Dalai »

I can confirm the different behavior in TC8 and TC9. However, I don't know which of them is behaving correctly. And, it only behaves differently if SortDirsByName=0 at the same time.

Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64

Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
Partial
Junior Member
Junior Member
Posts: 25
Joined: 2009-09-08, 07:27 UTC

Post by *Partial »

Thanks for checking, Dalai

v8
[img]https://image.ibb.co/bC86Rb/v8.png[/img]

v9
[img]https://image.ibb.co/icAxXG/v9.png[/img]

I have SortDirsByName=0 in *.ini but I think it's default? Never changed this flag and not sure what it does.

From my experience behaviour in v8 was "better", but it's subjective opinion. I just noticed that now I can't find dirs in sorting order I've accustomed to.
User avatar
Dalai
Power Member
Power Member
Posts: 9364
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Post by *Dalai »

Partial wrote:I have SortDirsByName=0 in *.ini but I think it's default? Never changed this flag and not sure what it does.
No, 1 is default as TC help says:

Code: Select all

SortDirsByName=1 Always sort directories by name
This option can also be toggled in Configuration > Options > Display > Sorting directories.

I guess we have to wait for Ghisler to say something about this, whether the change was intentional or not.

Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64

Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
Partial
Junior Member
Junior Member
Posts: 25
Joined: 2009-09-08, 07:27 UTC

Post by *Partial »

Oh, I got it...

So I can get old behaviour but for account of not being able to sort dirs by date/time.

Thanks for tip, but I hope this will be "fixed" and both options will be available.

May be it has something to do with which dot is used as "separator" between name and extension of dir - first dot or last dot... Just guessing. But old behavior was "better" so even if this change is intentional may be it could be made optional.
User avatar
petermad
Power Member
Power Member
Posts: 14739
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

2Partial
I can confirm that TC 8.52a and TC 9.12 sorts the two dir names differently when:
[Configuration]
SortDirExt=1
SortDirsByName=0
SortUpper=3 (Natural sorting: alphabetical and numbers)

[left] or [right]
sortorder=0 (Ascending by Name)

I think the way TC 9.12 does it is the right way - if dirs are considered to have extensions (SortDirExt=1), the NAME of the two dirs are:
v6
v6.3 X

So the shortest one has to be placed first - as TC 9.12 does it.

Windows Explorer sorts them opposite though, and so do the NTFS file system (TC's sorting set to Unsorted). Console DIR command also sorts them opposite, but DIR /OG (group dirs) sorts like TC 9.12 does, but then again DIR /OGN sorts like Explorer.

If dirs are NOT considered to have extensions (SortDirExt=0), then the NAMES are:
v6.3 X.5
v6.4

and should be sorted by name in this way - also as TC 9.12 does it

I cannot find anything in history.txt that explicitly explains the difference between TC 9.12 and TC 8.52a
Last edited by petermad on 2018-01-08, 07:00 UTC, edited 1 time in total.
License #524 (1994)
Danish Total Commander Translator
TC 11.03 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1371a
TC 3.50b4 on Android 6 & 13
Try: TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Partial
Junior Member
Junior Member
Posts: 25
Joined: 2009-09-08, 07:27 UTC

Post by *Partial »

I can only speak from the point of view of a person who uses "extensions" of folders/directories (which is very substandard "lifehack" irrelevant to Windows Explorer and NFTS) - that previous sorting in 8.52a was more natural and worked better.

(Probably) no OSes or file systems are using folder "extension" anyway so we are completely inside of TC universe and habits of its users here.

I just found that FAR users had same discussion and without any conclusive decision. They just left it "as is" and it's different than in TC.

Since this "old" sorting type has been in TC for decades (probably since this feature introduced), changing it seems more "breaking" than "fixing".
Post Reply