After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 711604 - Add documentation about thumbnailers and thumbnailer files
Add documentation about thumbnailers and thumbnailer files
Status: RESOLVED FIXED
Product: gnome-desktop
Classification: Core
Component: docs
git master
Other All
: Normal normal
: ---
Assigned To: Desktop Maintainers
Desktop Maintainers
Depends on:
Blocks:
 
 
Reported: 2013-11-07 12:01 UTC by Philip Withnall
Modified: 2013-12-16 08:50 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
thumbnailer: Add documentation on thumbnailers and .thumbnailer files (6.07 KB, patch)
2013-11-07 12:02 UTC, Philip Withnall
reviewed Details | Review
thumbnailer: Add documentation on thumbnailers and .thumbnailer files (6.31 KB, patch)
2013-12-14 21:12 UTC, Philip Withnall
committed Details | Review

Description Philip Withnall 2013-11-07 12:01:39 UTC
Patch coming which adapts my recent blog entry (http://tecnocode.co.uk/2013/10/21/writing-a-gnome-thumbnailer/) to fit in the libgnome-desktop reference manual so it’s easier to find and use offline.
Comment 1 Philip Withnall 2013-11-07 12:02:45 UTC
Created attachment 259175 [details] [review]
thumbnailer: Add documentation on thumbnailers and .thumbnailer files
Comment 2 Bastien Nocera 2013-12-13 17:46:32 UTC
Review of attachment 259175 [details] [review]:

There's no mention of the factory doing fallback for image types handled by GdkPixbuf.

Rest looks good, very useful!

::: libgnome-desktop/gnome-desktop-thumbnail.c
@@ +41,3 @@
+ *
+ * To generate a thumbnail, an appropriate thumbnailer program is selected then
+ * executed, passing it the path of the file to thumbnail, plus a path to write

path or URI?

@@ +70,3 @@
+ * <replaceable>%u</replaceable> is the URI of the file being thumbnailed;
+ * <replaceable>%i</replaceable> is its filename; <replaceable>%o</replaceable>
+ * is the filename of the image file to be written to;

Watch out for filename vs. file path. IMO, a filename should only refer to the filename without any path components.

@@ +71,3 @@
+ * <replaceable>%i</replaceable> is its filename; <replaceable>%o</replaceable>
+ * is the filename of the image file to be written to;
+ * <replaceable>%s</replaceable> is the maximum desired size of the thumbnail

Explain "size". It's the maximum width and height.
Comment 3 Philip Withnall 2013-12-14 21:12:54 UTC
Created attachment 264199 [details] [review]
thumbnailer: Add documentation on thumbnailers and .thumbnailer files
Comment 4 Bastien Nocera 2013-12-16 07:31:02 UTC
Review of attachment 264199 [details] [review]:

Looks good, thanks for the patch!
Comment 5 Philip Withnall 2013-12-16 08:50:17 UTC
Thanks for the detailed review. :-)

Attachment 264199 [details] pushed as f5561d7 - thumbnailer: Add documentation on thumbnailers and .thumbnailer files