+2012-10-09 [mones] 3.8.1cvs86
+
+ * doc/man/claws-mail.1
+ * src/compose.c
+ * src/common/utils.c
+ New extra headers feature for adding user-defined
+ extra headers to the combobox in the compose window
+ Headers are stablished in 'extraheaderrc', one per
+ line with a final colon
+
2012-10-06 [mones] 3.8.1cvs85
* po/POTFILES.in
2012-09-22 [mir] 3.8.1cvs72
* src/advsearch.c
- Fix for not searching in folders marked 'no_select'
- patch provide by colin.
+ Fix for not searching in folders marked 'no_select'
+ patch provided by Colin.
2012-09-22 [mones] 3.8.1cvs71
2012-09-16 [mones] 3.8.1cvs60
- * src/action.c
- Removed dup calls with ignored result
- * src/addr_compl.c
- Removed unused var is_group and simplified logic around it
- * src/addrharvest.c
- * src/matcher.c
- * src/procmsg.c
- * src/etpan/etpan-thread-manager.c
- Use unused var r to verify result and emit messages on error
- * src/compose.c
- Move color variable into conditional usage blocks
- Remove assigned but not used vars: lock, titles, count
- * src/edittags.c
- Remove assigned but not used var actions
- * src/folderview.c
- Remove assigned but not used vars: from_parent, src_node
- * src/imap_gtk.c
- * src/mh_gtk.c
- Remove malloc-ed but not used var: old_path
- * src/news.c
- Comment unused vars from commented block: tofetch, fetched
- * src/prefs_account.c
- Remove assigned but not used var: privacy_enabled
- * src/prefs_actions.c
- * src/prefs_customheader.c
- Remove assigned but not used var: store
- * src/prefs_filtering.c
- Remove assigned but not used var: n_rows
- * src/prefs_template.c
- Remove assigned but not used vars: model, list_store
- * src/prefs_toolbar.c
- Remove assigned but not used var: win_titles
- * src/printing.c
- Remove assigned but not used vars: orientation, line, baseline,
- off_chars
- * src/etpan/imap-thread.c
- Remove assigned but not used var: value, r
- Refactor to check correct memory allocation
- * src/etpan/nntp-thread.c
- Remove assigned but not used var: value
- * src/gtk/gtkaspell.c
- Remove assigned but not used vars: textbuf, exist
- Remove unused function: find_gtkaspeller
- * src/gtk/gtkcmctree.c
- Remove unused function: gtk_cmctree_get_offset
- * src/gtk/gtkshruler.c
- Remove assigned but not used vars: ruler, priv
+ * src/action.c
+ Removed dup calls with ignored result
+ * src/addr_compl.c
+ Removed unused var is_group and simplified logic around it
+ * src/addrharvest.c
+ * src/matcher.c
+ * src/procmsg.c
+ * src/etpan/etpan-thread-manager.c
+ Use unused var r to verify result and emit messages on error
+ * src/compose.c
+ Move color variable into conditional usage blocks
+ Remove assigned but not used vars: lock, titles, count
+ * src/edittags.c
+ Remove assigned but not used var actions
+ * src/folderview.c
+ Remove assigned but not used vars: from_parent, src_node
+ * src/imap_gtk.c
+ * src/mh_gtk.c
+ Remove malloc-ed but not used var: old_path
+ * src/news.c
+ Comment unused vars from commented block: tofetch, fetched
+ * src/prefs_account.c
+ Remove assigned but not used var: privacy_enabled
+ * src/prefs_actions.c
+ * src/prefs_customheader.c
+ Remove assigned but not used var: store
+ * src/prefs_filtering.c
+ Remove assigned but not used var: n_rows
+ * src/prefs_template.c
+ Remove assigned but not used vars: model, list_store
+ * src/prefs_toolbar.c
+ Remove assigned but not used var: win_titles
+ * src/printing.c
+ Remove assigned but not used vars: orientation, line, baseline,
+ off_chars
+ * src/etpan/imap-thread.c
+ Remove assigned but not used var: value, r
+ Refactor to check correct memory allocation
+ * src/etpan/nntp-thread.c
+ Remove assigned but not used var: value
+ * src/gtk/gtkaspell.c
+ Remove assigned but not used vars: textbuf, exist
+ Remove unused function: find_gtkaspeller
+ * src/gtk/gtkcmctree.c
+ Remove unused function: gtk_cmctree_get_offset
+ * src/gtk/gtkshruler.c
+ Remove assigned but not used vars: ruler, priv
2012-09-14 [mones] 3.8.1cvs59
2012-09-12 [mones] 3.8.1cvs54
* src/prefs_other.c
- Fix 1975 'preference mutt key bindings do not take effect'
- (and the other invalid paths too)
+ Fix bug #1975 'preference mutt key bindings do not take
+ effect' (and the other invalid paths too)
2012-09-12 [colin] 3.8.1cvs53
#define MAX_REFERENCES_LEN 999
static GList *compose_list = NULL;
+static GSList *extra_headers = NULL;
static Compose *compose_generic_new (PrefsAccount *account,
const gchar *to,
gtk_widget_show(menuitem);
}
+void compose_add_extra_header(gchar *header, GtkListStore *model)
+{
+ GtkTreeIter iter;
+ if (strcmp(header, "")) {
+ COMBOBOX_ADD(model, header, COMPOSE_TO);
+ }
+}
+
+void compose_add_extra_header_entries(GtkListStore *model)
+{
+ FILE *exh;
+ gchar *exhrc;
+ gchar buf[BUFFSIZE];
+ gint lastc;
+
+ if (extra_headers == NULL) {
+ exhrc = g_strconcat(get_rc_dir(), G_DIR_SEPARATOR_S, "extraheaderrc", NULL);
+ if ((exh = g_fopen(exhrc, "rb")) == NULL) {
+ debug_print("extra headers file not found\n");
+ goto extra_headers_done;
+ }
+ while (fgets(buf, BUFFSIZE, exh) != NULL) {
+ lastc = strlen(buf) - 1; /* remove trailing \n */
+ buf[lastc] = (buf[lastc] == '\n')? '\0': buf[lastc];
+ --lastc;
+ if (lastc > 0 && buf[0] != '#' && buf[lastc] == ':') {
+ buf[lastc] = '\0'; /* remove trailing : for comparison */
+ if (custom_header_is_allowed(buf)) {
+ buf[lastc] = ':';
+ extra_headers = g_slist_prepend(extra_headers, g_strdup(buf));
+ }
+ else
+ g_message("disallowed extra header line: %s\n", buf);
+ }
+ else {
+ if (buf[0] != '#')
+ g_message("invalid extra header line: %s\n", buf);
+ }
+ }
+ fclose(exh);
+extra_headers_done:
+ g_free(exhrc);
+ extra_headers = g_slist_prepend(extra_headers, g_strdup("")); /* end of list */
+ extra_headers = g_slist_reverse(extra_headers);
+ }
+ g_slist_foreach(extra_headers, (GFunc)compose_add_extra_header, (gpointer)model);
+}
+
static void compose_create_header_entry(Compose *compose)
{
gchar *headers[] = {"To:", "Cc:", "Bcc:", "Newsgroups:", "Reply-To:", "Followup-To:", NULL};
COMPOSE_REPLYTO);
COMBOBOX_ADD(model, prefs_common_translated_header_name("Followup-To:"),
COMPOSE_FOLLOWUPTO);
+ compose_add_extra_header_entries(model);
gtk_combo_box_set_active(GTK_COMBO_BOX(combo), 0);
g_signal_connect(G_OBJECT(gtk_bin_get_child(GTK_BIN(combo))), "grab_focus",
slist_free_strings(compose->header_list);
g_slist_free(compose->header_list);
+ slist_free_strings(extra_headers);
+ extra_headers = NULL;
+
compose->header_list = compose->newsgroup_list = compose->to_list = NULL;
g_hash_table_destroy(compose->email_hashtable);