MATE Desktop Library Reference Manual: Miscellaneous Thumbnail Functions

## Miscellaneous Thumbnail Functions Miscellaneous Thumbnail Functions |

## Functions

gboolean | mate_desktop_thumbnail_has_uri ()
gboolean | mate_desktop_thumbnail_is_valid ()
char * | mate_desktop_thumbnail_md5 ()
char * | mate_desktop_thumbnail_path_for_uri ()
GdkPixbuf * | mate_desktop_thumbnail_scale_down_pixbuf ()

## Object Hierarchy

## Includes

    #include <mate-thumbnail.h>

## Description

## Functions

### mate_desktop_thumbnail_has_uri ()

    gboolean
    mate_desktop_thumbnail_has_uri (GdkPixbuf *pixbuf,
                                    const char *uri);

Returns whether the thumbnail has the correct uri embedded in the Thumb::URI option in the png.

#### Parameters

pixbuf | an loaded thumbnail pixbuf |
uri | a uri |

#### Returns

TRUE if the thumbnail is for `uri`

Since 2.2

### mate_desktop_thumbnail_is_valid ()

    gboolean
    mate_desktop_thumbnail_is_valid (GdkPixbuf *pixbuf,
                                     const char *uri,
                                     time_t mtime);

Returns whether the thumbnail has the correct uri and mtime embedded in the png options.

#### Parameters

pixbuf | an loaded thumbnail GdkPixbuf |
uri | a uri |
mtime | the mtime |

#### Returns

TRUE if the thumbnail has the right `uri` and `mtime`

Since 2.2

### mate_desktop_thumbnail_md5 ()

    char *
    mate_desktop_thumbnail_md5 (const char *uri);

`mate_desktop_thumbnail_md5` has been deprecated since version 2.22 and should not be used in newly-written code.

Use GChecksum instead

Calculates the MD5 checksum of the uri. This can be useful if you want to manually handle thumbnail files.

#### Parameters

uri | an uri |

#### Returns

A string with the MD5 digest of the uri string.

Since 2.2

### mate_desktop_thumbnail_path_for_uri ()

    char *
    mate_desktop_thumbnail_path_for_uri (const char *uri,
                                         MateDesktopThumbnailSize size);

Returns the filename that a thumbnail of size `size` for `uri` would have.

#### Parameters

uri | an uri |
size | a thumbnail size |

#### Returns

an absolute filename

Since 2.2

### mate_desktop_thumbnail_scale_down_pixbuf ()

    GdkPixbuf *
    mate_desktop_thumbnail_scale_down_pixbuf
                                   (GdkPixbuf *pixbuf,
                                    int dest_width,
                                    int dest_height);

#### Returns

## Types and Values