KLUDGE! Since neither ETable nor GtkHTML supports UTF-8 yet, output
* camel-mime-utils.c (rfc2047_decode_word): * camel-mime-part-utils.c (simple_data_wrapper_construct_from_parser): * camel-folder-summary.c (summary_build_content_info): KLUDGE! Since neither ETable nor GtkHTML supports UTF-8 yet, output ISO-8859-1 instead, so Ettore can read his Italian mail. :) This will be reverted later. svn path=/trunk/; revision=3597
This commit is contained in:
@ -1,3 +1,12 @@
|
||||
2000-06-16 Dan Winship <danw@helixcode.com>
|
||||
|
||||
* camel-mime-utils.c (rfc2047_decode_word):
|
||||
* camel-mime-part-utils.c (simple_data_wrapper_construct_from_parser):
|
||||
* camel-folder-summary.c (summary_build_content_info):
|
||||
KLUDGE! Since neither ETable nor GtkHTML supports UTF-8 yet,
|
||||
output ISO-8859-1 instead, so Ettore can read his Italian mail. :)
|
||||
This will be reverted later.
|
||||
|
||||
2000-06-15 Jeffrey Stedfast <fejj@helixcode.com>
|
||||
|
||||
* providers/imap/camel-imap-folder.c (imap_get_summary): Started to implement
|
||||
|
||||
@ -1237,18 +1237,18 @@ summary_build_content_info(CamelFolderSummary *s, CamelMimeParser *mp)
|
||||
charset = header_content_type_param(ct, "charset");
|
||||
if (charset!=NULL
|
||||
&& !(strcasecmp(charset, "us-ascii")==0
|
||||
|| strcasecmp(charset, "utf-8")==0)) {
|
||||
d(printf(" Adding conversion filter from %s to utf-8\n", charset));
|
||||
|| strcasecmp(charset, "iso-8859-1")==0)) {
|
||||
d(printf(" Adding conversion filter from %s to iso-8859-1\n", charset));
|
||||
mfc = g_hash_table_lookup(p->filter_charset, charset);
|
||||
if (mfc == NULL) {
|
||||
mfc = camel_mime_filter_charset_new_convert(charset, "utf-8");
|
||||
mfc = camel_mime_filter_charset_new_convert(charset, "iso-8859-1");
|
||||
if (mfc)
|
||||
g_hash_table_insert(p->filter_charset, g_strdup(charset), mfc);
|
||||
}
|
||||
if (mfc) {
|
||||
chr_id = camel_mime_parser_filter_add(mp, (CamelMimeFilter *)mfc);
|
||||
} else {
|
||||
g_warning("Cannot convert '%s' to 'utf-8', message index may be corrupt", charset);
|
||||
g_warning("Cannot convert '%s' to 'iso-8859-1', message index may be corrupt", charset);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -88,13 +88,13 @@ simple_data_wrapper_construct_from_parser(CamelDataWrapper *dw, CamelMimeParser
|
||||
const char *charset = header_content_type_param(ct, "charset");
|
||||
if (charset!=NULL
|
||||
&& !(strcasecmp(charset, "us-ascii")==0
|
||||
|| strcasecmp(charset, "utf-8")==0)) {
|
||||
d(printf("Adding conversion filter from %s to utf-8\n", charset));
|
||||
fch = (CamelMimeFilter *)camel_mime_filter_charset_new_convert(charset, "utf-8");
|
||||
|| strcasecmp(charset, "iso-8859-1")==0)) {
|
||||
d(printf("Adding conversion filter from %s to iso-8859-1\n", charset));
|
||||
fch = (CamelMimeFilter *)camel_mime_filter_charset_new_convert(charset, "iso-8859-1");
|
||||
if (fch) {
|
||||
chrid = camel_mime_parser_filter_add(mp, (CamelMimeFilter *)fch);
|
||||
} else {
|
||||
g_warning("Cannot convert '%s' to 'utf-8', message display may be corrupt", charset);
|
||||
g_warning("Cannot convert '%s' to 'iso-8859-1', message display may be corrupt", charset);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -724,7 +724,7 @@ rfc2047_decode_word(const char *in, int len)
|
||||
outbuf = outbase;
|
||||
|
||||
/* TODO: Should this cache iconv converters? */
|
||||
ic = unicode_iconv_open("utf-8", encname);
|
||||
ic = unicode_iconv_open("iso-8859-1", encname);
|
||||
if (ic != (unicode_iconv_t)-1) {
|
||||
ret = unicode_iconv(ic, (const char **)&inbuf, &inlen, &outbuf, &outlen);
|
||||
unicode_iconv_close(ic);
|
||||
|
||||
Reference in New Issue
Block a user