Gnus development mailing list
 help / color / mirror / Atom feed
From: Jesper Harder <harder@myrealbox.com>
Subject: Re: quoted-printable no-go in news?
Date: Tue, 08 Apr 2003 13:48:36 +0200	[thread overview]
Message-ID: <m3istpb46j.fsf@defun.localdomain> (raw)
In-Reply-To: <m37ka6nlf4.fsf@merlin.emma.line.org>

Matthias Andree <ma@dt.e-technik.uni-dortmund.de> writes:

> Gnus displays wide hollow boxes instead of the umlauts in Message-ID:
> <etvq8vonajs2p1llpmfpnl8d0rehmsdu5u@4ax.com> (de.rec.fotografie) -- it
> is declared iso-8859-1 and quoted-printable; but Gnus nicely and
> correctly displays "\200" for a b0rken =80. 

It's not related to QP -- the same would happen if it wasn't QP-encoded.
The real problem is that the article is not in iso-8859-1 as declared,
but in Windows-1252.

FWIW, the umlauts are displayed correctly for me.  That's because I'm
using a Latin-1 locale, while you're probably using UTF-8.

Here's what happens:

* Gnus detects that the message can't possibly be encoded in Latin-1 as
  advertised in the header (because \200 is not a valid character in
  Latin-1).

* It then uses Emacs' charset detection functions to determine the
  charset.  By default, Emacs doesn't know about windows-1252, so it
  isn't detected correctly, and the text is decoded as something else.

* If you're using a Latin-1 locale, then this happens to be displayed
  correctly.

The real way to solve it is to teach Emacs about windows-1252.  That's
possible with `code-pages.el' in CVS Emacs.  With this package loaded
and configured, the €'s are displayed correctly and converted to a
proper charset when you reply.

If you're not using code-pages.el, then it's probably better to use the
declared charset unconditionally, since the most common case of wrong
charset declaration is presumeably windows-125x vs. iso-8859-x.

I've changed the code to skip the auto detection if a charset was
declared in the headers and `code-pages' hasn't been loaded.



  parent reply	other threads:[~2003-04-08 11:48 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-04-07 19:43 Matthias Andree
2003-04-07 22:29 ` Randal L. Schwartz
2003-04-08  5:59   ` Graham Murray
2003-04-10 17:44   ` Matthias Andree
2003-04-08 11:48 ` Jesper Harder [this message]
2003-04-10 19:06   ` Matthias Andree
2003-04-10 19:39     ` Matthias Andree
2003-04-10 23:25       ` Reiner Steib
2003-04-10 20:26     ` Jesper Harder

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m3istpb46j.fsf@defun.localdomain \
    --to=harder@myrealbox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).