<<< Date Index >>>     <<< Thread Index >>>

Different encodings at index and pager views



Hi,

I'm noticing different encoding behavior for headers displayed at the
index view and those at the pager view for the same email. For example,
at the index view I can see subjects like: "?Opin? sobre Bebidas
Alcoh?licas y gan? una TV LCD o una Notebook!", while the right chars
show instead of ? at the pager view.

First, I want to discard a number of usual causes:

* It's not a cache header issue. I deleted the cache after each related
configuration change.

* I'm accessing to gmail via imap but it's not a case of bad encoding by
them. True, the headers I'm receiving are not 2047 encoded, they are
just iso-8859-1 or utf-8 encoded, but in theory I'm forcing their
charset by means of assumed_charset (more on this below). That said, I
can't swear that they are not serving the subject with that awful
qmarks themselves, but I don't think so.

* I made some tests with my locale configured to en_US.ISO-8859-1 and
then to en_US.UTF-8. I also tested disabling muttrc charset setting, and
forcing it to my current locale, whatever it were. It did no difference
at all.

To make things weirder, some non 2047 encoded headers are shown
correctly at both views. For example, I have a utf-8 email and a latin-1
email, both with their subject headers encoded in the respective charset
(I verified this editing the raw emails with e). No matter what my
locale is the utf-8 email subject is correctly displayed while the
latin-1 one isn't. Also assumed_charset=iso-8859-1 doesn't fix the
problem for the latin-1 message.

This begins to feel like random behavior but there is another aspect
that could be making the difference: the email that is looking bad is a
multipart one, with no charset specified at the main Content-Type:
multipart/alternative header; but the well behaved email is single part,
with Content-Type: text/plain; charset=UTF-8.

Maybe the index view is assuming the encoding given by Content-Type
header for the subject and other header values, disregarding
assumed_charset in case no encoding is given by Content-Type.

What do you think?

Ah, my mutt version is 1.5.19.

Best regards
-Carlos