Harald Hanche-Olsen | 1 Jan 2009 17:53
Picon
Picon
Favicon
Gravatar

[mew-int 2667] Re: format=flowed

+ Kazu Yamamoto (山本和彦) <kazu <at> iij.ad.jp>:

>>> I have implemented the encoding of format=flowed and fixed several
>>> bugs of the decoding.
>>
>> Thank you. From a little testing, it works fine except for one
>> thing: You should turn off longlines-mode before encoding the
>> buffer, as otherwise your code (mew-encode-flowed) will see soft
>> line breaks as hard ones, and the paragraphs are broken into lines.
>>
>> In order to avoid autoloading longlines.el in vain I suggest code like
>>
>> (if (and (boundp 'longlines-mode) longlines-mode) (longlines-mode-off))
>>
>> inserted in the right place.
> 
> Thank you. I have merged this code.

In some cases, turning off longlines-mode in mew-smtp-encode-message
is too late. If my buffer looks like this:

To: hanche <at> math.ntnu.no
Subject: Test
From: Harald Hanche-Olsen <hanche <at> math.ntnu.no>
References: <a-very-long-reference-that-is-bound-to-move-into-the-next-line <at> math.ntnu.no>
  <another-reference <at> math.ntnu.no>
X-Mailer: Mew version 6.1.53 on Emacs 23.0.60 / Mule 6.0 (HANACHIRUSATO)
----
Test message.

(Continue reading)

Kazu Yamamoto | 7 Jan 2009 11:02
Picon
Gravatar

[mew-dist 28813] Re: [mew-int 2667] Re: format=flowed

Hello,

> In some cases, turning off longlines-mode in mew-smtp-encode-message
> is too late. If my buffer looks like this:
> 
> So longlines-mode needs to be turned off before mew gets to look at
> any headers, I think.

Does the following patch solve your problem?

--Kazu

Index: mew-draft.el
===================================================================
RCS file: /cvsroot/mew/mew/mew-draft.el,v
retrieving revision 1.155
diff -c -r1.155 mew-draft.el
*** mew-draft.el	5 Jan 2009 01:56:00 -0000	1.155
--- mew-draft.el	7 Jan 2009 10:00:50 -0000
***************
*** 765,770 ****
--- 765,771 ----
        (mew-draft-process-message 'send))))

  (defun mew-draft-process-message (action &optional privacy signer)
+   (if (and (boundp 'longlines-mode) longlines-mode) (longlines-mode -1))
    (run-hooks 'mew-make-message-hook)
    (let* ((case (or (mew-tinfo-get-case) mew-case-default))
  	 (old-case case)
Index: mew-encode.el
(Continue reading)

Kevin Lin | 15 Jan 2009 01:20
Picon

[mew-int 2669] How to save attachment with different encoding (for filename)

Hi, There:

   I am getting comfortable with using Mew in my Linux box. Now, one issue needs your help.
   My Linux box language encoding is "UTF-8" (default), and my Mew is set to Big5. I can read mail
   very well. But when I get some mail with file attachment which is named with Big5 file name. If I
   save it directly, and use Linux file browser to list the saved file, the file name is
   unreadable. Any tips to solve this issue.

   Any help is very appreciated. Thanks.

-kevinlin

Kazu Yamamoto | 19 Jan 2009 08:29
Picon
Gravatar

[mew-int 2670] Re: How to save attachment with different encoding (for filename)

Hello,

>    I am getting comfortable with using Mew in my Linux box. Now, one
>    issue needs your help.  My Linux box language encoding is "UTF-8"
>    (default), and my Mew is set to Big5. I can read mail very
>    well. But when I get some mail with file attachment which is
>    named with Big5 file name. If I save it directly, and use Linux
>    file browser to list the saved file, the file name is
>    unreadable. Any tips to solve this issue.

I think this is not an issue of Mew.

What you want to know is how to specify file names with UTF-8 on
Emacs, I guess.  Please put the following to your ".emacs".

  (set-file-name-coding-system 'utf-8)

--Kazu

Kazu Yamamoto | 21 Jan 2009 07:20
Picon
Gravatar

[mew-int 2671] Mew version 6.2.50

Hello,

I have released Mew version 6.2.50:

	http://www.mew.org/Beta/mew-6.2.50.tar.gz

Several bugs were found after Mew 6.2 was released. They have been
fixed in this version.

--Kazu

vvoody | 24 Jan 2009 08:46
Favicon

[mew-int 2672] Why Mew always choose ISO-2022-JP-2 to send mails ? 牛

Mew ^_^

In the end of subject of this mail, there was a Chinese character. But
as you can see, it was encoded by ISO-2022-JP-2 not GB2312 or UTF-8. So
that, the recipients will see the gibberish :(

I have tried many methods to make Mew detect the encoding accurately,
but all failed.

My environment:
===========================================
Mew 6.2.50
Slackware 12.2
kernel 2.6.27.7
GNU Emacs 23.0.60.1 (GTK+ Version 2.12.12)
===========================================

I also have Emacs 22.2.3 installed on my system. When I ran Mew on 22,
Mew chosen GB2312 to send my Chinese mails correctly.

This makes me so confused :( What's up ?

Tatsuya Kinoshita | 24 Jan 2009 09:54
Picon

[mew-int 2673] Re: Why Mew always choose ISO-2022-JP-2 to send mails ? 牛

On January 24, 2009, [mew-int 2672],
vvoody (at qq.com) wrote:

> In the end of subject of this mail, there was a Chinese character. But
> as you can see, it was encoded by ISO-2022-JP-2 not GB2312 or UTF-8. So
> that, the recipients will see the gibberish :(
[...]
> I also have Emacs 22.2.3 installed on my system. When I ran Mew on 22,
> Mew chosen GB2312 to send my Chinese mails correctly.

Probably, Japanese characters are preferred over Chinese characters
on Unicode handling of your Emacs 23.

What's your locale setting? (e.g. LANG=zh_CN)

How about (set-language-environment "Chinese-GB")?

BTW, Emacs 23 is drastically changed from Emacs 22, and Mew has not
yet been well tested with it.  At this time, Emacs 23 isn't a
recommendable version for Mew.

Thanks,
--

-- 
Tatsuya Kinoshita

Harald Hanche-Olsen | 24 Jan 2009 10:18
Picon
Picon
Favicon
Gravatar

[mew-int 2674] Re: Why Mew always choose ISO-2022-JP-2 to send mails ? 牛

+ vvoody <vvoody <at> qq.com>:

> Mew ^_^
> 
> In the end of subject of this mail, there was a Chinese
> character. But as you can see, it was encoded by ISO-2022-JP-2 not
> GB2312 or UTF-8. So that, the recipients will see the gibberish :(

And as you can see, my mew encoded it as UTF-8.

> GNU Emacs 23.0.60.1 (GTK+ Version 2.12.12)
> 
> I also have Emacs 22.2.3 installed on my system. When I ran Mew on
> 22, Mew chosen GB2312 to send my Chinese mails correctly.

I have GNU Emacs 23.0.60.2 (powerpc-apple-darwin9.5.0, NS
apple-appkit-949.35) of 2008-11-29.

I have these settings in my .mew.el:

(setq mew-ask-charset '("us-ascii" "iso-8859-1" "iso-8859-15" "utf-8"))
(setq mew-internal-utf-8p t)
(setq mew-cs-database-for-encoding
      '(((ascii)
	 nil "7bit" "7bit")
	((ascii iso-8859-1)
	 iso-8859-1 "8bit" "Q")
	((ascii latin-iso8859-1)
	 iso-8859-1 "quoted-printable" "Q")
	(nil utf-8 "base64" "Q")))
(Continue reading)

vvoody | 24 Jan 2009 13:20
Favicon

[mew-int 2675] Re: Why Mew always choose ISO-2022-JP-2 to send mails ? 牛

From: Tatsuya Kinoshita <tats <at> vega.ocn.ne.jp>
Subject: [mew-int 2673] Re: Why Mew always choose ISO-2022-JP-2 to send mails ? 牛
Date: Sat, 24 Jan 2009 17:54:25 +0900 (JST)

> On January 24, 2009, [mew-int 2672],
> vvoody (at qq.com) wrote:
> 
>> In the end of subject of this mail, there was a Chinese character. But
>> as you can see, it was encoded by ISO-2022-JP-2 not GB2312 or UTF-8. So
>> that, the recipients will see the gibberish :(
> [...]
>> I also have Emacs 22.2.3 installed on my system. When I ran Mew on 22,
>> Mew chosen GB2312 to send my Chinese mails correctly.
> 
> Probably, Japanese characters are preferred over Chinese characters
> on Unicode handling of your Emacs 23.
> 
> What's your locale setting? (e.g. LANG=zh_CN)
> 
vvoody <at> slackware:~/Downloads/cvs/emacs/src$ locale
LANG=en_US.UTF-8
LC_CTYPE=zh_CN.UTF-8
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
(Continue reading)

Harald Hanche-Olsen | 27 Jan 2009 14:46
Picon
Picon
Favicon
Gravatar

[mew-int 2676] Re: format=flowed

+ Kazu Yamamoto (山本和彦) <kazu <at> iij.ad.jp>:

> > In some cases, turning off longlines-mode in mew-smtp-encode-message
> > is too late. If my buffer looks like this:
> > 
> > So longlines-mode needs to be turned off before mew gets to look at
> > any headers, I think.
> 
> Does the following patch solve your problem?

Yes. (I see that you have already put it into CVS.)

This also solves another problem that I discovered later: If I have
set up a file attachment area (C-c C-a) and turned on longlines-mode,
things would really go haywire. It works okay now, except the file
attachment area looks really funny while longlines-mode is turned on.

Thanks.

- Harald


Gmane