2 * Sylpheed -- a GTK+ based, lightweight, and fast e-mail client
3 * Copyright (C) 1999-2005 Hiroyuki Yamamoto
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
20 #ifndef __PREFS_COMMON_H__
21 #define __PREFS_COMMON_H__
29 #include "mainwindow.h"
30 #include "summaryview.h"
31 #include "folderview.h"
36 typedef struct _PrefsCommon PrefsCommon;
49 } TransferEncodingMethod;
53 /* SEND_DIALOG_ACTIVE would be irrelevant */
59 SELECTONENTRY_UNREAD = 1 << 0,
60 SELECTONENTRY_NEW = 1 << 1
65 NEXTUNREADMSGDIALOG_ALWAYS,
66 NEXTUNREADMSGDIALOG_ASSUME_YES,
67 NEXTUNREADMSGDIALOG_ASSUME_NO
68 } NextUnreadMsgDialogShow;
75 gboolean scan_all_after_inc;
76 gboolean autochk_newmail;
78 gboolean chk_on_startup;
79 gboolean newmail_notify_auto;
80 gboolean newmail_notify_manu;
81 gchar *newmail_notify_cmd;
82 RecvDialogMode recv_dialog_mode;
83 gboolean close_recv_dialog;
84 gboolean no_recv_err_panel;
88 gboolean confirm_send_queued_messages;
89 SendDialogMode send_dialog_mode;
90 gchar *outgoing_charset;
91 TransferEncodingMethod encoding_method;
93 gboolean allow_jisx0201_kana;
98 gboolean linewrap_quote;
99 gboolean linewrap_pastes;
101 gboolean linewrap_at_send;
102 gboolean auto_exteditor;
103 gboolean reply_account_autosel;
104 gboolean default_reply_list;
105 gboolean forward_account_autosel;
106 gboolean reedit_account_autosel;
109 gint autosave_length;
112 gboolean reply_with_quote;
117 gboolean forward_as_attachment;
118 gboolean redirect_keep_from;
119 gboolean block_cursor;
123 gboolean enable_aspell;
126 gulong misspelled_col;
128 gboolean check_while_typing;
129 gboolean use_alternate;
134 gchar *widgetfont_gtk1;
135 gchar *textfont_gtk1;
136 gchar *normalfont_gtk1;
137 gchar *boldfont_gtk1;
138 gchar *smallfont_gtk1;
148 gboolean display_img;
153 gboolean display_folder_unread;
156 gboolean show_searchbar;
157 gboolean expand_thread;
159 gboolean use_addr_book;
162 gboolean enable_rules_hint;
163 gboolean enable_hscrollbar;
164 gboolean bold_unread;
165 gboolean enable_thread;
166 gboolean thread_by_subject;
167 gint thread_by_subject_max_age; /*!< Max. age of a thread which was threaded
168 * by subject (days) */
170 ToolbarStyle toolbar_style;
171 gboolean toolbar_detachable;
172 gboolean show_statusbar;
174 gint folderview_vscrollbar_policy;
180 gint important_score;
183 GSList *actions_list;
185 /* Summary columns visibility, position and size */
186 gboolean summary_col_visible[N_SUMMARY_COLS];
187 gint summary_col_pos[N_SUMMARY_COLS];
188 gint summary_col_size[N_SUMMARY_COLS];
190 gboolean folder_col_visible[N_FOLDER_COLS];
191 gint folder_col_pos[N_FOLDER_COLS];
192 gint folder_col_size[N_FOLDER_COLS];
194 /* Widget visibility, position and size */
197 gint folderview_width;
198 gint folderview_height;
199 gboolean folderview_visible;
201 gint summaryview_width;
202 gint summaryview_height;
208 gboolean msgview_visible;
213 gint mainview_height;
222 gint sourcewin_width;
223 gint sourcewin_height;
231 gboolean enable_color;
232 gulong quote_level1_col;
233 gulong quote_level2_col;
234 gulong quote_level3_col;
236 gulong tgt_folder_col;
237 gulong signature_col;
238 gboolean recycle_quote_colors;
239 gboolean conv_mb_alnum;
240 gboolean display_header_pane;
241 gboolean display_header;
243 gboolean render_html;
244 gboolean textview_cursor_visible;
245 gboolean enable_smooth_scroll;
247 gboolean scroll_halfpage;
249 gboolean show_other_header;
250 GSList *disphdr_list;
252 gboolean attach_desc;
255 gchar *mime_image_viewer;
256 gchar *mime_audio_player;
257 gchar *mime_open_cmd;
258 gchar *attach_save_dir;
260 GList *mime_open_cmd_history;
264 gboolean auto_check_signatures;
265 gboolean gpg_signature_popup;
266 gboolean store_passphrase;
267 gint store_passphrase_timeout;
268 gboolean passphrase_grab;
269 gboolean gpg_warning;
270 #endif /* USE_GPGME */
275 gint statusbar_update_step;
276 gboolean emulate_emacs;
277 gboolean always_show_msg;
278 gboolean mark_as_read_on_new_window;
279 gboolean mark_as_read_delay;
280 gboolean open_inbox_on_inc;
281 gboolean immediate_exec;
282 SelectOnEntry select_on_entry;
283 NextUnreadMsgDialogShow next_unread_msg_dialog;
284 gboolean add_address_by_click;
285 gchar *pixmap_theme_path;
286 int hover_timeout; /* msecs mouse hover timeout */
287 gboolean ask_mark_all_read;
292 gchar *ext_editor_cmd;
297 gboolean confirm_on_exit;
298 gboolean clean_on_exit;
299 gboolean ask_on_clean;
300 gboolean warn_queued_on_exit;
302 gint io_timeout_secs;
306 gboolean ssl_ask_unknown_valid;
311 gint cache_max_mem_usage;
312 gint cache_min_keep_time;
314 /* boolean for work offline
315 stored here for use in inc.c */
316 gboolean work_offline;
318 gint summary_quicksearch_type;
319 gint summary_quicksearch_sticky;
320 gint summary_quicksearch_recurse;
323 GList *summary_quicksearch_history;
325 gint filteringwin_width;
326 gint filteringwin_height;
327 gint filteringactionwin_width;
328 gint filteringactionwin_height;
329 gint matcherwin_width;
330 gint matcherwin_height;
331 gint templateswin_width;
332 gint templateswin_height;
333 gint actionswin_width;
334 gint actionswin_height;
335 gint addressbookwin_width;
336 gint addressbookwin_height;
337 gint addressbookeditpersonwin_width;
338 gint addressbookeditpersonwin_height;
339 gint pluginswin_width;
340 gint pluginswin_height;
342 gint prefswin_height;
343 gint folderitemwin_width;
344 gint folderitemwin_height;
345 gint editaccountwin_width;
346 gint editaccountwin_height;
347 gint accountswin_width;
348 gint accountswin_height;
353 gint broken_are_utf8;
356 extern PrefsCommon prefs_common;
358 void prefs_common_read_config (void);
359 void prefs_common_write_config (void);
360 void prefs_common_open (void);
361 PrefsCommon *prefs_common_get (void);
362 void pref_set_textview_from_pref(GtkTextView *textview, gchar *txt);
363 gchar *pref_get_pref_from_textview(GtkTextView *textview);
365 #endif /* __PREFS_COMMON_H__ */