2 * Sylpheed -- a GTK+ based, lightweight, and fast e-mail client
3 * Copyright (C) 1999-2006 Hiroyuki Yamamoto and the Claws Mail team
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"
35 #include "prefs_msg_colors.h"
37 typedef struct _PrefsCommon PrefsCommon
;
49 } ComposeDndInsertOrAttach
;
56 } TransferEncodingMethod
;
60 /* SEND_DIALOG_ACTIVE would be irrelevant */
66 /* U = unread, N = new, M = marked */
67 SELECTONENTRY_NOTHING
,
78 NEXTUNREADMSGDIALOG_ALWAYS
,
79 NEXTUNREADMSGDIALOG_ASSUME_YES
,
80 NEXTUNREADMSGDIALOG_ASSUME_NO
81 } NextUnreadMsgDialogShow
;
88 gboolean scan_all_after_inc
;
89 gboolean autochk_newmail
;
91 gboolean chk_on_startup
;
92 gboolean open_inbox_on_inc
;
93 gboolean newmail_notify_auto
;
94 gboolean newmail_notify_manu
;
95 gchar
*newmail_notify_cmd
;
96 RecvDialogMode recv_dialog_mode
;
97 gint receivewin_width
;
98 gint receivewin_height
;
99 gboolean close_recv_dialog
;
100 gboolean no_recv_err_panel
;
104 gboolean confirm_send_queued_messages
;
105 SendDialogMode send_dialog_mode
;
108 gchar
*outgoing_charset
;
109 TransferEncodingMethod encoding_method
;
111 gboolean allow_jisx0201_kana
;
116 gboolean linewrap_quote
;
117 gboolean linewrap_pastes
;
119 gboolean auto_exteditor
;
120 gboolean reply_account_autosel
;
121 gboolean default_reply_list
;
122 gboolean forward_account_autosel
;
123 gboolean reedit_account_autosel
;
126 gint autosave_length
;
127 gboolean compose_no_markup
;
128 ComposeDndInsertOrAttach compose_dnd_mode
;
129 gboolean compose_with_format
;
130 gchar
*compose_subject_format
;
131 gchar
*compose_body_format
;
134 gboolean reply_with_quote
;
139 gboolean forward_as_attachment
;
140 gboolean redirect_keep_from
;
141 gboolean block_cursor
;
145 gboolean enable_aspell
;
148 gulong misspelled_col
;
150 gboolean check_while_typing
;
151 gboolean recheck_when_changing_dict
;
152 gboolean use_alternate
;
157 gchar
*widgetfont_gtk1
;
158 gchar
*textfont_gtk1
;
159 gchar
*normalfont_gtk1
;
160 gchar
*boldfont_gtk1
;
161 gchar
*smallfont_gtk1
;
172 ColorlabelPrefs custom_colorlabel
[COLORLABELS
];
175 gboolean display_img
;
180 gboolean display_folder_unread
;
183 gboolean show_searchbar
;
184 gboolean expand_thread
;
186 gboolean use_addr_book
;
189 gboolean use_stripes_everywhere
;
190 gboolean use_stripes_in_summaries
; /* overrides if use_stripes_everywhere is set to TRUE */
191 gint stripes_color_offset
;
192 gboolean enable_dotted_lines
;
193 gboolean enable_hscrollbar
;
194 gboolean bold_unread
;
195 gboolean enable_thread
;
196 gboolean thread_by_subject
;
197 gint thread_by_subject_max_age
; /*!< Max. age of a thread which was threaded
198 * by subject (days) */
200 ToolbarStyle toolbar_style
;
201 gboolean toolbar_detachable
;
202 gboolean show_statusbar
;
204 gint folderview_vscrollbar_policy
;
210 gint important_score
;
213 GSList
*actions_list
;
215 /* Summary columns visibility, position and size */
216 gboolean summary_col_visible
[N_SUMMARY_COLS
];
217 gint summary_col_pos
[N_SUMMARY_COLS
];
218 gint summary_col_size
[N_SUMMARY_COLS
];
220 gboolean folder_col_visible
[N_FOLDER_COLS
];
221 gint folder_col_pos
[N_FOLDER_COLS
];
222 gint folder_col_size
[N_FOLDER_COLS
];
224 /* Widget visibility, position and size */
227 gint folderview_width
;
228 gint folderview_height
;
229 gboolean folderview_visible
;
231 gint summaryview_width
;
232 gint summaryview_height
;
238 gboolean msgview_visible
;
243 gint mainview_height
;
252 gint sourcewin_width
;
253 gint sourcewin_height
;
261 gboolean enable_color
;
262 gboolean enable_bgcolor
;
263 gulong quote_level1_col
;
264 gulong quote_level2_col
;
265 gulong quote_level3_col
;
266 gulong quote_level1_bgcol
;
267 gulong quote_level2_bgcol
;
268 gulong quote_level3_bgcol
;
270 gulong tgt_folder_col
;
271 gulong signature_col
;
272 gboolean recycle_quote_colors
;
273 gboolean display_header_pane
;
274 gboolean display_header
;
275 gboolean display_xface
;
277 gboolean render_html
;
278 gboolean invoke_plugin_on_html
;
279 gboolean textview_cursor_visible
;
280 gboolean enable_smooth_scroll
;
282 gboolean scroll_halfpage
;
283 gboolean respect_flowed_format
;
285 gboolean show_other_header
;
286 gboolean use_different_print_font
;
287 GSList
*disphdr_list
;
289 gboolean attach_desc
;
292 gchar
*mime_textviewer
;
293 gchar
*mime_open_cmd
;
294 gchar
*attach_save_dir
;
295 gchar
*attach_load_dir
;
297 GList
*mime_open_cmd_history
;
301 gboolean auto_check_signatures
;
302 gboolean gpg_signature_popup
;
303 gboolean store_passphrase
;
304 gint store_passphrase_timeout
;
305 gboolean passphrase_grab
;
306 gboolean gpg_warning
;
307 #endif /* USE_GPGME */
310 gboolean addressbook_use_editaddress_dialog
;
315 gint statusbar_update_step
;
316 gboolean emulate_emacs
;
317 gboolean always_show_msg
;
318 gboolean mark_as_read_on_new_window
;
319 gboolean mark_as_read_delay
;
320 gboolean immediate_exec
;
321 SelectOnEntry select_on_entry
;
322 NextUnreadMsgDialogShow next_unread_msg_dialog
;
323 gboolean add_address_by_click
;
324 gchar
*pixmap_theme_path
;
325 int hover_timeout
; /* msecs mouse hover timeout */
326 gboolean ask_mark_all_read
;
327 gboolean ask_apply_per_account_filtering_rules
;
328 gint apply_per_account_filtering_rules
;
333 gchar
*ext_editor_cmd
;
337 gulong log_msg_color
;
338 gulong log_warn_color
;
339 gulong log_error_color
;
341 gulong log_out_color
;
343 gboolean confirm_on_exit
;
344 gboolean clean_on_exit
;
345 gboolean ask_on_clean
;
346 gboolean warn_queued_on_exit
;
348 gint io_timeout_secs
;
351 gint cache_max_mem_usage
;
352 gint cache_min_keep_time
;
354 /* boolean for work offline
355 stored here for use in inc.c */
356 gboolean work_offline
;
358 gint summary_quicksearch_type
;
359 gint summary_quicksearch_sticky
;
360 gint summary_quicksearch_recurse
;
361 gint summary_quicksearch_dynamic
;
364 GList
*summary_quicksearch_history
;
365 GList
*summary_search_from_history
;
366 GList
*summary_search_to_history
;
367 GList
*summary_search_subject_history
;
368 GList
*summary_search_body_history
;
369 GList
*summary_search_adv_condition_history
;
370 GList
*message_search_history
;
372 gint filteringwin_width
;
373 gint filteringwin_height
;
374 gint filteringactionwin_width
;
375 gint filteringactionwin_height
;
376 gint matcherwin_width
;
377 gint matcherwin_height
;
378 gint templateswin_width
;
379 gint templateswin_height
;
380 gint actionswin_width
;
381 gint actionswin_height
;
382 gint addressbookwin_width
;
383 gint addressbookwin_height
;
384 gint addressbookeditpersonwin_width
;
385 gint addressbookeditpersonwin_height
;
386 gint addressbookeditgroupwin_width
;
387 gint addressbookeditgroupwin_height
;
388 gint pluginswin_width
;
389 gint pluginswin_height
;
391 gint prefswin_height
;
392 gint folderitemwin_width
;
393 gint folderitemwin_height
;
394 gint editaccountwin_width
;
395 gint editaccountwin_height
;
396 gint accountswin_width
;
397 gint accountswin_height
;
400 gint folderselwin_width
;
401 gint folderselwin_height
;
402 gint addressaddwin_width
;
403 gint addressaddwin_height
;
404 gint addressbook_folderselwin_width
;
405 gint addressbook_folderselwin_height
;
408 gint broken_are_utf8
;
409 gint skip_ssl_cert_check
;
410 gint live_dangerously
;
411 gint never_send_retrcpt
;
413 gboolean unsafe_ssl_certs
;
416 extern PrefsCommon prefs_common
;
418 void prefs_common_read_config (void);
419 void prefs_common_write_config (void);
420 void prefs_common_open (void);
421 PrefsCommon
*prefs_common_get (void);
422 void pref_get_unescaped_pref(gchar
*out
, const gchar
*in
);
423 void pref_get_escaped_pref(gchar
*out
, const gchar
*in
);
424 void pref_set_textview_from_pref(GtkTextView
*textview
, const gchar
*txt
);
425 void pref_set_entry_from_pref(GtkEntry
*entry
, const gchar
*txt
);
426 gchar
*pref_get_pref_from_textview(GtkTextView
*textview
);
427 gchar
*pref_get_pref_from_entry(GtkEntry
*entry
);
429 #endif /* __PREFS_COMMON_H__ */