7 * This software is released under the GNU General Public License (GNU GPL).
8 * Please read the included file COPYING for more information.
9 * This software comes with no warranty of any kind, use at your own risk!
27 ALTER_NONE, /* do nothing */
29 ALTER_ROTATE_90_CC, /* counterclockwise */
38 LAYOUT_RIGHT = 1 << 1,
40 LAYOUT_BOTTOM = 1 << 3
44 typedef struct _ImageLoader ImageLoader;
45 typedef struct _ThumbLoader ThumbLoader;
47 typedef struct _CollectInfo CollectInfo;
48 typedef struct _CollectionData CollectionData;
49 typedef struct _CollectTable CollectTable;
50 typedef struct _CollectWindow CollectWindow;
52 typedef struct _ImageWindow ImageWindow;
54 typedef struct _FileData FileData;
56 typedef struct _LayoutWindow LayoutWindow;
57 typedef struct _ViewDirList ViewDirList;
58 typedef struct _ViewDirTree ViewDirTree;
59 typedef struct _ViewFileList ViewFileList;
60 typedef struct _ViewFileIcon ViewFileIcon;
62 typedef struct _SlideShowData SlideShowData;
63 typedef struct _FullScreenData FullScreenData;
65 typedef struct _PixmapFolders PixmapFolders;
79 gint requested_height;
86 GdkPixbufLoader *loader;
89 void (*func_area_ready)(ImageLoader *, guint x, guint y, guint w, guint h, gpointer);
90 void (*func_error)(ImageLoader *, gpointer);
91 void (*func_done)(ImageLoader *, gpointer);
92 void (*func_percent)(ImageLoader *, gdouble, gpointer);
94 gpointer data_area_ready;
97 gpointer data_percent;
102 typedef void (* ThumbLoaderFunc)(ThumbLoader *tl, gpointer data);
106 gint standard_loader;
108 GdkPixbuf *pixbuf; /* contains final (scaled) image when done */
114 gdouble percent_done;
119 ThumbLoaderFunc func_done;
120 ThumbLoaderFunc func_error;
121 ThumbLoaderFunc func_progress;
138 struct _CollectionData
143 SortType sort_method;
145 ThumbLoader *thumb_loader;
146 CollectInfo *thumb_info;
148 void (*info_updated_func)(CollectionData *, CollectInfo *, gpointer);
149 gpointer info_updated_data;
160 /* contents changed since save flag */
174 CollectInfo *prev_selection;
176 CollectInfo *click_info;
178 GtkWidget *tip_window;
180 CollectInfo *tip_info;
182 GdkWindow *marker_window;
183 CollectInfo *marker_info;
185 GtkWidget *status_label;
186 GtkWidget *extra_label;
190 CollectInfo *focus_info;
193 CollectInfo *drop_info;
202 struct _CollectWindow
206 GtkWidget *status_box;
209 GtkWidget *close_dialog;
214 typedef gint (* ImageTileRequestFunc)(ImageWindow *imd, gint x, gint y,
215 gint width, gint height, GdkPixbuf *pixbuf, gpointer);
216 typedef void (* ImageTileDisposeFunc)(ImageWindow *imd, gint x, gint y,
217 gint width, gint height, GdkPixbuf *pixbuf, gpointer);
221 GtkWidget *widget; /* use this to add it and show it */
226 const gchar *image_name;
228 gint64 size; /* file size (bytes) */
229 time_t mtime; /* file modified time stamp */
230 gint unknown; /* failed to load image */
236 /* top level (not necessarily parent) window */
237 gint top_window_sync; /* resize top_window when image dimensions change */
238 GtkWidget *top_window; /* window that gets title, and window to resize when 'fitting' */
239 gchar *title; /* window title to display left of file name */
240 gchar *title_right; /* window title to display right of file name */
241 gint title_show_zoom; /* option to include zoom in window title */
245 void (*func_update)(ImageWindow *, gpointer);
246 void (*func_complete)(ImageWindow *, gint preload, gpointer);
247 void (*func_new)(ImageWindow *, gpointer);
248 ImageTileRequestFunc func_tile_request;
249 ImageTileDisposeFunc func_tile_dispose;
251 gpointer data_update;
252 gpointer data_complete;
256 /* button, scroll functions */
257 void (*func_button)(ImageWindow *, gint button,
258 guint32 time, gdouble x, gdouble y, guint state, gpointer);
259 void (*func_scroll)(ImageWindow *, GdkScrollDirection direction,
260 guint32 time, gdouble x, gdouble y, guint state, gpointer);
262 gpointer data_button;
263 gpointer data_scroll;
265 /* scroll notification (for scroll bar implementation) */
266 void (*func_scroll_notify)(ImageWindow *, gint x, gint y, gint width, gint height, gpointer);
268 gpointer data_scroll_notify;
270 /* collection info */
271 CollectionData *collection;
272 CollectInfo *collection_info;
274 AlterType delay_alter_type;
276 ImageLoader *read_ahead_il;
277 GdkPixbuf *read_ahead_pixbuf;
278 gchar *read_ahead_path;
280 GdkPixbuf *prev_pixbuf;
283 gint auto_refresh_id;
284 gint auto_refresh_interval;
308 GtkWidget *group_box;
312 /* menus, path selector */
314 GtkActionGroup *action_group;
315 GtkUIManager *ui_manager;
317 GtkWidget *path_entry;
321 LayoutLocation image_location;
325 /* tools window (float) */
328 GtkWidget *tools_pane;
338 GtkWidget *thumb_button;
343 LayoutLocation dir_location;
353 LayoutLocation file_location;
357 GtkWidget *file_view;
360 SortType sort_method;
366 GtkWidget *info_progress_bar;
367 GtkWidget *info_sort;
368 GtkWidget *info_status;
369 GtkWidget *info_details;
370 GtkWidget *info_zoom;
374 SlideShowData *slideshow;
378 FullScreenData *full_screen;
379 gint full_screen_overlay_id;
380 gint full_screen_overlay_on;
388 /* directory update check */
395 GtkWidget *utility_box;
400 gint bar_sort_enabled;
401 gint bar_exif_enabled;
402 gint bar_info_enabled;
405 gint bar_exif_advanced;
424 void (*select_func)(ViewDirList *vdl, const gchar *path, gpointer data);
425 gpointer select_data;
427 LayoutWindow *layout;
450 void (*select_func)(ViewDirTree *vdt, const gchar *path, gpointer data);
451 gpointer select_data;
453 LayoutWindow *layout;
470 SortType sort_method;
481 ThumbLoader *thumbs_loader;
482 FileData *thumbs_filedata;
485 void (*func_thumb_status)(ViewFileList *vfl, gdouble val, const gchar *text, gpointer data);
486 gpointer data_thumb_status;
488 void (*func_status)(ViewFileList *vfl, gpointer data);
489 gpointer data_status;
492 LayoutWindow *layout;
511 FileData *prev_selection;
513 GtkWidget *tip_window;
523 SortType sort_method;
535 ThumbLoader *thumbs_loader;
539 void (*func_thumb_status)(ViewFileIcon *vfi, gdouble val, const gchar *text, gpointer data);
540 gpointer data_thumb_status;
542 void (*func_status)(ViewFileIcon *vfi, gpointer data);
543 gpointer data_status;
545 LayoutWindow *layout;
550 struct _SlideShowData
557 LayoutWindow *layout;
569 void (*stop_func)(SlideShowData *, gpointer);
575 struct _FullScreenData
580 GtkWidget *normal_window;
581 ImageWindow *normal_imd;
589 void (*stop_func)(FullScreenData *, gpointer);
593 struct _PixmapFolders