commit - c215d14d2165cb25126ea6a37f3fca52b0ea5d7f
commit + 101e8c42867b7647c33d25c13e8281f9c7bd0d7c
blob - 9cca09e39053b6edff44bd298689744a644af4e1
blob + d64224d592c75c58fdeead11eb5e2e60e4f34e42
--- src/common/utils.c
+++ src/common/utils.c
return 0;
}
-const gchar * line_has_quote_char(const gchar * str, const gchar *quote_chars)
+const gchar * line_has_quote_char(const gchar * str)
{
- gchar * position = NULL;
- gchar * tmp_pos = NULL;
- int i;
-
- if (str == NULL || quote_chars == NULL)
- return NULL;
-
- for (i = 0; i < strlen(quote_chars); i++) {
- tmp_pos = strchr (str, quote_chars[i]);
- if(position == NULL
- || (tmp_pos != NULL && position >= tmp_pos) )
- position = tmp_pos;
- }
- return position;
+ return strchr(str, '>');
}
static gchar *strstr_with_skip_quote(const gchar *haystack, const gchar *needle)
blob - a609ec624b61fcb50c7e694e209fbb0078560182
blob + 6390d61a95b52f1e41f624872b03063b0fb6c56e
--- src/common/utils.h
+++ src/common/utils.h
gint subject_get_prefix_length (const gchar *subject);
/* quoting recognition */
-const gchar * line_has_quote_char (const gchar *str,
- const gchar *quote_chars);
+const gchar * line_has_quote_char (const gchar *str);
gint g_int_compare (gconstpointer a, gconstpointer b);
blob - 288e23fcf29237c1a15953a2e408bb3b62a8ff45
blob + 54f7591cfcd04b8ddd1940e1a86a77b910625422
--- src/mainwindow.c
+++ src/mainwindow.c
SummarySelection selection;
FolderItem *item = mainwin->summaryview->folder_item;
GList *account_list = account_get_list();
- GSList *tmp;
selection = summary_get_selection_type(mainwin->summaryview);
prefs_common.mainwin_width,
prefs_common.mainwin_height);
}
- if (!prefs_common.display_header_name)
+ if (!prefs_common.display_header_pane)
gtk_widget_hide(mainwin->messageview->headerview->hbox);
if (mainwin->messageview->visible)
blob - b451379cfe23d2d4266918fa7d91694d0e7abbe0
blob + 3d09685dfbd7c352696cf89d7c895bd1e59f61fd
--- src/messageview.c
+++ src/messageview.c
return;
}
- headerview_destroy(messageview->headerview);
+ g_free(messageview->headerview);
mimeview_destroy(messageview->mimeview);
noticeview_destroy(messageview->noticeview);
blob - 3912bd4769c22e3dfa9fc79b118e15c50c95266b
blob + 6692b7ab84dfa386f005c107442647559febc4ec
--- src/prefs_message.c
+++ src/prefs_message.c
GtkWidget *checkbtn_hide_quoted;
GtkWidget *checkbtn_attach_desc;
- GtkWidget *entry_quote_chars;
} MessagePage;
static void disphdr_pane_toggled(GtkToggleButton *toggle_btn, GtkWidget *widget)
GtkWidget *frame_quote;
GtkWidget *hbox2;
GtkWidget *vbox_quote;
- GtkWidget *entry_quote_chars;
- GtkWidget *label_quote_chars;
vbox1 = gtk_box_new(GTK_ORIENTATION_VERTICAL, VSPACING);
gtk_widget_show (vbox1);
gtk_widget_show (hbox2);
gtk_box_pack_start (GTK_BOX (hbox1), hbox2, FALSE, FALSE, 0);
- label_quote_chars = gtk_label_new (_("Treat these characters as quotation marks"));
- gtk_widget_show (label_quote_chars);
- gtk_box_pack_start (GTK_BOX (hbox2), label_quote_chars, FALSE, FALSE, 0);
-
- entry_quote_chars = gtk_entry_new ();
- gtk_widget_show (entry_quote_chars);
- gtk_box_pack_start (GTK_BOX (hbox2), entry_quote_chars,
- FALSE, FALSE, 0);
- gtk_widget_set_size_request (entry_quote_chars, 64, -1);
-
gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(checkbtn_disphdrpane),
prefs_common.display_header_pane);
prefs_common.line_space);
gtk_spin_button_set_value(GTK_SPIN_BUTTON(spinbtn_scrollstep),
prefs_common.scroll_step);
- gtk_entry_set_text(GTK_ENTRY(entry_quote_chars),
- prefs_common.quote_chars?prefs_common.quote_chars:"");
prefs_message->window = GTK_WIDGET(window);
prefs_message->checkbtn_disphdrpane = checkbtn_disphdrpane;
prefs_message->spinbtn_scrollstep = spinbtn_scrollstep;
prefs_message->checkbtn_halfpage = checkbtn_halfpage;
prefs_message->checkbtn_attach_desc = checkbtn_attach_desc;
- prefs_message->entry_quote_chars = entry_quote_chars;
prefs_message->page.widget = vbox1;
}
prefs_common.scroll_step = gtk_spin_button_get_value_as_int(
GTK_SPIN_BUTTON(page->spinbtn_scrollstep));
- g_free(prefs_common.quote_chars);
- prefs_common.quote_chars = gtk_editable_get_chars(
- GTK_EDITABLE(page->entry_quote_chars), 0, -1);
- remove_space(prefs_common.quote_chars);
-
main_window_reflect_prefs_all_real(FALSE);
}
blob - 660b4aad1cc3d7ebfe49dfa9418ace54b72c5ae0
blob + cc3954f153e3c1d43546a87c6d076e9497e2fbf5
--- src/summaryview.c
+++ src/summaryview.c
static gchar date_modified[80];
static gchar col_score[11];
static gchar from_buf[BUFFSIZE], to_buf[BUFFSIZE];
- static gchar tmp1[BUFFSIZE], tmp2[BUFFSIZE+4], tmp3[BUFFSIZE];
+ static gchar tmp2[BUFFSIZE+4], tmp3[BUFFSIZE];
gint *col_pos = summaryview->col_pos;
gchar *from_text = NULL, *to_text = NULL;
gboolean should_swap = FALSE;
blob - 2a33bcd934a4e9fc293515419ada2c3d286bf4db
blob + 657ccba7d7947fb738513bdac067b8c885e09016
--- src/textview.c
+++ src/textview.c
>, foo>, _> ... ok, <foo>, foo bar>, foo-> ... ng
Up to 3 levels of quotations are detected, and each
level is colored using a different color. */
- if (prefs_common.enable_color
- && !textview->is_attachment
- && line_has_quote_char(buf, prefs_common.quote_chars)) {
+ if (prefs_common.enable_color && !textview->is_attachment && line_has_quote_char(buf)) {
real_quotelevel = quote_depth(buf);
quotelevel = real_quotelevel;
/* set up the correct foreground color */