From: "Stefan Monnier" <monnier+gnu.emacs.help/news/@flint.cs.yale.edu>
Subject: Re: problem with editing/decoding utf-8 text
Date: 23 May 2003 17:20:24 -0400 [thread overview]
Message-ID: <5lwugh8inb.fsf@rum.cs.yale.edu> (raw)
In-Reply-To: mailman.6635.1053692285.21513.help-gnu-emacs@gnu.org
> Now, no matter what I choose (raw-text, no-conversion, utf-8), it
> modifies all of the utf8 chars which are not fit into the ascii charset.
> It seems, that it inserts a \201 before every char which is not in the
> ascii charset. I.e. if I just load and save a file, emacs does not
> behaves transparently.
Do you also get the \201 if you choose `utf-8' ?
If so, it's definitely a bug.
> 0. What is this \201 byte?
An internal thing that you shouldn't see unless you ask to see it.
Using `raw-text' or `no-conversion' is debatably considered as "asking to
see it", but utf-8 definitely isn't, so if you see it with utf-8, it's
a bug.
> 1. Cannot I tell to a buffer (after the load of a file) that interpet it
> as binary, and save exactly the same bytes what it did read into the
> buffer (i.e. transparent buffer)?
If you save with the same coding-system as when you loaded, yes.
In your case, you loaded with a latin-1 coding-system and then saved with
another, so obviously Emacs had to do some conversion work and you don't
get the same sequence of byte.
Of course the fact that Emacs happily visited the file in latin-1 but then
refused to save it in latin-1 is a bug. I vaguely seem to remember that
such a bug has been fixed in Emacs-CVS, but it would be great if you could
either check it or report a precise test case.
> 2. What is the difference between raw-text, no-conversion, binary? On
> some places, I can choose any of them, on other places not... This whole
> coding system is a nightmare... :(((
Yes it is but it's not all Emacs fault. The only alternative would be for
Emacs to say "I only ever support 1 encoding". The current code is
supposed to work just fine in this "single encoding" situation while also
allowing you to use other encodings if you want to.
Of course bugs, make this dream a bit less sweet.
Stefan
next prev parent reply other threads:[~2003-05-23 21:20 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <mailman.6635.1053692285.21513.help-gnu-emacs@gnu.org>
2003-05-23 16:50 ` problem with editing/decoding utf-8 text Kai Großjohann
2003-05-23 19:23 ` Oliver Scholz
2003-05-23 20:53 ` Kai Großjohann
2003-05-23 21:20 ` Stefan Monnier [this message]
[not found] <mailman.6818.1054022957.21513.help-gnu-emacs@gnu.org>
2003-05-27 11:10 ` Oliver Scholz
[not found] ` <3ED37785.CA5A9AD5@innomed.hu>
[not found] ` <ubrxnb5m2.fsf@ID-87814.user.dfncis.de>
2003-05-30 12:45 ` Fery
[not found] ` <mailman.7046.1054298932.21513.help-gnu-emacs@gnu.org>
2003-05-30 13:24 ` Kai Großjohann
[not found] <mailman.6770.1053942670.21513.help-gnu-emacs@gnu.org>
2003-05-27 11:05 ` Oliver Scholz
2003-05-27 11:41 ` Oliver Scholz
2003-05-27 8:06 Fery
-- strict thread matches above, loose matches on Subject: below --
2003-05-26 9:47 Fery
2003-05-26 9:47 Fery
2003-05-23 12:08 Fery
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=5lwugh8inb.fsf@rum.cs.yale.edu \
--to=monnier+gnu.emacs.help/news/@flint.cs.yale.edu \
/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.
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).