Re: problem with Mime headers
- To: mutt-users@xxxxxxxx
- Subject: Re: problem with Mime headers
- From: Kyle Wheeler <kyle-mutt@xxxxxxxxxxxxxx>
- Date: Tue, 5 May 2009 13:48:58 -0500
- Comment: DomainKeys? See http://domainkeys.sourceforge.net/
- Dkim-signature: v=1; a=rsa-sha1; c=relaxed; d=memoryhole.net; h=date :from:to:subject:message-id:references:mime-version:content-type :in-reply-to; s=default; bh=sCfu4QIhkNyyAiPlMPAVMCXb/so=; b=YYYA 0+4xmcOquwu7F60lRBcKNnNKY5KJBDUZzWmHPIxLiRCyGNYRIN3pueCy9ooQSYKm cV4TKWW6DI7ZpTa/Ot3NEbgex6lLoku0YBT17IW7DnFEvdow2CbbvAC6qepwLKH7 0mu9L9xI4Poc709xdcwyuKtb+Ix84WvsV37hGmk=
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=memoryhole.net; b=UVJC3vBzsvQlh2qi1+Bwbz08OMTVjq8/cwsaoLlL4hiEoPcEZUg6m+lsFDW5SWhAdQ80ztCW8mj7UDcknF06SOZmGHXrfWgFvmPQVpTjxM4M+S/Vb4kFqbBolKBPTpL6h6kKvX+DJhQ/ijG6XRM6fQoT/aeeeJZaYcW52jzngik=; h=Received:Received:Date:From:To:Subject:Message-ID:Mail-Followup-To:References:MIME-Version:Content-Type:Content-Disposition:In-Reply-To:OpenPGP:User-Agent;
- In-reply-to: <20090505161959.GG3399@xxxxxxxxxxxxxxxxxx>
- List-post: <mailto:mutt-users@mutt.org>
- List-unsubscribe: send mail to majordomo@mutt.org, body only "unsubscribe mutt-users"
- Mail-followup-to: mutt-users@xxxxxxxx
- Openpgp: id=CA8E235E; url=http://www.memoryhole.net/~kyle/kyle-pgp.asc; preference=signencrypt
- References: <4A0023B1.9060808@xxxxxxxxxxxx> <20090505150242.GV2575@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx> <4A005C3A.6080607@xxxxxxxxxxxx> <20090505161959.GG3399@xxxxxxxxxxxxxxxxxx>
- Sender: owner-mutt-users@xxxxxxxx
- User-agent: Mutt/1.5.19 (2009-04-29)
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Tuesday, May 5 at 06:19 PM, quoth Michael Tatge:
>* On Tue, May 05, 2009 05:33PM +0200 Christoph Kukulies (kuku@xxxxxxxxxxxx)
>muttered:
>> Yes, in .muttrc I have :
>> set charset="iso-8859-1" # character set for your terminal
>>
>> That's my output of locale:
>>
>> LANG=de_DE.UTF-8
>> LANGUAGE=de_DE:de:en_GB:en
>> LC_CTYPE="de_DE.UTF-8"
>
>Why charset iso-8859-1 but utf-8 locales? Let mutt autodetect $charset,
>or at least don't let charset differ from your locales.
Michael's right. The reason you don't want your locale and charset to
disagree is because it confuses the libraries that mutt relies on. For
example, when displaying characters, mutt needs to know what
characters are printable and what characters are non-printable (e.g.
control characters). A standard way to do this is to use the isprint()
function in libc (this isn't the way mutt does it, but it's a simple
example). isprint() relies on LANG and LC_CTYPE to figure out what
characters are printable and what aren't. It assumes that the input
character is in the charset specified in the locale environment
variables, which mutt can do. But if you forced mutt to assume that
the terminal only accepts iso-8859-1 characters, mutt believes
something different than what isprint() believes, so when handed a
given character, isprint() may say "sure, that's printable" when it's
definitely NOT printable in the character set you specified with the
$charset setting. Does that make sense? In other words: the libraries
that mutt relies on for handling strings (such as libc) do not
understand mutt's configuration.
I'm *guessing* that the reason you set $charset to be ISO-8859-1 is
because your terminal (putty) freaks out when you try to display
anything else. As it happens, recent versions of putty CAN understand
UTF-8 output, if you click the right box in their configuration dialog
box. If you don't want to use UTF8 for whatever reason (e.g. your
version of putty really really can't handle it), then the right way to
change it is to change your LANG and/or LC_CTYPE settings rather than
to change mutt's $charset setting. That way all the software on the
remote system can agree on what characters are displayable and what
characters are not displayable.
Does that make sense?
~Kyle
- --
In the game of life and evolution there are three players at the
table: Human Beings, Nature, and Machines. I am firmly on the side of
Nature. But Nature, I suspect, is on the side of the Machines.
-- George Dyson
-----BEGIN PGP SIGNATURE-----
Comment: Thank you for using encryption!
iEYEARECAAYFAkoAihoACgkQBkIOoMqOI16jvgCgs9MtU+2Si4SkEwx75xuyzqah
LkUAoNMsiaoMCav0vRPKHdeCODpN6trh
=zbzs
-----END PGP SIGNATURE-----