1.9.10 - The problem with sorting files

*** Please report new bugs here! ***

Moderators: xnview, Dreamer

adrem85
Posts: 94
Joined: Mon Feb 10, 2020 12:47 pm

1.9.10 - The problem with sorting files

Post by adrem85 »

I noticed that the program periodically "loses track" of the file sorting assigned via the filter on the toolbar (the "Sort by" button). Apparently, the parameter values assigned through this filter are not "hard" (constant) and are not used by default in all cases.

Is it a bug, or is it a feature of the program? But if the program decides for the user what and how to sort, it's strange and inconvenient. The user is forced to go into the program and reset the sorting parameters they need. This is a waste of time.

At first, I thought that, as in other image viewing programs, the sorting parameters would be found in Settings. But alas, I did not find such a parameter in XnViewMP. Although, maybe I didn't look hard enough and the sorting parameters are in Settings after all? There is a File List - Sorting section, but it lacks the most important setting - sorting the files themselves.

If there is no such parameter in Settings, then I would like to request that a parameter be added for "hard" (unchangeable) fixing of the default sorting value in the program Settings, as is done in other viewers.
User avatar
user0
XnThusiast
Posts: 2842
Joined: Sat May 09, 2015 9:37 am

Re: 1.9.10 - The problem with sorting files

Post by user0 »

I have no such issue, Sort by is persistent

possible causes
- enabled sessions
- old .ini w/ conflicting settings
- user has no write access to .ini location
adrem85
Posts: 94
Joined: Mon Feb 10, 2020 12:47 pm

Re: 1.9.10 - The problem with sorting files

Post by adrem85 »

user0 wrote: Fri Feb 06, 2026 2:09 pm- enabled sessions
I do not even know what it is... It doesn't seem to be in the Settings.
user0 wrote: Fri Feb 06, 2026 2:09 pm- old .ini w/ conflicting settings
I've only had one portable version installed for a long time.
user0 wrote: Fri Feb 06, 2026 2:09 pm- user has no write access to .ini location
There is write access to the INI, since changes in other settings are saved normally, only the sorting settings are "reset" (spontaneously changed).
user0 wrote: Fri Feb 06, 2026 2:09 pm Sort by is persistent
I also find that sorting settings are not always reset. In other words, it's a "floating bug". I'll try to catch this moment and record the sequence of actions so that they can be reproduced.
User avatar
user0
XnThusiast
Posts: 2842
Joined: Sat May 09, 2015 9:37 am

Re: 1.9.10 - The problem with sorting files

Post by user0 »

adrem85 wrote: Fri Feb 06, 2026 5:29 pm
user0 wrote: Fri Feb 06, 2026 2:09 pm- enabled sessions
I do not even know what it is... It doesn't seem to be in the Settings.
set 'Save session on program exit' to Never in Settings>General
adrem85
Posts: 94
Joined: Mon Feb 10, 2020 12:47 pm

Re: 1.9.10 - The problem with sorting files

Post by adrem85 »

user0 wrote: Fri Feb 06, 2026 5:31 pm set 'Save session on program exit' to Never in Settings>General
I already have the Never parameter set there.
alee001
Posts: 276
Joined: Sun Sep 04, 2022 4:43 am

Re: 1.9.10 - The problem with sorting files

Post by alee001 »

Just passing by…

The sorting method and settings themselves are not problematic and will not change without reason.

However, I found that when you copy or drag a batch of already sorted files to (from File Explorer) MP, the newly added files are not displayed in MP's sorting format. You need to press F5 to update the sorting for it to work correctly. This might be a bug or a defect.
adrem85
Posts: 94
Joined: Mon Feb 10, 2020 12:47 pm

Re: 1.9.10 - The problem with sorting files

Post by adrem85 »

alee001 wrote: Sat Feb 07, 2026 6:36 am However, I found that when you copy or drag a batch of already sorted files to (from File Explorer) MP, the newly added files are not displayed in MP's sorting format. You need to press F5 to update the sorting for it to work correctly. This might be a bug or a defect.
I would like to reproduce your situation, but I never do that and therefore don't understand how to do it. Could you send a video or GIF showing how you do it? Or at least describe in more detail what exactly you are doing? At the same time, your video or GIF would serve as evidence of the sorting problem.
alee001
Posts: 276
Joined: Sun Sep 04, 2022 4:43 am

Re: 1.9.10 - The problem with sorting files

Post by alee001 »

adrem85 wrote: Sat Feb 07, 2026 9:06 am
alee001 wrote: Sat Feb 07, 2026 6:36 am However, I found that when you copy or drag a batch of already sorted files to (from File Explorer) MP, the newly added files are not displayed in MP's sorting format. You need to press F5 to update the sorting for it to work correctly. This might be a bug or a defect.
I would like to reproduce your situation, but I never do that and therefore don't understand how to do it. Could you send a video or GIF showing how you do it? Or at least describe in more detail what exactly you are doing? At the same time, your video or GIF would serve as evidence of the sorting problem.
Here's a simple example you can replicate:

1) Place a series of images in a folder in MP, named n01.jpg, n02.jpg, ... n05.jpg (set this order).

2) Place a series of images in another folder in Windows Explorer, named a01.jpg, a02.jpg, ... a05.jpg (set this order).

3) Drag and drop a01.jpg, a02.jpg, ... a05.jpg into the MP's folder.

