Bug 388303

Summary: Folder thumbnails inconsistently following settings of enabled file thumbnailers
Product: [Applications] dolphin Reporter: Friedrich W. H. Kossebau <kossebau>
Component: generalAssignee: Dolphin Bug Assignee <dolphin-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: elvis.angelaccio, nate
Priority: NOR    
Version: 17.12.0   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:

Description Friedrich W. H. Kossebau 2017-12-28 18:52:52 UTC
Dolphin (or KIO?) now shows more thumbnails of the files contained in a folder on the icon for that folder. Which is pretty nice, thanks for implementing that.

Just, it seems the settings which file types should be thumbnailed are not following the same logic as for the thumbnails shown for the files themselves.

With these settings
* text thumbnailer: ON
* gettext/po thumbnailer: OFF
for a folder containing *.po files the folder icon gets thumbnails added which are done using the gettext thumbnailer (pie chart of translation status), while the thumbnails for the *.po files themselves are done using the text thumbnailer.

This inconsistency is surprising.
Comment 1 Elvis Angelaccio 2017-12-31 09:36:10 UTC
This should be handled by ThumbnailProtocol::thumbForDirectory() from kio-extras. Could be a regression in 17.12 after porting to KIO::PreviewJob::defaultPlugins(). Nate?
Comment 2 Nate Graham 2018-01-02 17:47:45 UTC
I'll investigate. Where can I get the gettext/po thumbnailer from?
Comment 3 Friedrich W. H. Kossebau 2018-01-02 18:00:25 UTC
You find the gettext thumbnailer in kdesdk-thumbnailers (last one which survived there).
Comment 4 Nate Graham 2018-01-02 18:04:25 UTC
Did you not have folder thumbnails/previews on before? I will do a full investigation, but offhand, I suspect this is a case of exposing a pre-existing bug when we turned thumbnails on by default.
Comment 5 Friedrich W. H. Kossebau 2018-01-02 18:22:49 UTC
Thanks for investigating.

Please also try enabling/disabling the Gettext thumbnailer & Plaintext thumbnailer and see how this only has an effect for the file preview, but not the folder preview.

Tested for new files & folder, so nothing should be in any cache (.cache/thumbnails/ also removed before).

Gettext thumbnailer:   ON
Plaintext thumbnailer: ON
->
po file:              pie chart
folder with po files: pie chart

Gettext thumbnailer:   OFF
Plaintext thumbnailer: ON
->
po file:              plaintext preview
folder with po files: pie chart

Gettext thumbnailer:   OFF
Plaintext thumbnailer: OFF
->
po file:              no preview
folder with po files: pie chart
Comment 6 Kai Uwe Broulik 2018-09-18 08:37:59 UTC
Git commit b582cd477f657e859818b2deff130ad186a6a704 by Kai Uwe Broulik.
Committed on 18/09/2018 at 08:37.
Pushed by broulik into branch 'master'.

[PreviewJob] Send enabled thumbnail plugins to the thumbnail slave

This way the thumbnailer can use the same enabled plugin configuration as the calling application

Differential Revision: https://phabricator.kde.org/D15096

M  +1    -0    src/widgets/previewjob.cpp

https://commits.kde.org/kio/b582cd477f657e859818b2deff130ad186a6a704
Comment 7 Kai Uwe Broulik 2018-09-18 08:41:58 UTC
Git commit ed68ea157d59f105a50888642f98241e639a9fdc by Kai Uwe Broulik.
Committed on 18/09/2018 at 08:40.
Pushed by broulik into branch 'master'.

[Thumbnailer] Use enabled plugins passed in as metadata

The thumbnailer lives in a separate application, so it will read the enabled plugins from a different configuration than the
calling application (e.g. dolphinrc).
This leads to folder thumbnails following the default settings instead of user-configured settings, causing disabled plugins
to be used and blacklisted thumbnails never being used even if enabled by the user.

Differential Revision: https://phabricator.kde.org/D15097

M  +9    -5    thumbnail/thumbnail.cpp

https://commits.kde.org/kio-extras/ed68ea157d59f105a50888642f98241e639a9fdc