bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Emacs doesn't write with the encoding it used for reading


From: Rommerskirchen Heinrich
Subject: Emacs doesn't write with the encoding it used for reading
Date: Fri, 5 Apr 2002 14:59:54 +0200

This bug report will be sent to the Free Software Foundation,
not to your local site managers!
Please write in English, because the Emacs maintainers do not have
translators to read other languages for them.

Your bug report will be posted to the address@hidden mailing list,
and to the gnu.emacs.bug news group.

In GNU Emacs 21.2.1 (i386-msvc-nt4.0.1381)
 of 2002-03-19 on buffy
configured using `configure --with-msvc (12.00)'
Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: DEU
  locale-coding-system: iso-latin-1
  default-enable-multibyte-characters: t

If a file contains a mixture of German DOS-encoded text (cp850) and
German Windows-encoded text it is read as latin1 but emacs will not
write it back as latin1.

Simple Example:
A file contains the 4 Bytes 0xE4 0x84 0x0D 0x0A. (Umlaut-a in DOS and Windows
encoding followed by CR LF).

Emacs unter German Windows reads it as latin1. If I now type a
character and delete it again, so that I have the same content,
emacs will not write it back as latin1 but instead suggests a few
encodings with default utf8.

Saving with utf8 gives a file with 6 bytes, which emacs again reads as latin1, 
but doesn't
write as latin1, choosing again utf8 gives a file with 10 bytes and this doesn't
change anymore, but contains neither of the original two characters.

Saving the original file (4 bytes) with raw-text gives a file with 5 bytes which
doesn't change anymore on reading and writing (emacs uses encoding 
raw-text-dos), it contains
the original bytes plus a spurious \201 (Umlaut-u in DOS encoding)

Recent input:
C-x C-f / t e m p / x x <return> <end> SPC <backspace> 
C-x C-s C-g <menu-bar> <help-menu> <report-emacs-b
ug>

Recent messages:
(C:\bin\emacs-21.2\bin\emacs.exe -q --no-site-file)
For information about the GNU Project and its goals, type C-h C-p.
Loading image...done
Loading view...done
byte-code: Quit
Loading emacsbug...done

Regards

Heinz




reply via email to

[Prev in Thread] Current Thread [Next in Thread]