| Libfm Reference Manual | ||||
|---|---|---|---|---|
| Top | Description | ||||
#define FM_THUMBNAILER (p) FmThumbnailer; void fm_thumbnailer_check_update (); char * fm_thumbnailer_command_for_uri (FmThumbnailer *thumbnailer,const char *uri,const char *output_file,guint size); void fm_thumbnailer_free (FmThumbnailer *thumbnailer); gboolean fm_thumbnailer_launch_for_uri (FmThumbnailer *thumbnailer,const char *uri,const char *output_file,guint size); GPid fm_thumbnailer_launch_for_uri_async (FmThumbnailer *thumbnailer,const char *uri,const char *output_file,guint size,GError **error); FmThumbnailer * fm_thumbnailer_new_from_keyfile (const char *id,GKeyFile *kf); FmThumbnailer * fm_thumbnailer_ref (FmThumbnailer *thumbnailer); void fm_thumbnailer_unref (FmThumbnailer *thumbnailer);
void fm_thumbnailer_check_update ();
Checks new thumbnailers and reloads if needed.
Since 1.0.0
char * fm_thumbnailer_command_for_uri (FmThumbnailer *thumbnailer,const char *uri,const char *output_file,guint size);
Tries to generate command line that can be used to generate a thumbnail
for given uri. Returned string is allocated and should be freed with
g_free() after usage.
|
thumbnailer descriptor |
|
a file to create thumbnail for |
|
the target file name |
|
size of thumbnail to generate |
Returns : |
a newly allocated string or NULL. [transfer full]
|
Since 1.2.0
void fm_thumbnailer_free (FmThumbnailer *thumbnailer);
fm_thumbnailer_free has been deprecated since version 1.2.0 and should not be used in newly-written code. Use fm_thumbnailer_unref() instead.
Frees thumbnailer object.
|
thumbnailer descriptor |
Since 1.0.0
gboolean fm_thumbnailer_launch_for_uri (FmThumbnailer *thumbnailer,const char *uri,const char *output_file,guint size);
fm_thumbnailer_launch_for_uri has been deprecated since version 1.2.0 and should not be used in newly-written code. Use fm_thumbnailer_launch_for_uri_async() instead.
Tries to generate new thumbnail for given uri.
|
thumbnailer descriptor |
|
a file to create thumbnail for |
|
the target file name |
|
size of thumbnail to generate |
Returns : |
TRUE in case of success. |
Since 1.0.0
GPid fm_thumbnailer_launch_for_uri_async (FmThumbnailer *thumbnailer,const char *uri,const char *output_file,guint size,GError **error);
Tries to spawn thumbnailer to generate new thumbnail for given uri.
|
thumbnailer descriptor |
|
a file to create thumbnail for |
|
the target file name |
|
size of thumbnail to generate |
|
location to save error. [allow-none][out] |
Returns : |
thumbnailer process ID or -1 in case of failure. |
Since 1.2.0
FmThumbnailer * fm_thumbnailer_new_from_keyfile (const char *id,GKeyFile *kf);
Creates new thumbnailer object.
|
desktop entry Id |
|
content of id
|
Returns : |
a new FmThumbnailer or NULL in case of error. [transfer full]
|
Since 1.0.0
FmThumbnailer * fm_thumbnailer_ref (FmThumbnailer *thumbnailer);
Increases reference count for thumbnailer object.
|
thumbnailer descriptor |
Returns : |
thumbnailer. |
Since 1.2.0
void fm_thumbnailer_unref (FmThumbnailer *thumbnailer);
Decreases reference count for thumbnailer object. When last reference
is dropped, allocated resources will be freed and thumbnailer becomes
invalid.
|
thumbnailer descriptor |
Since 1.2.0