Re: [evolution-patches] IDN patch for evolution head
- From: Suresh Chandrasekharan <Suresh Chandrasekharan Eng Sun COM>
- To: evolution-patches ximian com
- Subject: Re: [evolution-patches] IDN patch for evolution head
- Date: Mon, 05 Jan 2004 12:43:09 -0800 (PST)
I missed a couple of questions in the prev. mail
LOCALMAP is used for utf8 ( see man libidnkit where this is explained )
IDN_LOCALCONV is the one which is used for local codeset<->utf8 map.
>>
>>does LOCALMAP map to local charsets? Shouldn't it always be utf8?
>>
>>
>>> + if (r == idn_success) {
>>> + if (strcmp (ace_name, t))
>>> + cache_coded_host (ace_name, t);
>>> + d = strdup(ace_name);
>>> + }
>>> +
>>> + g_free (t);
>>> +
>>> + return d;
>>> +#endif
>>> +}
>>> +
>>> +void
>>> +e_uri_show (const char *uri_string, GError **err) {
>>> +#ifndef ENABLE_IDN
>>> + gnome_url_show (uri_string, err);
>>> +#else
>>> + char *t = strdup (uri_string);
>>> +
>>> + e_uri_replace_with_encoded_host (&t);
>>> + gnome_url_show (t, err);
>>> + g_free (t);
>>> +#endif
>>> +}
>>> +
>>> +void
>>> +e_uri_replace_with_encoded_host (char **uri_string)
>>> +{
>>
>>> +void
>>> +e_uri_replace_with_decoded_host (char **uri_string)
>>> +{
****
May be renaming them as described in prev mail will make it more clear ?
*****
>>I think these two are just redundant, far too complex and they save
>>little code in their caller's.
>>
>>> EUri *
>>> e_uri_copy (EUri *uri)
>>> {
>>> @@ -291,6 +530,7 @@
>>> uri_copy->path = g_strdup (uri->path);
>>> uri_copy->query = g_strdup (uri->query);
>>> uri_copy->fragment = g_strdup (uri->fragment);
>>> + uri_copy->host_offset = uri->host_offset;
>>>
>>> /* copy uri->params */
>>> g_datalist_foreach (&uri->params,
>>> Index: e-util/e-url.h
>>> ===================================================================
>>> RCS file: /cvs/gnome/evolution/e-util/e-url.h,v
>>> retrieving revision 1.5
>>> diff -u -r1.5 e-url.h
>>> --- e-util/e-url.h 27 Oct 2001 16:59:34 -0000 1.5
>>> +++ e-util/e-url.h 31 Dec 2003 19:03:09 -0000
>>> @@ -44,6 +44,7 @@
>>> GData *params;
>>> char *query;
>>> char *fragment;
>>> + int host_offset;
>>> } EUri;
>>>
>>> EUri *e_uri_new (const char *uri_string);
>>> @@ -51,6 +52,11 @@
>>> const char *e_uri_get_param (EUri *uri, const char *name);
>>> EUri *e_uri_copy (EUri *uri);
>>> char *e_uri_to_string (EUri *uri, gboolean show_password);
>>> +char *e_uri_encode_host (char *utf8_name);
>>> +char *e_uri_decode_host (char *ace_name);
>>> +void e_uri_replace_with_decoded_host (char **uri_string);
>>> +void e_uri_replace_with_encoded_host (char **uri_string);
>>> +void e_uri_show (const char *uri_string,
>GError **err);
>>>
>>> #endif /* __E_URL_H__ */
>>>
>>> Index: mail/ChangeLog
>>> ===================================================================
>>> RCS file: /cvs/gnome/evolution/mail/ChangeLog,v
>>> retrieving revision 1.2964
>>> diff -u -r1.2964 ChangeLog
>>> --- mail/ChangeLog 22 Dec 2003 14:50:56 -0000 1.2964
>>> +++ mail/ChangeLog 31 Dec 2003 19:03:10 -0000
>>> @@ -1,3 +1,21 @@
>>> +2003-12-27 Suresh Chandrasekharan <suresh chandrasekharan sun com>
>>> +
>>> + * em-folder-view.c: (emfv_format_link_clicked): When a multibyte
>>> + hostname is appearing on a URL, convert it into suitable ASCII
>>> + encoding before passing over to gnome_url_show.
***
OK
****
>>doesn't acgtually describe the change.
>>
>>> + * mail-account-gui.c: (setup_service) Display the mail server name
>>> + in UTF-8 in account set up windows.
>>> +
>>> + * mail-ops.c: (get_folder_desc) Change the output hostname to UTF-8.
>>> +
>>> + * mail-send-recv.c: (format_url) hostname in message when the
>>> + Send/receive button is clicked changed to utf8.
>>> +
>>> + * mail-vfolder.c: (vfolder_adduri_desc) Display utf8 host name in
>>> + 'Updating vfolders for uri' message
>>> +
>>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]