Bug 276050 - Setting "string comparison type" is not evaluated in icon-view
Summary: Setting "string comparison type" is not evaluated in icon-view
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Albums-IconView (show other bugs)
Version: 3.5.0
Platform: Gentoo Packages Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-06-19 15:03 UTC by Peter Albrecht
Modified: 2017-07-29 05:27 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 5.0.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Albrecht 2011-06-19 15:03:36 UTC
Version:           2.0.0 (using Devel) 
OS:                Linux

Setting "settings" -> "configure digikam" -> "miscellaneous" -> "string comprison type" to "normal" is ignored in picture thumbnail-view.

I'm using digikam-2.0.0_beta6 with KDE-4.6.80-r1.

Reproducible: Always

Steps to Reproduce:
<maybe optional>
1. start digikam with new profile
     Setting:
       - RAW: open directly
       - Metadata: add info to file
       - preview: load reduced
       - rightclick-action: open a preview
       - use tooltips
</maybe optional>
2. add three photos:
       - 12img.jpg
       - 3img.jpg
       - 4img.jpg
3. add three albums:
       - 1a
       - 23b
       - 4c
4. verify "settings" -> "configure digikam" -> "miscellaneous" -> "string comprison type" to "natural" (should be default)
5. albums get sorted:
       - 1a
       - 4c
       - 23b
    => OK
6. pictures get sorted:
       - 3img.jpg
       - 4img.jpg
       - 12img.jpg
    => OK
7. change "settings" -> "configure digikam" -> "miscellaneous" -> "string comprison type" to "normal"
8.  albums get sorted:
       - 1a
       - 23b
       - 4c
    => OK


Actual Results:  
pictures get sorted:
       - 3img.jpg
       - 4img.jpg
       - 12img.jpg

Expected Results:  
pictures get sorted:
       - 12img.jpg
       - 3img.jpg
       - 4img.jpg


The following bugs seem to be the "historical background" of "natural sorting" and have been found during "is the bug already filed?":
 - Bug #158868
 - Bug #227905
Comment 1 Marcel Wiesweg 2011-06-19 15:50:53 UTC
As you observed corretly, natural ordering is always used. I didnt know there is something to adjust in the settings, and it seems to me like an option which we really dont need?
Comment 2 Peter Albrecht 2011-06-19 16:35:57 UTC
(In reply to comment #1)
> As you observed corretly, natural ordering is always used. I didnt know there
> is something to adjust in the settings, and it seems to me like an option which
> we really dont need?

The discussion in bug #227905 ended with the agreement to create this setting. So I would say: thumbnail view should respect this setting.

I personally don't like "natural string comparison". My picture numbers are prefixed with zeros (e.g. MyPic00051.jpg). But that is a personal opinion.
Comment 3 caulier.gilles 2011-12-14 09:17:23 UTC
Peter,

It still valid with digiKam 2.4 ?

Gilles Caulier
Comment 4 Peter Albrecht 2011-12-18 08:15:53 UTC
Hi Gilles,

yes, this bug is still valid with digiKam 2.4.1 and KDE 4.7.3.

Peter Albrecht
Comment 5 caulier.gilles 2013-11-25 17:10:19 UTC
Peter,

What's about this file with digiKam 3.5.0 ?

Gilles Caulier
Comment 6 Peter Albrecht 2013-11-25 18:26:11 UTC
Gilles,

at the moment, I still use digikam 3.1.0. But I plan to switch to 3.5.0 at mid december. 
Than I will test this bug again. 

Regards,
    Peter
Comment 7 caulier.gilles 2013-11-25 19:27:53 UTC
And with 3.1.0, problem still here ?

Gilles Caulier
Comment 8 Peter Albrecht 2013-12-13 13:22:45 UTC
Sorry, but bug is still present in digikam 3.5.0 and 4.10.5:

"string comprison type = normal" is ignored in picture thumbnail-view.

Behaviour still exactly as described in comment #0. (Step 1 can be omitted.)
Comment 9 caulier.gilles 2015-05-10 14:20:54 UTC
Maik,

Another entry where we can study a patch. This touch Image Lister if i remember.

Gilles
Comment 10 Maik Qualmann 2016-02-20 23:48:13 UTC
Git commit b8566dc4928aa686822c73e3d5fedac5c91a80f5 by Maik Qualmann.
Committed on 20/02/2016 at 23:47.
Pushed by mqualmann into branch 'master'.

fix string comparison type in the icon views
FIXED-IN: 5.0.0

M  +2    -1    NEWS
M  +2    -0    app/items/digikamimageview.cpp
M  +2    -1    libs/models/imagealbumfiltermodel.cpp
M  +7    -0    libs/models/imagefiltermodel.cpp
M  +1    -0    libs/models/imagefiltermodel.h
M  +10   -4    libs/models/imagesortsettings.cpp
M  +4    -2    libs/models/imagesortsettings.h
M  +2    -0    utilities/importui/main/importui.cpp
M  +11   -5    utilities/importui/models/camitemsortsettings.cpp
M  +4    -2    utilities/importui/models/camitemsortsettings.h
M  +7    -0    utilities/importui/models/importfiltermodel.cpp
M  +1    -0    utilities/importui/models/importfiltermodel.h

http://commits.kde.org/digikam/b8566dc4928aa686822c73e3d5fedac5c91a80f5