4) You'll find that a01.jpg, a02.jpg, ... a05.jpg appear after n01.jpg, n02.jpg, ... n05.jpg.

5) You need to press F5 to update the order.
adrem85
Posts: 94
Joined: Mon Feb 10, 2020 12:47 pm

Re: 1.9.10 - The problem with sorting files

Post by adrem85 »

alee001 wrote: Sat Feb 07, 2026 10:16 am 4) You'll find that a01.jpg, a02.jpg, ... a05.jpg appear after n01.jpg, n02.jpg, ... n05.jpg.
Thanks for the clarification, I did as you described. But I have no problems with sorting in this case. Files a.jpg when added, the programs are positioned in the browser as they should be, in front of n.jpg. Moreover, even if you enable the File list - Sorting parameter - New files are added at the end of the list - you can still visually see that they are first added to the end of the list, and then instantly sorted according to the sorting value set in the browser - that is, by Name/Ascendidg, from a to n. Most likely, you just have some problems updating the page in the program.
alee001
Posts: 276
Joined: Sun Sep 04, 2022 4:43 am

Re: 1.9.10 - The problem with sorting files

Post by alee001 »

adrem85 wrote: Sat Feb 07, 2026 10:39 am
alee001 wrote: Sat Feb 07, 2026 10:16 am 4) You'll find that a01.jpg, a02.jpg, ... a05.jpg appear after n01.jpg, n02.jpg, ... n05.jpg.
Thanks for the clarification, I did as you described. But I have no problems with sorting in this case. Files a.jpg when added, the programs are positioned in the browser as they should be, in front of n.jpg. Moreover, even if you enable the File list - Sorting parameter - New files are added at the end of the list - you can still visually see that they are first added to the end of the list, and then instantly sorted according to the sorting value set in the browser - that is, by Name/Ascendidg, from a to n. Most likely, you just have some problems updating the page in the program.
I found that many of MP's actions failed to update in a timely manner, causing bugs. Perhaps these are defects, but they should not appear on different platforms (I use Win11).
adrem85
Posts: 94
Joined: Mon Feb 10, 2020 12:47 pm

Re: 1.9.10 - The problem with sorting files

Post by adrem85 »

I discovered some rather illogical behavior in the program when sorting files in the browser under certain conditions.

Go to any directory with several images. Sort them by Name. Then drag the last thumbnail to the very beginning, to the first place. Now, if you look at the sorting, it will no longer be Name, but Custom. And that's probably logical.

But if you exit this directory without changing the sorting (i.e., it remains Custom), then all other directories will also be sorted by... Custom. And this is not logical at all, because Custom sorting is always individual for each directory.

It's hard for me to imagine users who sort all their directories manually. After all, this sorting is only needed once, and then, when you exit the directory, the sorting should change back to the default sorting. But this doesn't happen, and the user has to spend time manually returning the sorting to its original state for other directories.
User avatar
xnview
Author of XnView
Posts: 47518
Joined: Mon Oct 13, 2003 7:31 am
Location: France

Re: 1.9.10 - The problem with sorting files

Post by xnview »

'Sort' is global not by folder
Pierre.
jkm
Posts: 395
Joined: Sat May 11, 2024 12:43 am

Re: 1.9.10 - The problem with sorting files

Post by jkm »

adrem85 wrote: Fri Feb 13, 2026 2:06 pm But if you exit this directory without changing the sorting (i.e., it remains Custom), then all other directories will also be sorted by... Custom. And this is not logical at all, because Custom sorting is always individual for each directory.

It's hard for me to imagine users who sort all their directories manually. After all, this sorting is only needed once, and then, when you exit the directory, the sorting should change back to the default sorting. But this doesn't happen, and the user has to spend time manually returning the sorting to its original state for other directories.
The logical part is that the sort mode selection does not change unless you change it. So the sorting mode is “persistent” or “global”. The app does not remember “descending by name” in one folder and “descending by size” in another.

You set a sorting mode for the app, and every folder you browse to is sorted in that mode.

Makes perfect sense.

I agree that I certainly wouldn’t want to sort all my folders manually either, but different people have different sensibilities.
adrem85
Posts: 94
Joined: Mon Feb 10, 2020 12:47 pm

Re: 1.9.10 - The problem with sorting files

Post by adrem85 »

xnview wrote: Fri Feb 13, 2026 2:22 pm 'Sort' is global not by folder
I know this. But I don't understand why this applies to Custom sorting. Are there any users who use Custom sorting globally, in all folders? In my opinion, it would be logical to automatically change the sorting to the previous one (any standard one) after exiting the such folder. Otherwise, it just leads to unnecessary user actions.

As a compromise, you can make the "Remember / Leave Custom sorting" option for those users who use such sorting always and in all folders. But I very much doubt that such users exist.
User avatar
xnview
Author of XnView
Posts: 47518
Joined: Mon Oct 13, 2003 7:31 am
Location: France

Re: 1.9.10 - The problem with sorting files

Post by xnview »

adrem85 wrote: Fri Feb 13, 2026 6:36 pm As a compromise, you can make the "Remember / Leave Custom sorting" option for those users who use such sorting always and in all folders. But I very much doubt that such users exist.
So when you browse in a folder with .XnViewSort, sort is automatically 'Custom', and in other folder users sort?
If you browse a folder with .XnViewSort, and user choose another sort, .XnViewSort should be removed?
Pierre.