<html>
<body>
<div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
<table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 solid;">
<tr>
<td>
This is an automatically generated e-mail. To reply, visit:
<a href="http://git.reviewboard.kde.org/r/105371/">http://git.reviewboard.kde.org/r/105371/</a>
</td>
</tr>
</table>
<br />
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<p style="margin-top: 0;">On July 11th, 2012, 12:36 p.m., <b>David Faure</b> wrote:</p>
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">KMimeTypeTrader::query honours the sorting, so InitialPreference=10 should have been enough in your thumbnailer.
preferredService() basically calls first() ;)
Patch is OK however.</pre>
</blockquote>
</blockquote>
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">IIRC I tried InitialPreference=10 but to no effect (but then we all fail sometimes).
But I did not inspect preferredService(), just looked at the name it seems :)
So the sorting by preference is already done when creating the cache I learn by your comment?
For KDELIBS NG I wonder if a thumbnail control should be added to the File Association settings, so the user can control which plugin stamps the thumbnail, if any. At least Calligra 2.6 will signal support for quite a lot of file types (due to the filter system there can be many), so overlapping of thumbnailers might happen more often.</pre>
<br />
<p>- Friedrich W. H.</p>
<br />
<p>On June 28th, 2012, 5:39 a.m., Friedrich W. H. Kossebau wrote:</p>
<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('http://git.reviewboard.kde.org/media/rb/images/review_request_box_top_bg.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
<tr>
<td>
<div>Review request for KDE Runtime.</div>
<div>By Friedrich W. H. Kossebau.</div>
<p style="color: grey;"><i>Updated June 28, 2012, 5:39 a.m.</i></p>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
<tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">The declared-as-supported mimetypes of the image thumbnailer are quite broad, assuming a lot of QImageIOPlugin existing and installed. But at least for x-fig and wmf there are no such plugins known, by what I can tell. So the claim of support is wrong.
Worse: There is no safe way to install an own, better thumbnailer, that one would be only chosen by pure luck. Reason is that the thumbnail creation invoking code just greps the first in the list of found thumbnail plugins, see the code in kde-runtime/kioslave/thumbnail/thumbnail.cpp:
QString ThumbnailProtocol::pluginForMimeType(const QString& mimeType) {
KService::List offers = KMimeTypeTrader::self()->query( mimeType, QLatin1String("ThumbCreator"));
if (!offers.isEmpty()) {
KService::Ptr serv;
serv = offers.first();
return serv->library();
}
[...]
E.g. trying to install an own xfig thumbnailer failed for me.
While changing the above code to use KMimeTypeTrader::preferredService(...) surely might be also good to do, I have no idea about the impact.
For now I just would like to have those two wrong claims removed.
Okay to backport to 4.9 (and 4.8)?</pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">
<li>kioslave/thumbnail/imagethumbnail.desktop <span style="color: grey">(53c9a33)</span></li>
</ul>
<p><a href="http://git.reviewboard.kde.org/r/105371/diff/" style="margin-left: 3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>