[notmuch] [PATCH] notmuch-reply: Display reply message part using UTF-8.

2009-12-03 Thread Carl Worth
On Sat, 28 Nov 2009 19:58:29 +0800, Kan-Ru Chen  wrote:
> Pass the message through the charset filter so that we can view
> messages wrote in different charset encoding.
...
> Same problem as notmuch-show before. Noticed this when I intend to
> reply a Chinese mail...

Thanks Kanru,

This is pushed now.

-Carl
-- next part --
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: 



Re: [notmuch] [PATCH] notmuch-reply: Display reply message part using UTF-8.

2009-12-03 Thread Carl Worth
On Sat, 28 Nov 2009 19:58:29 +0800, Kan-Ru Chen ka...@kanru.info wrote:
 Pass the message through the charset filter so that we can view
 messages wrote in different charset encoding.
...
 Same problem as notmuch-show before. Noticed this when I intend to
 reply a Chinese mail...

Thanks Kanru,

This is pushed now.

-Carl


pgpI7Zo0wCKIX.pgp
Description: PGP signature
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[notmuch] [PATCH] notmuch-reply: Display reply message part using UTF-8.

2009-11-28 Thread Kan-Ru Chen

Same problem as notmuch-show before. Noticed this when I intend to
reply a Chinese mail...


Cheers,
 Kanru


[notmuch] [PATCH] notmuch-reply: Display reply message part using UTF-8.

2009-11-28 Thread Kan-Ru Chen
Pass the message through the charset filter so that we can view
messages wrote in different charset encoding.

Signed-off-by: Kan-Ru Chen 
---
 notmuch-reply.c |6 ++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/notmuch-reply.c b/notmuch-reply.c
index 9ca1236..0cda72d 100644
--- a/notmuch-reply.c
+++ b/notmuch-reply.c
@@ -39,11 +39,17 @@ reply_part_content (GMimeObject *part)
 {
 GMimeStream *stream_stdout = NULL, *stream_filter = NULL;
 GMimeDataWrapper *wrapper;
+const char *charset;

+charset = g_mime_object_get_content_type_parameter (part, "charset");
 stream_stdout = g_mime_stream_file_new (stdout);
 if (stream_stdout) {
g_mime_stream_file_set_owner (GMIME_STREAM_FILE (stream_stdout), FALSE);
stream_filter = g_mime_stream_filter_new(stream_stdout);
+if (charset) {
+  g_mime_stream_filter_add(GMIME_STREAM_FILTER(stream_filter),
+   g_mime_filter_charset_new(charset, 
"UTF-8"));
+}
 }
 g_mime_stream_filter_add(GMIME_STREAM_FILTER(stream_filter),
 g_mime_filter_reply_new(TRUE));
-- 
1.6.5.3



Re: [notmuch] [PATCH] notmuch-reply: Display reply message part using UTF-8.

2009-11-28 Thread Kan-Ru Chen

Same problem as notmuch-show before. Noticed this when I intend to
reply a Chinese mail...


Cheers,
 Kanru
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch