*** While viewing thumbnails of images in a folder, I have selected to sort items by Name in Ascending order. If I have the following 3 files: "Test.jpg", "Test_a.jpg", and "Test_b.jpg", they sort in the following way within the album/folder in Windows, the Windows Command Line, and I believe Linux: Test.jpg Test_a.jpg Test_b.jpg However, in the Thumbnail viewer of the album/folder containing these 3 images, Digikam displays them in the following order: Test_a.jpg Test_b.jpg Test.jpg when sorted by Name in Ascending order. I have not been able to change the settings such that the files would sort into the same order that the operating systems display them (and the order I would like to run them through renaming/Queque manager). As a separate test, I opened the folder in another tool, XNView MP and it sorted in the same order that the operating systems display the images which is what I expected Digikam to also do. *** SUMMARY Sort order of images by Name in Ascending or Descending order - logic STEPS TO REPRODUCE 1. Open an Album / folder and view Thumbnails 2. Select Sort by Name in Ascending order OBSERVED RESULT Test_a.jpg Test_b.jpg Test.jpg EXPECTED RESULT Test.jpg Test_a.jpg Test_b.jpg SOFTWARE/OS VERSIONS Windows: 11
Switch the icon-view to the table-view in digiKam and look if the problem still reproducible... https://docs.digikam.org/en/main_window/image_view.html#general-information
We just had this yesterday, read this bug for the solution: Bug 507713 Maik
I switched to Table View and the images now sort in the following order (which appear to be in descending order): Test_b.jpg Test_a.jpg Test.jpg when I have selected "By Name" and "Ascending Order" under the View sorting order selections. So, it looks like the sort is different from Thumbnail to Table view and neither match to the pre-selection of By Name, Ascending Order
As Maik said, look at https://bugs.kde.org/show_bug.cgi?id=507713
However, switching to "normal" string comparison loses the numeric sorting. For years, Dolphin sorted in the same way as digiKam. Now, it doesn't. I found the corresponding commit; the cause is apparently the filename extension in QCollator. I'll take a closer look. Maik
Git commit 8763113ff983fc9ac85f53310bdb78bf3d7f55a8 by Maik Qualmann. Committed on 01/08/2025 at 19:28. Pushed by mqualmann into branch 'master'. fix natural item sorting with QCollator Related: bug 507713 FIXED-IN: 8.8.0 M +2 -2 NEWS M +25 -9 core/libs/database/models/itemsortcollator.cpp https://invent.kde.org/graphics/digikam/-/commit/8763113ff983fc9ac85f53310bdb78bf3d7f55a8