]> Pileus Git - ~andy/gtk/blob - docs/reference/gdk-pixbuf/tmpl/module_interface.sgml
5b0a95bc07e3886336f90b36a6e693bf4b61f0b7
[~andy/gtk] / docs / reference / gdk-pixbuf / tmpl / module_interface.sgml
1 <!-- ##### SECTION Title ##### -->
2 Module Interface
3
4 <!-- ##### SECTION Short_Description ##### -->
5
6
7 <!-- ##### SECTION Long_Description ##### -->
8 <para>
9
10 </para>
11
12 <!-- ##### SECTION See_Also ##### -->
13 <para>
14
15 </para>
16
17 <!-- ##### USER_FUNCTION ModuleFillVtableFunc ##### -->
18 <para>
19 Defines the type of the function used to set the vtable of a 
20 #GdkPixbufModule when it is loaded.
21 </para>
22
23 @module: a #GdkPixbufModule.
24
25
26 <!-- ##### USER_FUNCTION ModulePreparedNotifyFunc ##### -->
27 <para>
28 Defines the type of the function that gets called once the initial 
29 setup of @pixbuf is done.
30 </para>
31 <para>
32 #GdkPixbufLoader uses a function of this type to emit the 
33 "<link linkend="GdkPixbufLoader-area-prepared">area_prepared</link>"
34 signal.
35 </para>
36
37 @pixbuf: the #GdkPixbuf that is currently being loaded.
38 @anim: if an animation is being loaded, the #GdkPixbufAnimation, else %NULL.
39 @user_data: the loader.
40
41
42 <!-- ##### USER_FUNCTION ModuleUpdatedNotifyFunc ##### -->
43 <para>
44 Defines the type of the function that gets called every time a region
45 of @pixbuf is updated.
46 </para>
47 <para>
48 #GdkPixbufLoader uses a function of this type to emit the 
49 "<link linkend="GdkPixbufLoader-area-updated">area_updated</link>"
50 signal.
51 </para>
52
53 @pixbuf: the #GdkPixbuf that is currently being loaded.
54 @x: the X origin of the updated area.
55 @y: the Y origin of the updated area.
56 @width: the width of the updated area.
57 @height: the height of the updated area.
58 @user_data: the loader.
59
60
61 <!-- ##### STRUCT GdkPixbufModule ##### -->
62 <para>
63 A #GdkPixbufModule contains the necessary functions to load and save 
64 images in a certain file format. 
65 </para>
66 <para>
67 A #GdkPixbufModule can be loaded dynamically from a #GModule.
68 Each loadable module must contain a #ModuleFillVtableFunc function named 
69 <funcion>gdk_pixbuf__<replaceable>module_name</replaceable>_fill_vtable</function>.
70 It will get called when the module is loaded and must set the function
71 pointers of the #GdkPixbufModule.
72 </para>
73
74 @module_name: the name of the module, usually the same as the
75   usual file extension for images of this type, eg. "xpm", "jpeg" or "png".
76 @format_check: checks if the given data is the beginning of a valid image 
77   in the format supported by the module.
78 @module: the loaded #GModule.
79 @load: loads an image from a file.
80 @load_xpm_data: loads an image from data in memory.
81 @begin_load: begins an incremental load.
82 @stop_load: stops an incremental load.
83 @load_increment: continues an incremental load.
84 @load_animation: loads an animation from a file.
85 @save: saves a #GdkPixbuf to a file.
86