From: Richard Stallman <rms@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: Emacs-diffs Digest, Vol 2, Issue 28
Date: Tue, 21 Jan 2003 13:18:26 -0500 [thread overview]
Message-ID: <E18b2yg-0007yl-00@fencepost.gnu.org> (raw)
In-Reply-To: <200301200152.KAA16258@etlken.m17n.org> (message from Kenichi Handa on Mon, 20 Jan 2003 10:52:31 +0900 (JST))
If we want a multibyte sequence but each character contained
is one of ascii, eight-bit-control, and eight-bit-graphic
corresponding to the original bytes, we must read by
no-conversion, and insert characters one by one as below:
(apply 'insert (string-to-list UNIBYTE-STRING))
Perhaps, we must have a function, say, string-to-multibyte,
and make this enable.
(insert (string-to-multibyte UNIBYTE-STRING))
I think we do need this function string-to-multibyte, and its doc
string should carefully explain how it differs from
string-make-multibyte.
I don't remember why the current code does as above. I
think the behaviour what Eli wrote is more consistent with
the behaviour of file reading.
Shall I change the code as what Eli wrote (by introducing
the new function string-to-multibyte)?
Please do introduce string-to-multibyte. What other change do
you propose? I am not sure how what Eli wrote differs from the
current behavior.
By the way, it may be clean to have all these functions in
parallel, and spare one section describing the difference of
MAKE, AS, TO conversions in info.
string-make-multibyte
string-as-multibyte
string-to-multibyte
These three are all useful.
string-make-unibyte
string-as-unibyte
string-to-unibyte (perpaps the same as string-as-unibyte, or
it should signal an error if non-ascii,
non-eight-bit-XXX is contained).
I don't see a need to add string-to-unibyte.
buffer-make-multibyte
buffer-as-multibyte (same as (set-buffer-multibyte BUFFER t))
buffer-to-multibyte
I don't think buffer-make-multibyte and buffer-to-multibyte are
useful. What is useful is to have functions to operate on a region in
a multibyte buffer, transforming the text between these three
different representations. (Some of the 6 transformations may be
meaningless or impossible; we should only support the meaningful
ones.)
buffer-make-unibyte
buffer-as-unibyte (same as (set-buffer-multibyte BUFFER nil))
buffer-to-nuibyte
I don't think any change here is worth making.
next prev parent reply other threads:[~2003-01-21 18:18 UTC|newest]
Thread overview: 49+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <E18ZDQC-0003mt-02@monty-python.gnu.org>
2003-01-18 0:48 ` Emacs-diffs Digest, Vol 2, Issue 28 Richard Stallman
2003-01-18 12:35 ` Kim F. Storm
2003-01-18 12:40 ` Eli Zaretskii
2003-01-20 0:49 ` Richard Stallman
2003-01-20 2:29 ` unibyte<->multibyte conversion [Re: Emacs-diffs Digest, Vol 2, Issue 28] Kenichi Handa
2003-01-20 18:48 ` Eli Zaretskii
2003-01-20 20:55 ` Stefan Monnier
2003-01-21 0:20 ` Kenichi Handa
2003-01-21 0:54 ` Stefan Monnier
2003-01-21 5:57 ` Eli Zaretskii
2003-01-22 9:59 ` Richard Stallman
2003-01-22 14:12 ` Stefan Monnier
2003-01-22 18:09 ` Eli Zaretskii
2003-01-23 11:38 ` Richard Stallman
2003-01-23 16:18 ` Stefan Monnier
2003-01-24 17:16 ` Richard Stallman
2003-01-23 17:48 ` Eli Zaretskii
2003-01-24 5:43 ` Richard Stallman
2003-01-26 1:30 ` Stefan Monnier
2003-01-27 2:31 ` Richard Stallman
2003-01-27 7:38 ` Kenichi Handa
2003-01-27 14:12 ` Stefan Monnier
2003-01-29 11:23 ` Kenichi Handa
2003-01-21 0:10 ` Kenichi Handa
2003-01-21 0:45 ` Stefan Monnier
2003-01-21 6:01 ` Eli Zaretskii
2003-01-21 6:43 ` Kenichi Handa
2003-01-21 8:04 ` Kenichi Handa
2003-01-21 15:02 ` Miles Bader
2003-01-21 17:44 ` Stefan Monnier
2003-01-22 10:00 ` Richard Stallman
2003-01-21 5:56 ` Eli Zaretskii
2003-01-21 6:38 ` Kenichi Handa
2003-01-22 10:00 ` Richard Stallman
2003-01-22 14:12 ` Stefan Monnier
2003-01-20 1:52 ` Emacs-diffs Digest, Vol 2, Issue 28 Kenichi Handa
2003-01-21 18:18 ` Richard Stallman
2003-01-28 0:32 ` Kenichi Handa
2003-01-28 12:35 ` Kim F. Storm
2003-02-10 8:15 ` set-process-filter-multibyte and etc Kenichi Handa
2003-02-10 14:57 ` Kim F. Storm
2003-02-11 0:15 ` Kenichi Handa
2003-02-20 1:27 ` Tak Ota
2003-02-20 1:56 ` Kenichi Handa
2003-02-20 2:44 ` Tak Ota
2003-03-03 18:59 ` Emacs-diffs Digest, Vol 2, Issue 28 Richard Stallman
2003-01-21 18:18 ` Richard Stallman [this message]
2003-01-27 12:20 ` Kenichi Handa
2003-01-29 0:05 ` Richard Stallman
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=E18b2yg-0007yl-00@fencepost.gnu.org \
--to=rms@gnu.org \
--cc=emacs-devel@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 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.