From: Kenichi Handa <handa@m17n.org>
Cc: bug-gnu-emacs@gnu.org
Subject: Re: detect-coding-string doesn't return all possibilities
Date: Thu, 13 Mar 2003 20:34:27 +0900 (JST) [thread overview]
Message-ID: <200303131134.UAA21300@etlken.m17n.org> (raw)
In-Reply-To: <m3smtw31uq.fsf@defun.localdomain> (message from Jesper Harder on Sun, 09 Mar 2003 18:07:41 +0100)
[-- Attachment #1: Type: text/plain, Size: 1454 bytes --]
Sorry for the late reply.
In article <m3smtw31uq.fsf@defun.localdomain>, Jesper Harder <harder@ifa.au.dk> writes:
> `detect-coding-string' doesn't return all possible coding systems for a
> string. For example:
> (detect-coding-string (encode-coding-string "¾È³ç" 'korean-iso-8bit))
> => (iso-latin-1 iso-latin-1 raw-text chinese-big5 no-conversion)
> Clearly korean-iso-8bit is a possible coding system, but this is not
> detected.
detect-coding-string doesn't return all possible coding
systems, but returns a possible coding systems Emacs may
automatically detect in the current language environment.
Result of (encode-coding-string "¾È³ç" 'korean-iso-8bit) is
a sequence of bytes of the range 0xA0..0xFF.
For instance, if you are in "Latin-1" language environment,
such a byte sequence is detected as iso-latin-1. If you are
in "Korean" language environment, it is detected as
korean-iso-8bit, and in that case, detect-coding-string
returns this: (korean-iso-8bit iso-latin-1 raw-text
chinese-big5 no-conversion)
But the docstring of detect-coding-system is surely not
good. I've just changed the first paragraph as this. How
is it?
Return a list of possible coding systems used on decoding a byte
sequence containing the bytes in STRING when the coding system
`undecided' is specified. The list is ordered by priority decided in
the current language environment.
---
Ken'ichi HANDA
handa@m17n.org
[-- Attachment #2: Type: text/plain, Size: 148 bytes --]
_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/bug-gnu-emacs
next prev parent reply other threads:[~2003-03-13 11:34 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-03-09 17:07 detect-coding-string doesn't return all possibilities Jesper Harder
2003-03-13 11:34 ` Kenichi Handa [this message]
[not found] ` <mailman.3161.1047557974.21513.bug-gnu-emacs@gnu.org>
2003-03-14 4:34 ` Jesper Harder
2003-03-14 4:55 ` Kenichi Handa
2003-03-14 23:04 ` 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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200303131134.UAA21300@etlken.m17n.org \
--to=handa@m17n.org \
--cc=bug-gnu-emacs@gnu.org \
/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.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
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 read-only IMAP folder(s) and NNTP newsgroup(s).