Save order of Properties dialog tabs to rc file.
[geeqie.git] / src / options.h
1 /*
2  * Geeqie
3  * Copyright (C) 2008 The Geeqie Team
4  *
5  * Authors: Vladimir Nadvornik, Laurent Monin
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 #ifndef OPTIONS_H
13 #define OPTIONS_H
14
15 typedef struct _ConfOptions ConfOptions;
16
17 struct _ConfOptions
18 {
19
20         /* ui */
21         gint progressive_key_scrolling;
22         gint place_dialogs_under_mouse;
23         gint mousewheel_scrolls;
24         gint show_icon_names;
25         gint show_copy_path;
26
27         /* various */
28         gint enable_metadata_dirs;
29
30         gint tree_descend_subdirs;
31
32         gint lazy_image_sync;
33         gint update_on_time_change;
34
35         gint duplicates_similarity_threshold;
36
37         gint open_recent_list_maxsize;
38         gint dnd_icon_size;
39
40         gint save_metadata_in_image_file;
41
42         struct {
43                 gboolean restore_path;
44                 gboolean use_last_path;
45                 gchar *path;
46         } startup;
47
48         /* file ops */
49         struct {
50                 gint enable_in_place_rename;
51
52                 gint confirm_delete;
53                 gint enable_delete_key;
54                 gint safe_delete_enable;
55                 gchar *safe_delete_path;
56                 gint safe_delete_folder_maxsize;
57         } file_ops;
58
59         /* image */
60         struct {
61                 gint exif_rotate_enable;
62                 gint scroll_reset_method;
63                 gint fit_window_to_image;
64                 gint limit_window_size;
65                 gint max_window_size;
66                 gint limit_autofit_size;
67                 gint max_autofit_size;
68
69                 gint tile_cache_max;    /* in megabytes */
70                 gint dither_quality;
71                 gint enable_read_ahead;
72
73                 gint zoom_mode;
74                 gint zoom_2pass;
75                 gint zoom_to_fit_allow_expand;
76                 gint zoom_quality;
77                 gint zoom_increment;    /* 10 is 1.0, 5 is 0.05, 20 is 2.0, etc. */
78
79                 gint use_custom_border_color;
80                 GdkColor border_color;
81
82                 gint read_buffer_size; /* bytes to read from file per read() */
83                 gint idle_read_loop_count; /* the number of bytes to read per idle call (define x image.read_buffer_size) */
84         } image;
85
86         /* thumbnails */
87         struct {
88                 gint max_width;
89                 gint max_height;
90                 gint enable_caching;
91                 gint cache_into_dirs;
92                 gint fast;
93                 gint use_xvpics;
94                 gint spec_standard;
95                 gint quality;
96         } thumbnails;
97
98         /* file filtering */
99         struct {
100                 gint show_hidden_files;
101                 gint show_dot_directory;
102                 gint disable;
103         } file_filter;
104
105         /* collections */
106         struct {
107                 gint rectangular_selection;
108         } collections;
109
110         /* editors */
111         gchar *editor_name[GQ_EDITOR_SLOTS];
112         gchar *editor_command[GQ_EDITOR_SLOTS];
113
114         /* file sorting */
115         struct {
116                 SortType method;
117                 gint ascending;
118                 gint case_sensitive; /* file sorting method (case) */
119         } file_sort;
120
121         /* slideshow */
122         struct {
123                 gint delay;     /* in tenths of a second */
124                 gint random;
125                 gint repeat;
126         } slideshow;
127
128         /* fullscreen */
129         struct {
130                 gint screen;
131                 gint clean_flip;
132                 gint disable_saver;
133                 gint above;
134         } fullscreen;
135
136         /* histogram */
137         struct {
138                 guint last_channel_mode;
139                 guint last_log_mode;
140         } histogram;
141         
142         /* image overlay */
143         struct {
144                 struct {
145                         guint state;
146                         gint show_at_startup;
147                         gchar *template_string;
148                 } common;
149         } image_overlay;
150
151         /* layout */
152         struct {
153                 gchar *order;
154                 gint style;
155
156                 DirViewType dir_view_type;
157                 FileViewType file_view_type;
158
159                 gint show_thumbnails;
160                 gint show_marks;
161
162                 struct {
163                         gint w;
164                         gint h;
165                         gint x;
166                         gint y;
167                         gint maximized;
168                         gint hdivider_pos;
169                         gint vdivider_pos;
170                 } main_window;
171
172                 struct {
173                         gint w;
174                         gint h;
175                         gint x;
176                         gint y;
177                         gint vdivider_pos;
178                 } float_window;
179
180                 gint save_window_positions;
181
182                 gint tools_float;
183                 gint tools_hidden;
184                 gint tools_restore_state;
185
186                 gint toolbar_hidden;
187
188         } layout;
189
190         /* panels */
191         struct {
192                 struct {
193                         gint enabled;
194                         gint width;
195                 } info;
196
197                 struct {
198                         gint enabled;
199                         gint width;
200                 } exif;
201
202                 struct {
203                         gint enabled;
204                         gint mode_state;
205                         gint action_state;
206                         gint selection_state;
207                 } sort;
208         } panels;
209
210         /* properties dialog */
211         struct {
212                 gchar *tabs_order;
213         } properties;
214
215         /* color profiles */
216         struct {
217                 gint enabled;
218                 gint input_type;
219                 gchar *input_file[COLOR_PROFILE_INPUTS];
220                 gchar *input_name[COLOR_PROFILE_INPUTS];
221                 gint screen_type;
222                 gchar *screen_file;
223                 gint use_image;
224
225         } color_profile;
226
227 };
228
229 ConfOptions *options;
230
231 ConfOptions *init_options(ConfOptions *options);
232
233 #endif /* OPTIONS_H */