~ubuntu-branches/ubuntu/jaunty/gimp/jaunty-security

« back to all changes in this revision

Viewing changes to libgimp/gimpimage.c

  • Committer: Bazaar Package Importer
  • Author(s): Daniel Holbach
  • Date: 2007-05-02 16:33:03 UTC
  • mfrom: (1.1.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20070502163303-bvzhjzbpw8qglc4y
Tags: 2.3.16-1ubuntu1
* Resynchronized with Debian, remaining Ubuntu changes:
  - debian/rules: i18n magic.
* debian/control.in:
  - Maintainer: Ubuntu Core Developers <ubuntu-devel@lists.ubuntu.com>
* debian/patches/02_help-message.patch,
  debian/patches/03_gimp.desktop.in.in.patch,
  debian/patches/10_dont_show_wizard.patch: updated.
* debian/patches/04_composite-signedness.patch,
  debian/patches/05_add-letter-spacing.patch: dropped, used upstream.

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
#include "config.h"
23
23
 
24
24
#include "gimp.h"
25
 
 
 
25
#undef GIMP_DISABLE_DEPRECATED
 
26
#undef __GIMP_IMAGE_H__
 
27
#include "gimpimage.h"
26
28
 
27
29
/**
28
30
 * gimp_image_get_cmap:
35
37
 */
36
38
guchar *
37
39
gimp_image_get_cmap (gint32  image_ID,
38
 
                     gint   *num_colors)
 
40
                     gint   *num_colors)
39
41
{
40
42
  return gimp_image_get_colormap (image_ID, num_colors);
41
43
}
52
54
 */
53
55
gboolean
54
56
gimp_image_set_cmap (gint32        image_ID,
55
 
                     const guchar *cmap,
56
 
                     gint          num_colors)
 
57
                     const guchar *cmap,
 
58
                     gint          num_colors)
57
59
{
58
60
  return gimp_image_set_colormap (image_ID, cmap, num_colors);
59
61
}
110
112
 
111
113
guchar *
112
114
gimp_image_get_thumbnail_data (gint32  image_ID,
113
 
                               gint   *width,
114
 
                               gint   *height,
115
 
                               gint   *bpp)
 
115
                               gint   *width,
 
116
                               gint   *height,
 
117
                               gint   *bpp)
116
118
{
117
119
  gint    ret_width;
118
120
  gint    ret_height;
120
122
  gint    data_size;
121
123
 
122
124
  _gimp_image_thumbnail (image_ID,
123
 
                         *width,
124
 
                         *height,
125
 
                         &ret_width,
126
 
                         &ret_height,
127
 
                         bpp,
128
 
                         &data_size,
129
 
                         &image_data);
 
125
                         *width,
 
126
                         *height,
 
127
                         &ret_width,
 
128
                         &ret_height,
 
129
                         bpp,
 
130
                         &data_size,
 
131
                         &image_data);
130
132
 
131
133
  *width  = ret_width;
132
134
  *height = ret_height;
145
147
 * Convenience function that creates a parasite and attaches it
146
148
 * to the GIMP.
147
149
 *
 
150
 * Return value: TRUE on successful creation and attachment of
 
151
 * the new parasite.
 
152
 *
148
153
 * See Also: gimp_image_parasite_attach()
149
154
 */
150
 
void
 
155
gboolean
151
156
gimp_image_attach_new_parasite (gint32         image_ID,
152
 
                                const gchar   *name,
153
 
                                gint           flags,
154
 
                                gint           size,
155
 
                                gconstpointer  data)
 
157
                                const gchar   *name,
 
158
                                gint           flags,
 
159
                                gint           size,
 
160
                                gconstpointer  data)
156
161
{
157
162
  GimpParasite *parasite = gimp_parasite_new (name, flags, size, data);
 
163
  gboolean      success;
158
164
 
159
 
  gimp_image_parasite_attach (image_ID, parasite);
 
165
  success = gimp_image_parasite_attach (image_ID, parasite);
160
166
 
161
167
  gimp_parasite_free (parasite);
 
168
 
 
169
  return success;
162
170
}