all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* determining process coding
@ 2015-02-12 10:24 Eric Abrahamsen
  2015-02-12 15:45 ` Eli Zaretskii
  0 siblings, 1 reply; 7+ messages in thread
From: Eric Abrahamsen @ 2015-02-12 10:24 UTC (permalink / raw)
  To: help-gnu-emacs

I've been trying for a while to improve Gnus' ability to search for
multibyte strings on IMAP servers, by sending in a charset and a string
literal as part of the SEARCH command. So instead of this:

. UID SEARCH SUBJECT "metal band"

we can send this:

. UID SEARCH CHARSET UTF-8 SUBJECT {10+}
Motörhead

The details aren't terribly interesting, basically you specify a
charset, and the number of string bytes in brackets, then send the
string itself on a separate line.

I'm having two problems: 1) I don't really know how to determine the
proper charset to use, and 2) some IMAP servers (*cough* exchange
*cough*) don't accept many charsets, including utf-8.

Number 2 can only be worked around, but number 1 should be resolvable.

Gnus opens a long-running connection to an IMAP server through a process
buffer, and while playing with the code, I tried (process-coding-system
(get-buffer-process (current-buffer))) while the IMAP buffer was
current, and it gave me (binary . binary). I'm not sure what to do with
that information. Searching this very server using utf-8 works just
fine, so I'm assuming that I'm coming to some sort of fallback value.

Can anyone tell me how to reliably tell what coding system Gnus will use
to send strings (with `process-send-string') to the IMAP server?

Bonus points for any wisdom regarding dealing with IMAP servers that
don't accept UTF-8.

Thanks for any pointers,
Eric




^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2015-02-21  4:21 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-12 10:24 determining process coding Eric Abrahamsen
2015-02-12 15:45 ` Eli Zaretskii
2015-02-13  4:27   ` Eric Abrahamsen
2015-02-13  8:41     ` Eli Zaretskii
2015-02-18  3:49       ` Eric Abrahamsen
2015-02-18 15:22         ` Eli Zaretskii
2015-02-21  4:21           ` Eric Abrahamsen

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.