~ubuntu-branches/ubuntu/raring/vala-0.20/raring-proposed

« back to all changes in this revision

Viewing changes to vapi/gdk-pixbuf-2.0.vapi

  • Committer: Package Import Robot
  • Author(s): Sebastien Bacher
  • Date: 2013-04-05 13:45:05 UTC
  • Revision ID: package-import@ubuntu.com-20130405134505-yyk3rec9904i7p8o
Tags: upstream-0.20.1
ImportĀ upstreamĀ versionĀ 0.20.1

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* gdk-pixbuf-2.0.vapi generated by vapigen, do not modify. */
 
2
 
 
3
[CCode (cprefix = "Gdk", gir_namespace = "GdkPixbuf", gir_version = "2.0", lower_case_cprefix = "gdk_")]
 
4
namespace Gdk {
 
5
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h")]
 
6
        public class Pixbuf : GLib.Object, GLib.Icon {
 
7
                [CCode (has_construct_function = false)]
 
8
                public Pixbuf (Gdk.Colorspace colorspace, bool has_alpha, int bits_per_sample, int width, int height);
 
9
                public Gdk.Pixbuf add_alpha (bool substitute_color, uint8 r, uint8 g, uint8 b);
 
10
                public Gdk.Pixbuf apply_embedded_orientation ();
 
11
                public void composite (Gdk.Pixbuf dest, int dest_x, int dest_y, int dest_width, int dest_height, double offset_x, double offset_y, double scale_x, double scale_y, Gdk.InterpType interp_type, int overall_alpha);
 
12
                public void composite_color (Gdk.Pixbuf dest, int dest_x, int dest_y, int dest_width, int dest_height, double offset_x, double offset_y, double scale_x, double scale_y, Gdk.InterpType interp_type, int overall_alpha, int check_x, int check_y, int check_size, uint32 color1, uint32 color2);
 
13
                public Gdk.Pixbuf? composite_color_simple (int dest_width, int dest_height, Gdk.InterpType interp_type, int overall_alpha, int check_size, uint32 color1, uint32 color2);
 
14
                public Gdk.Pixbuf copy ();
 
15
                public void copy_area (int src_x, int src_y, int width, int height, Gdk.Pixbuf dest_pixbuf, int dest_x, int dest_y);
 
16
                public void fill (uint32 pixel);
 
17
                public Gdk.Pixbuf? flip (bool horizontal);
 
18
                [CCode (has_construct_function = false)]
 
19
                public Pixbuf.from_data ([CCode (array_length = false)] owned uint8[] data, Gdk.Colorspace colorspace, bool has_alpha, int bits_per_sample, int width, int height, int rowstride, [CCode (type = "GdkPixbufDestroyNotify")] Gdk.PixbufDestroyNotify? destroy_fn = GLib.free);
 
20
                [CCode (has_construct_function = false)]
 
21
                public Pixbuf.from_file (string filename) throws GLib.Error;
 
22
                [CCode (has_construct_function = false)]
 
23
                public Pixbuf.from_file_at_scale (string filename, int width, int height, bool preserve_aspect_ratio) throws GLib.Error;
 
24
                [CCode (has_construct_function = false)]
 
25
                public Pixbuf.from_file_at_size (string filename, int width, int height) throws GLib.Error;
 
26
                [CCode (has_construct_function = false)]
 
27
                public Pixbuf.from_inline ([CCode (array_length_cname = "data_length", array_length_pos = 0.5)] uint8[] data, bool copy_pixels = true) throws GLib.Error;
 
28
                [CCode (cheader_filename = "gdk-pixbuf/gdk-pixdata.h")]
 
29
                public static Gdk.Pixbuf from_pixdata (Gdk.Pixdata pixdata, bool copy_pixels = true) throws GLib.Error;
 
30
                [CCode (has_construct_function = false)]
 
31
                public Pixbuf.from_resource (string resource_path) throws GLib.Error;
 
32
                [CCode (has_construct_function = false)]
 
33
                public Pixbuf.from_resource_at_scale (string resource_path, int width, int height, bool preserve_aspect_ratio) throws GLib.Error;
 
34
                [CCode (has_construct_function = false)]
 
35
                public Pixbuf.from_stream (GLib.InputStream stream, GLib.Cancellable? cancellable = null) throws GLib.Error;
 
36
                [CCode (cname = "gdk_pixbuf_new_from_stream_async", has_construct_function = false)]
 
37
                public async Pixbuf.from_stream_async (GLib.InputStream stream, GLib.Cancellable? cancellable) throws GLib.Error;
 
38
                [CCode (has_construct_function = false)]
 
39
                public Pixbuf.from_stream_at_scale (GLib.InputStream stream, int width, int height, bool preserve_aspect_ratio, GLib.Cancellable? cancellable = null) throws GLib.Error;
 
40
                [CCode (cname = "gdk_pixbuf_new_from_stream_at_scale_async", finish_name = "gdk_pixbuf_new_from_stream_finish")]
 
41
                public async Pixbuf.from_stream_at_scale_async (GLib.InputStream stream, int width, int height, bool preserve_aspect_ratio, GLib.Cancellable? cancellable = null) throws GLib.Error;
 
42
                [CCode (has_construct_function = false)]
 
43
                public Pixbuf.from_xpm_data ([CCode (array_length = false, array_null_terminated = true)] string[] data);
 
44
                public int get_bits_per_sample ();
 
45
                public size_t get_byte_length ();
 
46
                public Gdk.Colorspace get_colorspace ();
 
47
                public static unowned Gdk.PixbufFormat get_file_info (string filename, out int width, out int height);
 
48
                public static GLib.SList<weak Gdk.PixbufFormat> get_formats ();
 
49
                public bool get_has_alpha ();
 
50
                public int get_height ();
 
51
                public int get_n_channels ();
 
52
                public unowned string get_option (string key);
 
53
                [CCode (array_length = false)]
 
54
                public unowned uint8[] get_pixels ();
 
55
                [CCode (array_length_pos = 0.1, array_length_type = "guint")]
 
56
                public unowned uint8[] get_pixels_with_length ();
 
57
                public int get_rowstride ();
 
58
                public int get_width ();
 
59
                [CCode (cname = "gdk_pixbuf_new_from_stream_async", finish_name = "gdk_pixbuf_new_from_stream_finish")]
 
60
                [Deprecated (replacement = "Pixbuf.from_stream_async", since = "vala-0.18")]
 
61
                public static async Gdk.Pixbuf new_from_stream_async (GLib.InputStream stream, GLib.Cancellable? cancellable = null) throws GLib.Error;
 
62
                [CCode (cname = "gdk_pixbuf_new_from_stream_at_scale_async", finish_name = "gdk_pixbuf_new_from_stream_finish")]
 
63
                [Deprecated (replacement = "Pixbuf.from_stream_at_scale_async", since = "vala-0.18")]
 
64
                public static async Gdk.Pixbuf new_from_stream_at_scale_async (GLib.InputStream stream, int width, int height, bool preserve_aspect_ratio, GLib.Cancellable? cancellable = null) throws GLib.Error;
 
65
                public Gdk.Pixbuf rotate_simple (Gdk.PixbufRotation angle);
 
66
                public void saturate_and_pixelate (Gdk.Pixbuf dest, float saturation, bool pixelate);
 
67
                public bool save (string filename, string type, ...) throws GLib.Error;
 
68
                public bool save_to_buffer ([CCode (array_length_type = "gsize", type = "gchar**")] out uint8[] buffer, string type, ...) throws GLib.Error;
 
69
                public bool save_to_bufferv ([CCode (array_length_cname = "buffer_size", array_length_pos = 1.5, array_length_type = "gsize")] out uint8[] buffer, string type, [CCode (array_length = false, array_null_terminated = true)] string[] option_keys, [CCode (array_length = false, array_null_terminated = true)] string[] option_values) throws GLib.Error;
 
70
                public bool save_to_callback (Gdk.PixbufSaveFunc save_func, string type, ...) throws GLib.Error;
 
71
                public bool save_to_callbackv ([CCode (delegate_target_pos = 1.5)] Gdk.PixbufSaveFunc save_func, string type, [CCode (array_length = false, array_null_terminated = true)] string[] option_keys, [CCode (array_length = false, array_null_terminated = true)] string[] option_values) throws GLib.Error;
 
72
                public bool save_to_stream (GLib.OutputStream stream, string type, GLib.Cancellable? cancellable = null) throws GLib.Error;
 
73
                [CCode (finish_name = "gdk_pixbuf_save_to_stream_finish")]
 
74
                public async bool save_to_stream_async (GLib.OutputStream stream, string type, GLib.Cancellable? cancellable = null) throws GLib.Error;
 
75
                public bool savev (string filename, string type, [CCode (array_length = false, array_null_terminated = true)] string[] option_keys, [CCode (array_length = false, array_null_terminated = true)] string[] option_values) throws GLib.Error;
 
76
                public void scale (Gdk.Pixbuf dest, int dest_x, int dest_y, int dest_width, int dest_height, double offset_x, double offset_y, double scale_x, double scale_y, Gdk.InterpType interp_type);
 
77
                public Gdk.Pixbuf scale_simple (int dest_width, int dest_height, Gdk.InterpType interp_type);
 
78
                [CCode (has_construct_function = false)]
 
79
                public Pixbuf.subpixbuf (Gdk.Pixbuf src_pixbuf, int src_x, int src_y, int width, int height);
 
80
                [CCode (cname = "gdk_pixbuf_new_from_data", has_construct_function = false)]
 
81
                public Pixbuf.with_unowned_data ([CCode (array_length = false)] uint8[] data, Gdk.Colorspace colorspace, bool has_alpha, int bits_per_sample, int width, int height, int rowstride, [CCode (type = "GdkPixbufDestroyNotify")] Gdk.PixbufDestroyNotify? destroy_fn = null);
 
82
                public int bits_per_sample { get; construct; }
 
83
                public Gdk.Colorspace colorspace { get; construct; }
 
84
                public bool has_alpha { get; construct; }
 
85
                public int height { get; construct; }
 
86
                public int n_channels { get; construct; }
 
87
                public void* pixels { get; construct; }
 
88
                public int rowstride { get; construct; }
 
89
                public int width { get; construct; }
 
90
        }
 
91
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", type_id = "gdk_pixbuf_animation_get_type ()")]
 
92
        public class PixbufAnimation : GLib.Object {
 
93
                [CCode (has_construct_function = false)]
 
94
                protected PixbufAnimation ();
 
95
                [CCode (has_construct_function = false)]
 
96
                public PixbufAnimation.from_file (string filename) throws GLib.Error;
 
97
                [CCode (has_construct_function = false)]
 
98
                public PixbufAnimation.from_resource (string resource_path) throws GLib.Error;
 
99
                [CCode (has_construct_function = false)]
 
100
                public PixbufAnimation.from_stream (GLib.InputStream stream, GLib.Cancellable? cancellable = null) throws GLib.Error;
 
101
                [CCode (cname = "gdk_pixbuf_animation_new_from_stream_async", has_construct_function = false)]
 
102
                public async PixbufAnimation.from_stream_async (GLib.InputStream stream, GLib.Cancellable? cancellable) throws GLib.Error;
 
103
                public int get_height ();
 
104
                public Gdk.PixbufAnimationIter get_iter (GLib.TimeVal? start_time);
 
105
                public unowned Gdk.Pixbuf get_static_image ();
 
106
                public int get_width ();
 
107
                public bool is_static_image ();
 
108
        }
 
109
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", type_id = "gdk_pixbuf_animation_iter_get_type ()")]
 
110
        public class PixbufAnimationIter : GLib.Object {
 
111
                [CCode (has_construct_function = false)]
 
112
                protected PixbufAnimationIter ();
 
113
                public bool advance (GLib.TimeVal? current_time);
 
114
                public int get_delay_time ();
 
115
                public unowned Gdk.Pixbuf get_pixbuf ();
 
116
                public bool on_currently_loading_frame ();
 
117
        }
 
118
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", copy_function = "g_boxed_copy", free_function = "g_boxed_free", type_id = "gdk_pixbuf_format_get_type ()")]
 
119
        [Compact]
 
120
        public class PixbufFormat {
 
121
                public Gdk.PixbufFormat copy ();
 
122
                public void free ();
 
123
                public string get_description ();
 
124
                [CCode (array_length = false, array_null_terminated = true)]
 
125
                public string[] get_extensions ();
 
126
                public string get_license ();
 
127
                [CCode (array_length = false, array_null_terminated = true)]
 
128
                public string[] get_mime_types ();
 
129
                public string get_name ();
 
130
                public bool is_disabled ();
 
131
                public bool is_scalable ();
 
132
                public bool is_writable ();
 
133
                public void set_disabled (bool disabled);
 
134
        }
 
135
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", type_id = "gdk_pixbuf_loader_get_type ()")]
 
136
        public class PixbufLoader : GLib.Object {
 
137
                [CCode (has_construct_function = false)]
 
138
                public PixbufLoader ();
 
139
                public bool close () throws GLib.Error;
 
140
                public unowned Gdk.PixbufAnimation get_animation ();
 
141
                public unowned Gdk.PixbufFormat get_format ();
 
142
                public unowned Gdk.Pixbuf get_pixbuf ();
 
143
                public void set_size (int width, int height);
 
144
                [CCode (has_construct_function = false)]
 
145
                public PixbufLoader.with_mime_type (string mime_type) throws GLib.Error;
 
146
                [CCode (has_construct_function = false)]
 
147
                public PixbufLoader.with_type (string image_type) throws GLib.Error;
 
148
                public bool write ([CCode (array_length_cname = "count", array_length_pos = 1.1, array_length_type = "gsize")] uint8[] buf) throws GLib.Error;
 
149
                public virtual signal void area_prepared ();
 
150
                public virtual signal void area_updated (int x, int y, int width, int height);
 
151
                public virtual signal void closed ();
 
152
                public virtual signal void size_prepared (int width, int height);
 
153
        }
 
154
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", type_id = "gdk_pixbuf_simple_anim_get_type ()")]
 
155
        public class PixbufSimpleAnim : Gdk.PixbufAnimation {
 
156
                [CCode (has_construct_function = false)]
 
157
                public PixbufSimpleAnim (int width, int height, float rate);
 
158
                public void add_frame (Gdk.Pixbuf pixbuf);
 
159
                public bool get_loop ();
 
160
                public void set_loop (bool loop);
 
161
                public bool loop { get; set; }
 
162
        }
 
163
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", type_id = "gdk_pixbuf_simple_anim_iter_get_type ()")]
 
164
        public class PixbufSimpleAnimIter : Gdk.PixbufAnimationIter {
 
165
                [CCode (has_construct_function = false)]
 
166
                protected PixbufSimpleAnimIter ();
 
167
        }
 
168
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixdata.h", has_type_id = false)]
 
169
        public struct Pixdata {
 
170
                public uint32 magic;
 
171
                public int32 length;
 
172
                public uint32 pixdata_type;
 
173
                public uint32 rowstride;
 
174
                public uint32 width;
 
175
                public uint32 height;
 
176
                [CCode (array_length = false, array_null_terminated = true)]
 
177
                public weak uint8[] pixel_data;
 
178
                public bool deserialize ([CCode (array_length_cname = "stream_length", array_length_pos = 0.5, array_length_type = "guint")] uint8[] stream) throws GLib.Error;
 
179
                [CCode (array_length_pos = 0.1, array_length_type = "guint")]
 
180
                public uint8[] serialize ();
 
181
                public GLib.StringBuilder to_csource (string name, Gdk.PixdataDumpType dump_type);
 
182
        }
 
183
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", cprefix = "GDK_COLORSPACE_", type_id = "gdk_colorspace_get_type ()")]
 
184
        public enum Colorspace {
 
185
                RGB
 
186
        }
 
187
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", cprefix = "GDK_INTERP_", type_id = "gdk_interp_type_get_type ()")]
 
188
        public enum InterpType {
 
189
                NEAREST,
 
190
                TILES,
 
191
                BILINEAR,
 
192
                HYPER
 
193
        }
 
194
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", cprefix = "GDK_PIXBUF_ALPHA_", type_id = "gdk_pixbuf_alpha_mode_get_type ()")]
 
195
        public enum PixbufAlphaMode {
 
196
                BILEVEL,
 
197
                FULL
 
198
        }
 
199
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", cprefix = "GDK_PIXBUF_ROTATE_", type_id = "gdk_pixbuf_rotation_get_type ()")]
 
200
        public enum PixbufRotation {
 
201
                NONE,
 
202
                COUNTERCLOCKWISE,
 
203
                UPSIDEDOWN,
 
204
                CLOCKWISE
 
205
        }
 
206
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixdata.h", cprefix = "GDK_PIXDATA_DUMP_", has_type_id = false)]
 
207
        [Flags]
 
208
        public enum PixdataDumpType {
 
209
                PIXDATA_STREAM,
 
210
                PIXDATA_STRUCT,
 
211
                MACROS,
 
212
                GTYPES,
 
213
                CTYPES,
 
214
                STATIC,
 
215
                CONST,
 
216
                RLE_DECODER
 
217
        }
 
218
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixdata.h", cprefix = "GDK_PIXDATA_", has_type_id = false)]
 
219
        [Flags]
 
220
        public enum PixdataType {
 
221
                COLOR_TYPE_RGB,
 
222
                COLOR_TYPE_RGBA,
 
223
                COLOR_TYPE_MASK,
 
224
                SAMPLE_WIDTH_8,
 
225
                SAMPLE_WIDTH_MASK,
 
226
                ENCODING_RAW,
 
227
                ENCODING_RLE,
 
228
                ENCODING_MASK
 
229
        }
 
230
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", cprefix = "GDK_PIXBUF_ERROR_")]
 
231
        public errordomain PixbufError {
 
232
                CORRUPT_IMAGE,
 
233
                INSUFFICIENT_MEMORY,
 
234
                BAD_OPTION,
 
235
                UNKNOWN_TYPE,
 
236
                UNSUPPORTED_OPERATION,
 
237
                FAILED;
 
238
                public static GLib.Quark quark ();
 
239
        }
 
240
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", instance_pos = 1.9)]
 
241
        public delegate void PixbufDestroyNotify ([CCode (array_length = false)] uint8[] pixels);
 
242
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixdata.h", instance_pos = -0.9)]
 
243
        public delegate bool PixbufSaveFunc ([CCode (array_length_type = "gsize")] uint8[] buf) throws GLib.Error;
 
244
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", cname = "GDK_PIXBUF_FEATURES_H")]
 
245
        public const int PIXBUF_FEATURES_H;
 
246
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", cname = "GDK_PIXBUF_MAGIC_NUMBER")]
 
247
        public const int PIXBUF_MAGIC_NUMBER;
 
248
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", cname = "GDK_PIXBUF_MAJOR")]
 
249
        public const int PIXBUF_MAJOR;
 
250
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", cname = "GDK_PIXBUF_MICRO")]
 
251
        public const int PIXBUF_MICRO;
 
252
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", cname = "GDK_PIXBUF_MINOR")]
 
253
        public const int PIXBUF_MINOR;
 
254
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", cname = "GDK_PIXBUF_VERSION")]
 
255
        public const string PIXBUF_VERSION;
 
256
        [CCode (cheader_filename = "gdk-pixbuf/gdk-pixbuf.h", cname = "GDK_PIXDATA_HEADER_LENGTH")]
 
257
        public const int PIXDATA_HEADER_LENGTH;
 
258
}