Mercurial > geeqie.yaz
annotate src/typedefs.h @ 321:20d9b3cd7434
options_c -> c_options
author | zas_ |
---|---|
date | Fri, 11 Apr 2008 23:01:00 +0000 |
parents | c74af1cbd61a |
children | d344bcf37618 |
rev | line source |
---|---|
9 | 1 /* |
196 | 2 * Geeqie |
115
53b2bfdcff69
Tue Nov 28 11:54:30 2006 John Ellis <johne@verizon.net>
gqview
parents:
113
diff
changeset
|
3 * (C) 2006 John Ellis |
9 | 4 * |
5 * Author: John Ellis | |
6 * | |
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! | |
10 */ | |
11 | |
12 | |
13 #ifndef TYPEDEFS_H | |
14 #define TYPEDEFS_H | |
15 | |
134
9009856628f7
started implementation of external commands; external Delete should work
nadvornik
parents:
132
diff
changeset
|
16 typedef enum { |
283 | 17 CMD_COPY = GQ_EDITOR_GENERIC_SLOTS, |
134
9009856628f7
started implementation of external commands; external Delete should work
nadvornik
parents:
132
diff
changeset
|
18 CMD_MOVE, |
9009856628f7
started implementation of external commands; external Delete should work
nadvornik
parents:
132
diff
changeset
|
19 CMD_RENAME, |
9009856628f7
started implementation of external commands; external Delete should work
nadvornik
parents:
132
diff
changeset
|
20 CMD_DELETE, |
9009856628f7
started implementation of external commands; external Delete should work
nadvornik
parents:
132
diff
changeset
|
21 CMD_FOLDER, |
283 | 22 GQ_EDITOR_SLOTS |
134
9009856628f7
started implementation of external commands; external Delete should work
nadvornik
parents:
132
diff
changeset
|
23 } SpecialEditor; |
9 | 24 |
25 typedef enum { | |
26 SORT_NONE, | |
27 SORT_NAME, | |
28 SORT_SIZE, | |
29 SORT_TIME, | |
30 SORT_PATH, | |
31 SORT_NUMBER | |
32 } SortType; | |
33 | |
34 typedef enum { | |
35 ALTER_NONE, /* do nothing */ | |
36 ALTER_ROTATE_90, | |
37 ALTER_ROTATE_90_CC, /* counterclockwise */ | |
38 ALTER_ROTATE_180, | |
39 ALTER_MIRROR, | |
82
a4c1b7014e6e
Thu Oct 19 15:20:51 2006 John Ellis <johne@verizon.net>
gqview
parents:
41
diff
changeset
|
40 ALTER_FLIP, |
a4c1b7014e6e
Thu Oct 19 15:20:51 2006 John Ellis <johne@verizon.net>
gqview
parents:
41
diff
changeset
|
41 ALTER_DESATURATE |
9 | 42 } AlterType; |
43 | |
44 typedef enum { | |
45 LAYOUT_HIDE = 0, | |
46 LAYOUT_LEFT = 1 << 0, | |
47 LAYOUT_RIGHT = 1 << 1, | |
48 LAYOUT_TOP = 1 << 2, | |
49 LAYOUT_BOTTOM = 1 << 3 | |
50 } LayoutLocation; | |
51 | |
52 | |
113
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
53 typedef enum { |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
54 IMAGE_STATE_NONE = 0, |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
55 IMAGE_STATE_IMAGE = 1 << 0, |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
56 IMAGE_STATE_LOADING = 1 << 1, |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
57 IMAGE_STATE_ERROR = 1 << 2, |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
58 IMAGE_STATE_COLOR_ADJ = 1 << 3, |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
59 IMAGE_STATE_ROTATE_AUTO = 1 << 4, |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
60 IMAGE_STATE_ROTATE_USER = 1 << 5, |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
61 IMAGE_STATE_DELAY_FLIP = 1 << 6 |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
62 } ImageState; |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
63 |
127 | 64 typedef enum { |
65 SPLIT_NONE = 0, | |
66 SPLIT_VERT, | |
67 SPLIT_HOR, | |
68 SPLIT_QUAD, | |
69 } ImageSplitMode; | |
70 | |
143
0d1bf3ac6cd8
improved FileDataChangeInfo structure, check for another file operation in progress
nadvornik
parents:
141
diff
changeset
|
71 typedef enum { |
0d1bf3ac6cd8
improved FileDataChangeInfo structure, check for another file operation in progress
nadvornik
parents:
141
diff
changeset
|
72 FILEDATA_CHANGE_DELETE, |
0d1bf3ac6cd8
improved FileDataChangeInfo structure, check for another file operation in progress
nadvornik
parents:
141
diff
changeset
|
73 FILEDATA_CHANGE_MOVE, |
0d1bf3ac6cd8
improved FileDataChangeInfo structure, check for another file operation in progress
nadvornik
parents:
141
diff
changeset
|
74 FILEDATA_CHANGE_RENAME, |
0d1bf3ac6cd8
improved FileDataChangeInfo structure, check for another file operation in progress
nadvornik
parents:
141
diff
changeset
|
75 FILEDATA_CHANGE_COPY |
0d1bf3ac6cd8
improved FileDataChangeInfo structure, check for another file operation in progress
nadvornik
parents:
141
diff
changeset
|
76 } FileDataChangeType; |
0d1bf3ac6cd8
improved FileDataChangeInfo structure, check for another file operation in progress
nadvornik
parents:
141
diff
changeset
|
77 |
161 | 78 typedef enum { |
79 MTS_MODE_MINUS, | |
80 MTS_MODE_SET, | |
81 MTS_MODE_OR, | |
82 MTS_MODE_AND | |
83 } MarkToSelectionMode; | |
84 | |
85 typedef enum { | |
86 STM_MODE_RESET, | |
87 STM_MODE_SET, | |
88 STM_MODE_TOGGLE | |
89 } SelectionToMarkMode; | |
90 | |
212
c7021159079d
differentiate among normal image, raw image and metadata
nadvornik
parents:
196
diff
changeset
|
91 typedef enum { |
c7021159079d
differentiate among normal image, raw image and metadata
nadvornik
parents:
196
diff
changeset
|
92 FORMAT_CLASS_UNKNOWN, |
c7021159079d
differentiate among normal image, raw image and metadata
nadvornik
parents:
196
diff
changeset
|
93 FORMAT_CLASS_IMAGE, |
c7021159079d
differentiate among normal image, raw image and metadata
nadvornik
parents:
196
diff
changeset
|
94 FORMAT_CLASS_RAWIMAGE, |
c7021159079d
differentiate among normal image, raw image and metadata
nadvornik
parents:
196
diff
changeset
|
95 FORMAT_CLASS_META, |
c7021159079d
differentiate among normal image, raw image and metadata
nadvornik
parents:
196
diff
changeset
|
96 FILE_FORMAT_CLASSES |
c7021159079d
differentiate among normal image, raw image and metadata
nadvornik
parents:
196
diff
changeset
|
97 } FileFormatClass; |
c7021159079d
differentiate among normal image, raw image and metadata
nadvornik
parents:
196
diff
changeset
|
98 |
276 | 99 typedef enum { |
100 SS_ERR_NONE = 0, | |
101 SS_ERR_DISABLED, /**< secsave is disabled. */ | |
102 SS_ERR_OUT_OF_MEM, /**< memory allocation failure */ | |
103 | |
104 /* see err field in SecureSaveInfo */ | |
105 SS_ERR_OPEN_READ, | |
106 SS_ERR_OPEN_WRITE, | |
107 SS_ERR_STAT, | |
108 SS_ERR_ACCESS, | |
109 SS_ERR_MKSTEMP, | |
110 SS_ERR_RENAME, | |
111 SS_ERR_OTHER, | |
112 } SecureSaveErrno; | |
113 | |
143
0d1bf3ac6cd8
improved FileDataChangeInfo structure, check for another file operation in progress
nadvornik
parents:
141
diff
changeset
|
114 |
127 | 115 #define MAX_SPLIT_IMAGES 4 |
116 | |
9 | 117 typedef struct _ImageLoader ImageLoader; |
118 typedef struct _ThumbLoader ThumbLoader; | |
119 | |
120 typedef struct _CollectInfo CollectInfo; | |
121 typedef struct _CollectionData CollectionData; | |
122 typedef struct _CollectTable CollectTable; | |
123 typedef struct _CollectWindow CollectWindow; | |
124 | |
125 typedef struct _ImageWindow ImageWindow; | |
126 | |
127 typedef struct _FileData FileData; | |
138 | 128 typedef struct _FileDataChangeInfo FileDataChangeInfo; |
9 | 129 |
130 typedef struct _LayoutWindow LayoutWindow; | |
131 typedef struct _ViewDirList ViewDirList; | |
132 typedef struct _ViewDirTree ViewDirTree; | |
133 typedef struct _ViewFileList ViewFileList; | |
134 typedef struct _ViewFileIcon ViewFileIcon; | |
135 | |
136 typedef struct _SlideShowData SlideShowData; | |
137 typedef struct _FullScreenData FullScreenData; | |
138 | |
139 typedef struct _PixmapFolders PixmapFolders; | |
273
e0e2c2b72c5a
reworked the histogram patch by Uwe Ohse, most of the code is in
nadvornik
parents:
212
diff
changeset
|
140 typedef struct _Histogram Histogram; |
e0e2c2b72c5a
reworked the histogram patch by Uwe Ohse, most of the code is in
nadvornik
parents:
212
diff
changeset
|
141 |
276 | 142 typedef struct _SecureSaveInfo SecureSaveInfo; |
9 | 143 |
318 | 144 typedef struct _ConfOptions ConfOptions; |
9 | 145 |
146 struct _ImageLoader | |
147 { | |
148 GdkPixbuf *pixbuf; | |
138 | 149 FileData *fd; |
9 | 150 gchar *path; |
151 | |
152 gint bytes_read; | |
153 gint bytes_total; | |
154 | |
155 guint buffer_size; | |
156 | |
157 gint requested_width; | |
158 gint requested_height; | |
14
25335c62cd9b
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
12
diff
changeset
|
159 gint shrunk; |
9 | 160 |
161 gint done; | |
162 gint idle_id; | |
163 gint idle_priority; | |
164 | |
165 GdkPixbufLoader *loader; | |
166 gint load_fd; | |
167 | |
168 void (*func_area_ready)(ImageLoader *, guint x, guint y, guint w, guint h, gpointer); | |
169 void (*func_error)(ImageLoader *, gpointer); | |
170 void (*func_done)(ImageLoader *, gpointer); | |
171 void (*func_percent)(ImageLoader *, gdouble, gpointer); | |
172 | |
173 gpointer data_area_ready; | |
174 gpointer data_error; | |
175 gpointer data_done; | |
176 gpointer data_percent; | |
177 | |
178 gint idle_done_id; | |
179 }; | |
180 | |
181 typedef void (* ThumbLoaderFunc)(ThumbLoader *tl, gpointer data); | |
182 | |
183 struct _ThumbLoader | |
184 { | |
185 gint standard_loader; | |
186 | |
187 GdkPixbuf *pixbuf; /* contains final (scaled) image when done */ | |
188 ImageLoader *il; | |
189 gchar *path; | |
190 | |
191 gint cache_enable; | |
192 gint cache_hit; | |
193 gdouble percent_done; | |
194 | |
195 gint max_w; | |
196 gint max_h; | |
197 | |
198 ThumbLoaderFunc func_done; | |
199 ThumbLoaderFunc func_error; | |
200 ThumbLoaderFunc func_progress; | |
201 | |
202 gpointer data; | |
203 | |
204 gint idle_done_id; | |
205 }; | |
206 | |
207 struct _CollectInfo | |
208 { | |
138 | 209 FileData *fd; |
9 | 210 GdkPixbuf *pixbuf; |
211 gint flag_mask; | |
212 }; | |
213 | |
214 struct _CollectionData | |
215 { | |
216 gchar *path; | |
217 gchar *name; | |
218 GList *list; | |
219 SortType sort_method; | |
220 | |
221 ThumbLoader *thumb_loader; | |
222 CollectInfo *thumb_info; | |
223 | |
224 void (*info_updated_func)(CollectionData *, CollectInfo *, gpointer); | |
225 gpointer info_updated_data; | |
226 | |
227 gint ref; | |
228 | |
229 /* geometry */ | |
230 gint window_read; | |
231 gint window_x; | |
232 gint window_y; | |
233 gint window_w; | |
234 gint window_h; | |
235 | |
236 /* contents changed since save flag */ | |
237 gint changed; | |
303
6ff0bc50ac46
Prevent multiple insertion of the same file in a collection.
zas_
parents:
290
diff
changeset
|
238 |
6ff0bc50ac46
Prevent multiple insertion of the same file in a collection.
zas_
parents:
290
diff
changeset
|
239 GHashTable *existence; |
9 | 240 }; |
241 | |
242 struct _CollectTable | |
243 { | |
244 GtkWidget *scrolled; | |
245 GtkWidget *listview; | |
246 gint columns; | |
247 gint rows; | |
248 | |
249 CollectionData *cd; | |
250 | |
251 GList *selection; | |
252 CollectInfo *prev_selection; | |
253 | |
254 CollectInfo *click_info; | |
255 | |
256 GtkWidget *tip_window; | |
257 gint tip_delay_id; | |
258 CollectInfo *tip_info; | |
259 | |
260 GdkWindow *marker_window; | |
261 CollectInfo *marker_info; | |
262 | |
263 GtkWidget *status_label; | |
264 GtkWidget *extra_label; | |
265 | |
266 gint focus_row; | |
267 gint focus_column; | |
268 CollectInfo *focus_info; | |
269 | |
270 GtkWidget *popup; | |
271 CollectInfo *drop_info; | |
272 GList *drop_list; | |
273 | |
274 gint sync_idle_id; | |
275 gint drop_idle_id; | |
276 | |
277 gint show_text; | |
278 }; | |
279 | |
280 struct _CollectWindow | |
281 { | |
282 GtkWidget *window; | |
283 CollectTable *table; | |
284 GtkWidget *status_box; | |
285 GList *list; | |
286 | |
287 GtkWidget *close_dialog; | |
288 | |
289 CollectionData *cd; | |
290 }; | |
291 | |
12
147f4c4b9025
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
9
diff
changeset
|
292 typedef gint (* ImageTileRequestFunc)(ImageWindow *imd, gint x, gint y, |
147f4c4b9025
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
9
diff
changeset
|
293 gint width, gint height, GdkPixbuf *pixbuf, gpointer); |
147f4c4b9025
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
9
diff
changeset
|
294 typedef void (* ImageTileDisposeFunc)(ImageWindow *imd, gint x, gint y, |
147f4c4b9025
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
9
diff
changeset
|
295 gint width, gint height, GdkPixbuf *pixbuf, gpointer); |
147f4c4b9025
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
9
diff
changeset
|
296 |
9 | 297 struct _ImageWindow |
298 { | |
299 GtkWidget *widget; /* use this to add it and show it */ | |
23
17acca639a86
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
14
diff
changeset
|
300 GtkWidget *pr; |
17acca639a86
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
14
diff
changeset
|
301 GtkWidget *frame; |
9 | 302 |
138 | 303 FileData *image_fd; |
9 | 304 |
305 gint64 size; /* file size (bytes) */ | |
306 time_t mtime; /* file modified time stamp */ | |
307 gint unknown; /* failed to load image */ | |
308 | |
309 ImageLoader *il; | |
310 | |
311 gint has_frame; | |
312 | |
313 /* top level (not necessarily parent) window */ | |
23
17acca639a86
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
14
diff
changeset
|
314 gint top_window_sync; /* resize top_window when image dimensions change */ |
9 | 315 GtkWidget *top_window; /* window that gets title, and window to resize when 'fitting' */ |
316 gchar *title; /* window title to display left of file name */ | |
317 gchar *title_right; /* window title to display right of file name */ | |
318 gint title_show_zoom; /* option to include zoom in window title */ | |
319 | |
320 gint completed; | |
113
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
321 ImageState state; /* mask of IMAGE_STATE_* flags about current image */ |
9 | 322 |
117
0c2e1f0a001b
Wed Nov 29 14:28:30 2006 John Ellis <johne@verizon.net>
gqview
parents:
115
diff
changeset
|
323 void (*func_update)(ImageWindow *imd, gpointer data); |
0c2e1f0a001b
Wed Nov 29 14:28:30 2006 John Ellis <johne@verizon.net>
gqview
parents:
115
diff
changeset
|
324 void (*func_complete)(ImageWindow *imd, gint preload, gpointer data); |
0c2e1f0a001b
Wed Nov 29 14:28:30 2006 John Ellis <johne@verizon.net>
gqview
parents:
115
diff
changeset
|
325 void (*func_state)(ImageWindow *imd, ImageState state, gpointer data); |
12
147f4c4b9025
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
9
diff
changeset
|
326 ImageTileRequestFunc func_tile_request; |
147f4c4b9025
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
9
diff
changeset
|
327 ImageTileDisposeFunc func_tile_dispose; |
9 | 328 |
329 gpointer data_update; | |
330 gpointer data_complete; | |
117
0c2e1f0a001b
Wed Nov 29 14:28:30 2006 John Ellis <johne@verizon.net>
gqview
parents:
115
diff
changeset
|
331 gpointer data_state; |
12
147f4c4b9025
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
9
diff
changeset
|
332 gpointer data_tile; |
9 | 333 |
334 /* button, scroll functions */ | |
335 void (*func_button)(ImageWindow *, gint button, | |
336 guint32 time, gdouble x, gdouble y, guint state, gpointer); | |
128
98e2632b5d3d
improved connected scroll and active image switching
nadvornik
parents:
127
diff
changeset
|
337 void (*func_drag)(ImageWindow *, gint button, |
98e2632b5d3d
improved connected scroll and active image switching
nadvornik
parents:
127
diff
changeset
|
338 guint32 time, gdouble x, gdouble y, guint state, gdouble dx, gdouble dy,gpointer); |
9 | 339 void (*func_scroll)(ImageWindow *, GdkScrollDirection direction, |
340 guint32 time, gdouble x, gdouble y, guint state, gpointer); | |
341 | |
342 gpointer data_button; | |
128
98e2632b5d3d
improved connected scroll and active image switching
nadvornik
parents:
127
diff
changeset
|
343 gpointer data_drag; |
9 | 344 gpointer data_scroll; |
345 | |
12
147f4c4b9025
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
9
diff
changeset
|
346 /* scroll notification (for scroll bar implementation) */ |
147f4c4b9025
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
9
diff
changeset
|
347 void (*func_scroll_notify)(ImageWindow *, gint x, gint y, gint width, gint height, gpointer); |
147f4c4b9025
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
9
diff
changeset
|
348 |
147f4c4b9025
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
9
diff
changeset
|
349 gpointer data_scroll_notify; |
147f4c4b9025
##### Note: GQview CVS on sourceforge is not always up to date, please use #####
gqview
parents:
9
diff
changeset
|
350 |
9 | 351 /* collection info */ |
352 CollectionData *collection; | |
353 CollectInfo *collection_info; | |
354 | |
113
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
355 /* color profiles */ |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
356 gint color_profile_enable; |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
357 gint color_profile_input; |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
358 gint color_profile_screen; |
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
359 gint color_profile_use_image; |
115
53b2bfdcff69
Tue Nov 28 11:54:30 2006 John Ellis <johne@verizon.net>
gqview
parents:
113
diff
changeset
|
360 gpointer cm; |
113
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
361 |
9 | 362 AlterType delay_alter_type; |
363 | |
364 ImageLoader *read_ahead_il; | |
365 GdkPixbuf *read_ahead_pixbuf; | |
138 | 366 FileData *read_ahead_fd; |
9 | 367 |
368 GdkPixbuf *prev_pixbuf; | |
138 | 369 FileData *prev_fd; |
113
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
370 gint prev_color_row; |
9 | 371 |
372 gint auto_refresh_id; | |
373 gint auto_refresh_interval; | |
374 | |
375 gint delay_flip; | |
376 }; | |
377 | |
149 | 378 #define FILEDATA_MARKS_SIZE 6 |
132 | 379 |
138 | 380 struct _FileDataChangeInfo { |
143
0d1bf3ac6cd8
improved FileDataChangeInfo structure, check for another file operation in progress
nadvornik
parents:
141
diff
changeset
|
381 FileDataChangeType type; |
138 | 382 gchar *source; |
383 gchar *dest; | |
384 }; | |
137
be3328a58875
started support for sidecar files like xmp, raw+jpeg etc.
nadvornik
parents:
134
diff
changeset
|
385 |
be3328a58875
started support for sidecar files like xmp, raw+jpeg etc.
nadvornik
parents:
134
diff
changeset
|
386 struct _FileData { |
138 | 387 gint magick; |
137
be3328a58875
started support for sidecar files like xmp, raw+jpeg etc.
nadvornik
parents:
134
diff
changeset
|
388 gint type; |
138 | 389 gchar *original_path; /* key to file_data_pool hash table */ |
137
be3328a58875
started support for sidecar files like xmp, raw+jpeg etc.
nadvornik
parents:
134
diff
changeset
|
390 gchar *path; |
be3328a58875
started support for sidecar files like xmp, raw+jpeg etc.
nadvornik
parents:
134
diff
changeset
|
391 const gchar *name; |
be3328a58875
started support for sidecar files like xmp, raw+jpeg etc.
nadvornik
parents:
134
diff
changeset
|
392 const gchar *extension; |
be3328a58875
started support for sidecar files like xmp, raw+jpeg etc.
nadvornik
parents:
134
diff
changeset
|
393 gint64 size; |
be3328a58875
started support for sidecar files like xmp, raw+jpeg etc.
nadvornik
parents:
134
diff
changeset
|
394 time_t date; |
be3328a58875
started support for sidecar files like xmp, raw+jpeg etc.
nadvornik
parents:
134
diff
changeset
|
395 gboolean marks[FILEDATA_MARKS_SIZE]; |
be3328a58875
started support for sidecar files like xmp, raw+jpeg etc.
nadvornik
parents:
134
diff
changeset
|
396 GList *sidecar_files; |
141 | 397 FileData *parent; /* parent file if this is a sidecar file, NULL otherwise */ |
138 | 398 FileDataChangeInfo *change; /* for rename, move ... */ |
9 | 399 GdkPixbuf *pixbuf; |
138 | 400 gint ref; |
9 | 401 }; |
402 | |
403 struct _LayoutWindow | |
404 { | |
405 gchar *path; | |
406 | |
407 /* base */ | |
408 | |
409 GtkWidget *window; | |
410 | |
411 GtkWidget *main_box; | |
412 | |
413 GtkWidget *group_box; | |
414 GtkWidget *h_pane; | |
415 GtkWidget *v_pane; | |
416 | |
417 /* menus, path selector */ | |
418 | |
419 GtkActionGroup *action_group; | |
420 GtkUIManager *ui_manager; | |
421 | |
422 GtkWidget *path_entry; | |
423 | |
424 /* image */ | |
425 | |
426 LayoutLocation image_location; | |
427 | |
428 ImageWindow *image; | |
429 | |
127 | 430 ImageWindow *split_images[MAX_SPLIT_IMAGES]; |
431 ImageSplitMode split_mode; | |
432 gint active_split_image; | |
433 | |
434 GtkWidget *split_image_widget; | |
435 | |
436 gint connect_zoom, connect_scroll; | |
437 | |
9 | 438 /* tools window (float) */ |
439 | |
440 GtkWidget *tools; | |
441 GtkWidget *tools_pane; | |
442 | |
443 gint tools_float; | |
444 gint tools_hidden; | |
445 | |
446 /* toolbar */ | |
447 | |
448 GtkWidget *toolbar; | |
449 gint toolbar_hidden; | |
450 | |
451 GtkWidget *thumb_button; | |
452 gint thumbs_enabled; | |
137
be3328a58875
started support for sidecar files like xmp, raw+jpeg etc.
nadvornik
parents:
134
diff
changeset
|
453 gint marks_enabled; |
132 | 454 |
9 | 455 /* dir view */ |
456 | |
457 LayoutLocation dir_location; | |
458 | |
459 ViewDirList *vdl; | |
460 ViewDirTree *vdt; | |
461 GtkWidget *dir_view; | |
462 | |
463 gint tree_view; | |
464 | |
465 /* file view */ | |
466 | |
467 LayoutLocation file_location; | |
468 | |
469 ViewFileList *vfl; | |
470 ViewFileIcon *vfi; | |
471 GtkWidget *file_view; | |
472 | |
473 gint icon_view; | |
474 SortType sort_method; | |
475 gint sort_ascend; | |
476 | |
477 /* status bar */ | |
478 | |
479 GtkWidget *info_box; | |
480 GtkWidget *info_progress_bar; | |
481 GtkWidget *info_sort; | |
113
55166d93498d
Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net>
gqview
parents:
82
diff
changeset
|
482 GtkWidget *info_color; |
9 | 483 GtkWidget *info_status; |
484 GtkWidget *info_details; | |
485 GtkWidget *info_zoom; | |
486 | |
487 /* slide show */ | |
488 | |
489 SlideShowData *slideshow; | |
490 | |
491 /* full screen */ | |
492 | |
493 FullScreenData *full_screen; | |
494 | |
495 /* dividers */ | |
496 | |
497 gint div_h; | |
498 gint div_v; | |
499 gint div_float; | |
500 | |
501 /* directory update check */ | |
502 | |
503 gint last_time_id; | |
504 time_t last_time; | |
505 | |
506 /* misc */ | |
507 | |
508 GtkWidget *utility_box; | |
509 GtkWidget *bar_sort; | |
510 GtkWidget *bar_exif; | |
511 GtkWidget *bar_info; | |
512 | |
273
e0e2c2b72c5a
reworked the histogram patch by Uwe Ohse, most of the code is in
nadvornik
parents:
212
diff
changeset
|
513 gint histogram_enabled; |
e0e2c2b72c5a
reworked the histogram patch by Uwe Ohse, most of the code is in
nadvornik
parents:
212
diff
changeset
|
514 Histogram *histogram; |
e0e2c2b72c5a
reworked the histogram patch by Uwe Ohse, most of the code is in
nadvornik
parents:
212
diff
changeset
|
515 |
9 | 516 gint bar_sort_enabled; |
517 gint bar_exif_enabled; | |
518 gint bar_info_enabled; | |
519 | |
520 gint bar_exif_size; | |
521 gint bar_exif_advanced; | |
522 }; | |
523 | |
524 struct _ViewDirList | |
525 { | |
526 GtkWidget *widget; | |
527 GtkWidget *listview; | |
528 | |
529 gchar *path; | |
530 GList *list; | |
531 | |
532 FileData *click_fd; | |
533 | |
534 FileData *drop_fd; | |
535 GList *drop_list; | |
536 | |
537 gint drop_scroll_id; | |
538 | |
539 /* func list */ | |
540 void (*select_func)(ViewDirList *vdl, const gchar *path, gpointer data); | |
541 gpointer select_data; | |
542 | |
543 LayoutWindow *layout; | |
544 | |
545 GtkWidget *popup; | |
546 | |
547 PixmapFolders *pf; | |
548 }; | |
549 | |
550 struct _ViewDirTree | |
551 { | |
552 GtkWidget *widget; | |
553 GtkWidget *treeview; | |
554 | |
555 gchar *path; | |
556 | |
557 FileData *click_fd; | |
558 | |
559 FileData *drop_fd; | |
560 GList *drop_list; | |
561 | |
562 gint drop_scroll_id; | |
563 gint drop_expand_id; | |
564 | |
565 /* func list */ | |
566 void (*select_func)(ViewDirTree *vdt, const gchar *path, gpointer data); | |
567 gpointer select_data; | |
568 | |
569 LayoutWindow *layout; | |
570 | |
571 GtkWidget *popup; | |
572 | |
573 PixmapFolders *pf; | |
574 | |
575 gint busy_ref; | |
576 }; | |
577 | |
578 struct _ViewFileList | |
579 { | |
580 GtkWidget *widget; | |
581 GtkWidget *listview; | |
582 | |
583 gchar *path; | |
584 GList *list; | |
585 | |
586 SortType sort_method; | |
587 gint sort_ascend; | |
588 | |
589 FileData *click_fd; | |
590 FileData *select_fd; | |
591 | |
592 gint thumbs_enabled; | |
138 | 593 gint marks_enabled; |
150 | 594 gint active_mark; |
132 | 595 |
9 | 596 /* thumb updates */ |
597 gint thumbs_running; | |
598 gint thumbs_count; | |
599 ThumbLoader *thumbs_loader; | |
600 FileData *thumbs_filedata; | |
601 | |
602 /* func list */ | |
603 void (*func_thumb_status)(ViewFileList *vfl, gdouble val, const gchar *text, gpointer data); | |
604 gpointer data_thumb_status; | |
605 | |
606 void (*func_status)(ViewFileList *vfl, gpointer data); | |
607 gpointer data_status; | |
608 | |
609 gint select_idle_id; | |
610 LayoutWindow *layout; | |
611 | |
612 GtkWidget *popup; | |
613 }; | |
614 | |
138 | 615 struct _IconData; |
616 | |
9 | 617 struct _ViewFileIcon |
618 { | |
619 GtkWidget *widget; | |
620 GtkWidget *listview; | |
621 | |
622 gchar *path; | |
623 GList *list; | |
624 | |
625 /* table stuff */ | |
626 | |
627 gint columns; | |
628 gint rows; | |
629 | |
630 GList *selection; | |
138 | 631 struct _IconData *prev_selection; |
9 | 632 |
633 GtkWidget *tip_window; | |
634 gint tip_delay_id; | |
138 | 635 struct _IconData *tip_id; |
9 | 636 |
138 | 637 struct _IconData *click_id; |
9 | 638 |
138 | 639 struct _IconData *focus_id; |
9 | 640 gint focus_row; |
641 gint focus_column; | |
642 | |
643 SortType sort_method; | |
644 gint sort_ascend; | |
645 | |
646 gint show_text; | |
647 | |
648 gint sync_idle_id; | |
649 | |
650 /* thumbs */ | |
651 | |
652 gint thumbs_running; | |
653 GList *thumbs_list; | |
654 gint thumbs_count; | |
655 ThumbLoader *thumbs_loader; | |
656 FileData *thumbs_fd; | |
657 | |
658 /* func list */ | |
659 void (*func_thumb_status)(ViewFileIcon *vfi, gdouble val, const gchar *text, gpointer data); | |
660 gpointer data_thumb_status; | |
661 | |
662 void (*func_status)(ViewFileIcon *vfi, gpointer data); | |
663 gpointer data_status; | |
664 | |
665 LayoutWindow *layout; | |
666 | |
667 GtkWidget *popup; | |
668 }; | |
669 | |
670 struct _SlideShowData | |
671 { | |
672 ImageWindow *imd; | |
673 | |
138 | 674 GList *filelist; |
9 | 675 CollectionData *cd; |
676 gchar *layout_path; | |
677 LayoutWindow *layout; | |
678 | |
679 GList *list; | |
680 GList *list_done; | |
681 | |
138 | 682 FileData *slide_fd; |
9 | 683 |
684 gint slide_count; | |
685 gint timeout_id; | |
686 | |
687 gint from_selection; | |
688 | |
689 void (*stop_func)(SlideShowData *, gpointer); | |
690 gpointer stop_data; | |
691 | |
692 gint paused; | |
693 }; | |
694 | |
695 struct _FullScreenData | |
696 { | |
697 GtkWidget *window; | |
698 ImageWindow *imd; | |
699 | |
700 GtkWidget *normal_window; | |
701 ImageWindow *normal_imd; | |
702 | |
703 gint hide_mouse_id; | |
704 gint busy_mouse_id; | |
705 gint cursor_state; | |
706 | |
707 gint saver_block_id; | |
708 | |
709 void (*stop_func)(FullScreenData *, gpointer); | |
710 gpointer stop_data; | |
711 }; | |
712 | |
713 struct _PixmapFolders | |
714 { | |
715 GdkPixbuf *close; | |
716 GdkPixbuf *open; | |
717 GdkPixbuf *deny; | |
718 GdkPixbuf *parent; | |
719 }; | |
720 | |
276 | 721 struct _SecureSaveInfo { |
722 FILE *fp; /**< file stream pointer */ | |
723 gchar *file_name; /**< final file name */ | |
724 gchar *tmp_file_name; /**< temporary file name */ | |
725 gint err; /**< set to non-zero value in case of error */ | |
313
a955b7fd626b
Secure save now unlinks temporary file on error by default.
zas_
parents:
311
diff
changeset
|
726 gint secure_save; /**< use secure save for this file, internal use only */ |
a955b7fd626b
Secure save now unlinks temporary file on error by default.
zas_
parents:
311
diff
changeset
|
727 gint preserve_perms; /**< whether to preserve perms, TRUE by default */ |
a955b7fd626b
Secure save now unlinks temporary file on error by default.
zas_
parents:
311
diff
changeset
|
728 gint preserve_mtime; /**< whether to preserve mtime, FALSE by default */ |
a955b7fd626b
Secure save now unlinks temporary file on error by default.
zas_
parents:
311
diff
changeset
|
729 gint unlink_on_error; /**< whether to remove temporary file on save failure, TRUE by default */ |
276 | 730 }; |
731 | |
318 | 732 struct _ConfOptions |
733 { | |
734 gint main_window_w; | |
735 gint main_window_h; | |
736 gint main_window_x; | |
737 gint main_window_y; | |
738 gint main_window_maximized; | |
739 | |
740 gint float_window_w; | |
741 gint float_window_h; | |
742 gint float_window_x; | |
743 gint float_window_y; | |
744 gint float_window_divider; | |
745 | |
746 gint window_hdivider_pos; | |
747 gint window_vdivider_pos; | |
748 | |
749 gint save_window_positions; | |
750 gint tools_float; | |
751 gint tools_hidden; | |
752 gint toolbar_hidden; | |
753 gint progressive_key_scrolling; | |
754 | |
755 gint startup_path_enable; | |
756 gchar *startup_path; | |
757 gint confirm_delete; | |
758 gint enable_delete_key; | |
759 gint safe_delete_enable; | |
760 gchar *safe_delete_path; | |
761 gint safe_delete_size; | |
762 gint restore_tool; | |
763 gint zoom_mode; | |
764 gint two_pass_zoom; | |
765 gint scroll_reset_method; | |
766 gint fit_window; | |
767 gint limit_window_size; | |
768 gint zoom_to_fit_expands; | |
769 gint max_window_size; | |
770 gint limit_autofit_size; | |
771 gint max_autofit_size; | |
772 gint thumb_max_width; | |
773 gint thumb_max_height; | |
774 gint enable_thumb_caching; | |
775 gint enable_thumb_dirs; | |
776 gint thumbnail_fast; | |
777 gint use_xvpics_thumbnails; | |
778 gint thumbnail_spec_standard; | |
779 gint enable_metadata_dirs; | |
780 gint show_dot_files; | |
781 gint file_filter_disable; | |
782 gchar *editor_name[GQ_EDITOR_SLOTS]; | |
783 gchar *editor_command[GQ_EDITOR_SLOTS]; | |
784 | |
785 gint thumbnails_enabled; | |
786 SortType file_sort_method; | |
787 gint file_sort_ascending; | |
788 | |
789 gint slideshow_delay; /* in tenths of a second */ | |
790 gint slideshow_random; | |
791 gint slideshow_repeat; | |
792 | |
793 gint mousewheel_scrolls; | |
794 gint enable_in_place_rename; | |
795 | |
796 gint user_specified_window_background; | |
797 GdkColor window_background_color; | |
798 | |
799 gint fullscreen_screen; | |
800 gint fullscreen_clean_flip; | |
801 gint fullscreen_disable_saver; | |
802 gint fullscreen_above; | |
803 gint show_fullscreen_info; | |
804 gchar *fullscreen_info; | |
805 | |
806 gint dupe_custom_threshold; | |
807 | |
808 gint recent_list_max; | |
809 | |
810 gint collection_rectangular_selection; | |
811 | |
812 gint tile_cache_max; /* in megabytes */ | |
813 gint thumbnail_quality; | |
814 gint zoom_quality; | |
815 gint dither_quality; | |
816 | |
817 gint zoom_increment; /* 10 is 1.0, 5 is 0.05, 20 is 2.0, etc. */ | |
818 | |
819 gint enable_read_ahead; | |
820 | |
821 gint place_dialogs_under_mouse; | |
319 | 822 |
823 gint file_sort_case_sensitive; /* file sorting method (case) */ | |
824 | |
320 | 825 /* layout */ |
826 gchar *layout_order; | |
827 gint layout_style; | |
828 | |
829 gint layout_view_icons; | |
830 gint layout_view_tree; | |
831 | |
832 gint show_icon_names; | |
833 | |
834 gint tree_descend_subdirs; | |
835 | |
836 gint lazy_image_sync; | |
837 gint update_on_time_change; | |
838 gint exif_rotate_enable; | |
839 | |
840 gint color_profile_enabled; | |
841 gint color_profile_input_type; | |
842 gchar *color_profile_input_file[COLOR_PROFILE_INPUTS]; | |
843 gchar *color_profile_input_name[COLOR_PROFILE_INPUTS]; | |
844 gint color_profile_screen_type; | |
845 gchar *color_profile_screen_file; | |
846 gint color_profile_use_image; | |
847 | |
848 GList *filename_filter; | |
318 | 849 }; |
9 | 850 |
851 #endif | |
852 | |
853 |