sync with 0.8.8cvs1
authorPaul Mangan <paul@claws-mail.org>
Mon, 6 Jan 2003 20:39:06 +0000 (20:39 +0000)
committerPaul Mangan <paul@claws-mail.org>
Mon, 6 Jan 2003 20:39:06 +0000 (20:39 +0000)
ChangeLog
ChangeLog.claws
ChangeLog.jp
configure.in
src/codeconv.c
src/compose.c
src/customheader.c
src/prefs_customheader.c

index 54e79bd..3950fb2 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2003-01-06
+
+       * src/codeconv.c: LBREAK_IF_REQUIRED(): break line only if some
+         characters follow.
+       * src/compose.c: compose_convert_header(): remove trailing spaces.
+       * src/customheader.c: custom_header_read_str(): strip the spaces
+         of name and value.
+       * src/prefs_customheader.c: prefs_custom_header_clist_set_row():
+         strip the spaces of name and value.
+
 2002-12-25
 
        * version 0.8.8
index 4c270cb..3fda0e0 100644 (file)
@@ -1,3 +1,8 @@
+2003-01-06 [paul]      0.8.8claws57
+
+       * sync with 0.8.8cvs1
+               see ChangeLog 2003-01-06
+
 2003-01-06 [christoph] 0.8.8claws56
 
        * src/mainwindow.c
index a9fd619..1f5e65f 100644 (file)
@@ -1,3 +1,13 @@
+2003-01-06
+
+       * src/codeconv.c: LBREAK_IF_REQUIRED(): Ê¸»ú¤¬Â³¤¯¾ì¹ç¤Î¤ß²þ¹Ô¤¹¤ë
+         ¤è¤¦¤Ë¤·¤¿¡£
+       * src/compose.c: compose_convert_header(): ËöÈø¤Î¶õÇò¤òºï½ü¡£
+       * src/customheader.c: custom_header_read_str(): Ì¾Á°¤ÈÃͤζõÇò¤ò
+         ºï½ü¡£
+       * src/prefs_customheader.c: prefs_custom_header_clist_set_row():
+         Ì¾Á°¤ÈÃͤζõÇò¤òºï½ü¡£
+
 2002-12-25
 
        * version 0.8.8
index f8ceb0e..1dd4354 100644 (file)
@@ -11,7 +11,7 @@ MINOR_VERSION=8
 MICRO_VERSION=8
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=claws56
+EXTRA_VERSION=claws57
 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION
 
 dnl set $target
index 123e573..c2178fe 100644 (file)
@@ -1063,14 +1063,16 @@ void conv_unmime_header(gchar *outbuf, gint outlen, const gchar *str,
                return;                                         \
        }                                                       \
                                                                \
-       if (cond) {                                             \
+       if ((cond) && *srcp) {                                  \
                if (destp > dest && isspace(*(destp - 1)))      \
                        destp--;                                \
                else if (isspace(*srcp))                        \
                        srcp++;                                 \
-               *destp++ = '\n';                                \
-               *destp++ = ' ';                                 \
-               left = MAX_LINELEN - 1;                         \
+               if (*srcp) {                                    \
+                       *destp++ = '\n';                        \
+                       *destp++ = ' ';                         \
+                       left = MAX_LINELEN - 1;                 \
+               }                                               \
        }                                                       \
 }
 
index 6a3b4e3..3f9f445 100644 (file)
@@ -4174,7 +4174,7 @@ static void compose_convert_header(gchar *dest, gint len, gchar *src,
 
        if (len < 1) return;
 
-       remove_return(src);
+       g_strchomp(src);
 
        conv_encode_header(dest, len, src, header_len);
 }
index 7d8560a..35fad07 100644 (file)
@@ -1,6 +1,6 @@
 /*
  * Sylpheed -- a GTK+ based, lightweight, and fast e-mail client
- * Copyright (C) 1999-2001 Hiroyuki Yamamoto
+ * Copyright (C) 1999-2002 Hiroyuki Yamamoto
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -46,7 +46,6 @@ CustomHeader *custom_header_read_str(const gchar *buf)
        gchar *tmp;
 
        Xstrdup_a(tmp, buf, return NULL);
-       g_strstrip(tmp);
 
        account_id_str = tmp;
 
@@ -61,17 +60,17 @@ CustomHeader *custom_header_read_str(const gchar *buf)
                if (*endp != '\0') return NULL;
        }
 
-       while (*name == ' ') name++;
-
        value = strchr(name, ':');
        if (!value) return NULL;
 
        *value++ = '\0';
 
+       g_strstrip(name);
+       g_strstrip(value);
+
        ch = g_new0(CustomHeader, 1);
        ch->account_id = id;
        ch->name = *name ? g_strdup(name) : NULL;
-       while (*value == ' ') value++;
        ch->value = *value ? g_strdup(value) : NULL;
 
        return ch;
index 35af9d1..0e3e8b0 100644 (file)
@@ -332,7 +332,6 @@ void prefs_custom_header_read_config(PrefsAccount *ac)
        }
 
        while (fgets(buf, sizeof(buf), fp) != NULL) {
-               g_strchomp(buf);
                ch = custom_header_read_str(buf);
                if (ch) {
                        if (ch->account_id == ac->account_id) {
@@ -368,7 +367,6 @@ void prefs_custom_header_write_config(PrefsAccount *ac)
                all_hdrs = NULL;
 
                while (fgets(buf, sizeof(buf), fp) != NULL) {
-                       g_strchomp(buf);
                        ch = custom_header_read_str(buf);
                        if (ch) {
                                if (ch->account_id != ac->account_id)
@@ -492,11 +490,15 @@ static gint prefs_custom_header_clist_set_row(PrefsAccount *ac, gint row)
 
        ch->name = g_strdup(entry_text);
        unfold_line(ch->name);
+       g_strstrip(ch->name);
+       gtk_entry_set_text(GTK_ENTRY(customhdr.hdr_entry), ch->name);
 
        entry_text = gtk_entry_get_text(GTK_ENTRY(customhdr.val_entry));
        if (entry_text[0] != '\0') {
                ch->value = g_strdup(entry_text);
                unfold_line(ch->value);
+               g_strstrip(ch->value);
+               gtk_entry_set_text(GTK_ENTRY(customhdr.val_entry), ch->value);
        }
 
        ch_str[0] = g_strdup_printf("%s: %s", ch->name,