Sorting by label or tag doesn't work when TagSortKeepTagsOnTop is disabled

Things you’d like to miss in the future...
Forum rules
:warnred20: :warnred20: :warnred20: :warnred20: :warnred20: READ THIS AND DO IT!!! :warnred20: :warnred20: :warnred20: :warnred20: :warnred20:

:info: Please include the following information:
1) Your XYplorer Version (e.g., v28.00.0801)
2) Your Windows Version (e.g., Win 11)
3) Your Screen Scaling Percentage (e.g., 125%).

:info: We strongly recommend adding your Windows Version and Screen Scaling Percentage to the Location field in your Profile or to your Signature. That way, you only have to type them once, and we won't have to search for that vital information.

:info: When attaching an Image, please use the Attachment tab at the bottom of your post and click "Add files".

:warnred20: :warnred20: :warnred20: :warnred20: :warnred20: READ THIS AND DO IT!!! :warnred20: :warnred20: :warnred20: :warnred20: :warnred20:
Post Reply
daniel_m
Posts: 218
Joined: 11 Apr 2010 11:47
Location: Windows 10 Pro 22H2, scaling 100%

Sorting by label or tag doesn't work when TagSortKeepTagsOnTop is disabled

Post by daniel_m »

From the help file, I gather that TagSortKeepTagsOnTop sorts labelled/tagged files on top of the list when I click on the label or tag column header. Descending and ascending sorting reverses the order of the labelled/tagged items, but they remain on top of the file list as a block. This does work very well.

When TagSortKeepTagsOnTop is disabled, sorting by label/tag seems random. I would expect labelled/tagged files to be on top or bottom of the list, depending on descending and ascending sorting, but still in a block separate from unlabelled/untagged files.

To replicate:
Open a fresh instance of XYplorer and add a Label column. Enable "Show implicit secondary sort order arrow" for clarity (doesn't affect the result). Make a folder and 7 files "a.file" to "g.file". Apply Label "1" to files "a" and "b", Label "2" to file "c", and Label "3" to file "d".
Click onto the Name header to sort by Name in ascending order. Then, click on the Label header to sort by Label first, and Name second, both ascending.

(A) What I'd expect with TagSortKeepTagsOnTop disabled:

Code: Select all

[sort by Label, ascending]		[sort by Label, descending]
Label	Name				Label	Name
1	a.file					e.file
1	b.file					f.file
2	c.file					g.file
3	d.file				3	d.file
	e.file				2	c.file
	f.file				1	b.file
	g.file				1	a.file
(B) What I get:

Code: Select all

[sort by Label, ascending]		[sort by Label, descending]
Label	Name				Label	Name
	f.file					e.file
1	a.file				3	d.file
1	b.file				2	c.file
	g.file					g.file
2	c.file				1	b.file
3	d.file				1	a.file
	e.file					f.file
It gets more complicated. I get the above result when the list was initially sorted ascending by Name, as described above, but also initially by Ext or Type. When the list was initially sorted ascending by Size, Modified, or Created, the Label sorting works as expected (A).
Oh, and we are not done yet 😁
I get the inverse result when the list was initially sorted in descending order. Then, initially sorted by Name, Ext, or Type result in the correct Label sorting (A), while Size, Modified, or Created, result in the wrong Label sorting (B).
It gets weirder when the empty files get filled with text, resulting in different file sizes. I guess messing with the other file properties will also yield results different from (B), but still incorrect.

(This was tested on version 28.20.0501 x64)
XYplorer x64 (often the latest beta), Windows 10 Pro 22H2, 3840x2160 scaling 100%

admin
Site Admin
Posts: 66075
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Sorting by label or tag doesn't work when TagSortKeepTagsOnTop is disabled

Post by admin »

Works fine here. Could you show a screenshot of the situation, with all columns in sight?

I see it now in x64. (First I only tested x32 because I thought they behaved the same).

admin
Site Admin
Posts: 66075
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Sorting by label or tag doesn't work when TagSortKeepTagsOnTop is disabled

Post by admin »

Fixed in next beta. :tup:

daniel_m
Posts: 218
Joined: 11 Apr 2010 11:47
Location: Windows 10 Pro 22H2, scaling 100%

Re: Sorting by label or tag doesn't work when TagSortKeepTagsOnTop is disabled

Post by daniel_m »

Great, thanks!

I hope fixing bugs didn't spoil your weekend. I assume you did it because you wanted to but would still like to let you know that there was no expectation of you reading the bug report within a day, and less so on a weekend 🙂
XYplorer x64 (often the latest beta), Windows 10 Pro 22H2, 3840x2160 scaling 100%

admin
Site Admin
Posts: 66075
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Sorting by label or tag doesn't work when TagSortKeepTagsOnTop is disabled

Post by admin »

No worries, bug fixing is fun! :beer:

Post Reply