annotate src/pixbuf-renderer.h @ 33:a41ecbb26a96

Wed Apr 6 06:41:25 2005 John Ellis <johne@verizon.net> * pan-view.c: Move pixbuf drawing into pixbuf_util.c. * pixbuf-renderer.c: Rename util_clip_region to pr_clip_region to fix namespace conflict with util in pixbuf_util.h. * pixbuf_util.[ch]: Moved pixbuf drawing utils here from pan-view.c ##### Note: GQview CVS on sourceforge is not always up to date, please use ##### ##### an offical release when making enhancements and translation updates. #####
author gqview
date Wed, 06 Apr 2005 10:45:36 +0000
parents 0c3b353b666e
children 44f2223541d1
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
23
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
1 /*
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
2 * GQview
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
3 * (C) 2005 John Ellis
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
4 *
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
5 * Author: John Ellis
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
6 *
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
7 * This software is released under the GNU General Public License (GNU GPL).
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
8 * Please read the included file COPYING for more information.
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
9 * This software comes with no warranty of any kind, use at your own risk!
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
10 */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
11
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
12 #ifndef PIXBUF_RENDERER_H
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
13 #define PIXBUF_RENDERER_H
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
14
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
15 #include <gtk/gtkeventbox.h>
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
16 #include <gtk/gtkwindow.h>
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
17
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
18
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
19 #define TYPE_PIXBUF_RENDERER (pixbuf_renderer_get_type())
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
20 #define PIXBUF_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), TYPE_PIXBUF_RENDERER, PixbufRenderer))
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
21 #define PIXBUF_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), TYPE_PIXBUF_RENDERER, PixbufRendererClass))
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
22 #define IS_PIXBUF_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), TYPE_PIXBUF_RENDERER))
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
23 #define IS_PIXBUF_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), TYPE_PIXBUF_RENDERER))
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
24 #define PIXBUF_RENDERER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), TYPE_PIXBUF_RENDERER, PixbufRendererClass))
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
25
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
26
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
27 typedef struct _PixbufRenderer PixbufRenderer;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
28 typedef struct _PixbufRendererClass PixbufRendererClass;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
29
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
30
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
31 typedef gint (* PixbufRendererTileRequestFunc)(PixbufRenderer *pr, gint x, gint y,
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
32 gint width, gint height, GdkPixbuf *pixbuf, gpointer user_data);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
33 typedef void (* PixbufRendererTileDisposeFunc)(PixbufRenderer *pr, gint x, gint y,
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
34 gint width, gint height, GdkPixbuf *pixbuf, gpointer user_data);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
35 typedef enum {
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
36 PR_SCROLL_RESET_TOPLEFT = 0,
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
37 PR_SCROLL_RESET_CENTER,
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
38 PR_SCROLL_RESET_NOCHANGE
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
39 } PixbufRendererScrollResetType;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
40
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
41 struct _PixbufRenderer
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
42 {
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
43 GtkEventBox eventbox;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
44
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
45 gint image_width; /* image actual dimensions (pixels) */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
46 gint image_height;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
47
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
48 GdkPixbuf *pixbuf;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
49
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
50 gint window_width; /* allocated size of window (drawing area) */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
51 gint window_height;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
52
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
53 gint x_offset; /* offset of image start (non-zero when image < window) */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
54 gint y_offset;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
55
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
56 gint vis_width; /* dimensions of visible part of image */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
57 gint vis_height;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
58
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
59 gint width; /* size of scaled image (result) */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
60 gint height;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
61
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
62 gint x_scroll; /* scroll offset of image (into width, height to start drawing) */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
63 gint y_scroll;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
64
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
65 gdouble zoom_min;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
66 gdouble zoom_max;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
67 gdouble zoom; /* zoom we want (0 is auto) */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
68 gdouble scale; /* zoom we got (should never be 0) */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
69
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
70 GdkInterpType zoom_quality;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
71 gboolean zoom_2pass;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
72 gboolean zoom_expand;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
73
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
74 GdkRgbDither dither_quality;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
75
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
76 PixbufRendererScrollResetType scroll_reset;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
77
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
78 gboolean has_frame;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
79
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
80 GtkWidget *parent_window; /* resize parent_window when image dimensions change */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
81
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
82 gboolean window_fit;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
83 gboolean window_limit;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
84 gint window_limit_size;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
85
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
86 gint tile_cache_max; /* max mb to use for offscreen buffer */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
87
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
88 /*< private >*/
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
89
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
90 gint tile_width;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
91 gint tile_height;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
92 gint tile_cols; /* count of tile columns */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
93 GList *tiles; /* list of buffer tiles */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
94 gint tile_cache_size; /* allocated size of pixmaps/pixbufs */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
95 GList *draw_queue; /* list of areas to redraw */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
96 GList *draw_queue_2pass;/* list when 2 pass is enabled */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
97
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
98 gint draw_idle_id;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
99 gint draw_idle_high; /* current idle_id has high priority */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
100
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
101 gboolean in_drag;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
102 gint drag_last_x;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
103 gint drag_last_y;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
104 gint drag_moved;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
105
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
106 gboolean source_tiles_enabled;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
107 gint source_tiles_cache_size;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
108
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
109 GList *source_tiles; /* list of active source tiles */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
110 gint source_tile_width;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
111 gint source_tile_height;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
112
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
113 PixbufRendererTileRequestFunc func_tile_request;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
114 PixbufRendererTileDisposeFunc func_tile_dispose;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
115
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
116 gpointer func_tile_data;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
117
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
118 gboolean delay_flip;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
119 gboolean loading;
25
0c3b353b666e Fri Mar 25 22:39:30 2005 John Ellis <johne@verizon.net>
gqview
parents: 24
diff changeset
120 gboolean complete;
23
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
121
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
122 gint scroller_id;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
123 gint scroller_overlay;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
124 gint scroller_x;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
125 gint scroller_y;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
126 gint scroller_xpos;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
127 gint scroller_ypos;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
128 gint scroller_xinc;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
129 gint scroller_yinc;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
130
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
131 GList *overlay_list;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
132 };
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
133
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
134 struct _PixbufRendererClass
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
135 {
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
136 GtkEventBoxClass parent_class;
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
137
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
138 void (* zoom) (PixbufRenderer *pr, gdouble zoom);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
139 void (* clicked) (PixbufRenderer *pr, GdkEventButton *event);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
140 void (* scroll_notify) (PixbufRenderer *pr);
25
0c3b353b666e Fri Mar 25 22:39:30 2005 John Ellis <johne@verizon.net>
gqview
parents: 24
diff changeset
141
0c3b353b666e Fri Mar 25 22:39:30 2005 John Ellis <johne@verizon.net>
gqview
parents: 24
diff changeset
142 void (* render_complete)(PixbufRenderer *pr);
23
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
143 };
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
144
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
145
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
146 GType pixbuf_renderer_get_type (void);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
147
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
148 PixbufRenderer *pixbuf_renderer_new(void);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
149
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
150 void pixbuf_renderer_set_parent(PixbufRenderer *pr, GtkWindow *window);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
151 GtkWindow *pixbuf_renderer_get_parent(PixbufRenderer *pr);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
152
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
153 /* display a pixbuf */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
154
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
155 void pixbuf_renderer_set_pixbuf(PixbufRenderer *pr, GdkPixbuf *pixbuf, gdouble zoom);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
156 GdkPixbuf *pixbuf_renderer_get_pixbuf(PixbufRenderer *pr);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
157
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
158 /* display an on-request array of pixbuf tiles */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
159
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
160 void pixbuf_renderer_set_tiles(PixbufRenderer *pr, gint width, gint height,
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
161 gint tile_width, gint tile_height, gint cache_size,
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
162 PixbufRendererTileRequestFunc func_request,
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
163 PixbufRendererTileDisposeFunc func_dispose,
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
164 gpointer user_data,
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
165 gdouble zoom);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
166 gint pixbuf_renderer_get_tiles(PixbufRenderer *pr);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
167
24
104e34f9ab1f Wed Mar 23 00:22:28 2005 John Ellis <johne@verizon.net>
gqview
parents: 23
diff changeset
168 /* move image data from source to pr, source is then set to NULL image */
104e34f9ab1f Wed Mar 23 00:22:28 2005 John Ellis <johne@verizon.net>
gqview
parents: 23
diff changeset
169
104e34f9ab1f Wed Mar 23 00:22:28 2005 John Ellis <johne@verizon.net>
gqview
parents: 23
diff changeset
170 void pixbuf_renderer_move(PixbufRenderer *pr, PixbufRenderer *source);
104e34f9ab1f Wed Mar 23 00:22:28 2005 John Ellis <johne@verizon.net>
gqview
parents: 23
diff changeset
171
23
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
172 /* update region of existing image */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
173
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
174 void pixbuf_renderer_area_changed(PixbufRenderer *pr, gint x, gint y, gint width, gint height);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
175
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
176 /* scrolling */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
177
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
178 void pixbuf_renderer_scroll(PixbufRenderer *pr, gint x, gint y);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
179 void pixbuf_renderer_scroll_to_point(PixbufRenderer *pr, gint x, gint y,
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
180 gdouble x_align, gdouble y_align);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
181
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
182 /* zoom */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
183
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
184 void pixbuf_renderer_zoom_adjust(PixbufRenderer *pr, gdouble increment);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
185 void pixbuf_renderer_zoom_adjust_at_point(PixbufRenderer *pr, gdouble increment, gint x, gint y);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
186
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
187 void pixbuf_renderer_zoom_set(PixbufRenderer *pr, gdouble zoom);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
188 gdouble pixbuf_renderer_zoom_get(PixbufRenderer *pr);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
189 gdouble pixbuf_renderer_zoom_get_scale(PixbufRenderer *pr);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
190
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
191 void pixbuf_renderer_zoom_set_limits(PixbufRenderer *pr, gdouble min, gdouble max);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
192
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
193 /* sizes */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
194
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
195 gint pixbuf_renderer_get_image_size(PixbufRenderer *pr, gint *width, gint *height);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
196 gint pixbuf_renderer_get_scaled_size(PixbufRenderer *pr, gint *width, gint *height);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
197
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
198 /* region of image in pixel coordinates */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
199 gint pixbuf_renderer_get_visible_rect(PixbufRenderer *pr, GdkRectangle *rect);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
200
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
201 /* actual size of the PixbufRenderer window minus borders,
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
202 * x and y are the scroll offset and include zoom factor.
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
203 */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
204 gint pixbuf_renderer_get_virtual_rect(PixbufRenderer *pr, GdkRectangle *rect);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
205
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
206 /* background color */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
207
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
208 void pixbuf_renderer_set_color(PixbufRenderer *pr, GdkColor *color);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
209 void pixbuf_renderer_set_black(PixbufRenderer *pr, gint black);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
210
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
211 /* overlay */
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
212
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
213 gint pixbuf_renderer_overlay_add(PixbufRenderer *pr, GdkPixbuf *pixbuf, gint x, gint y,
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
214 gint relative, gint always);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
215 void pixbuf_renderer_overlay_set(PixbufRenderer *pr, gint id, GdkPixbuf *pixbuf, gint x, gint y);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
216 gint pixbuf_renderer_overlay_get(PixbufRenderer *pr, gint id, GdkPixbuf **pixbuf, gint *x, gint *y);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
217 void pixbuf_renderer_overlay_remove(PixbufRenderer *pr, gint id);
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
218
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
219
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
220 #endif
17acca639a86 ##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
diff changeset
221