emacs-diffs
[Top][All Lists]
Advanced

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

emacs-27 bcd92b5: Improve documentation of Hexl mode


From: Eli Zaretskii
Subject: emacs-27 bcd92b5: Improve documentation of Hexl mode
Date: Tue, 11 May 2021 13:06:45 -0400 (EDT)

branch: emacs-27
commit bcd92b5708083a6c10d4f0aa785cbd69fd8f7035
Author: Eli Zaretskii <eliz@gnu.org>
Commit: Eli Zaretskii <eliz@gnu.org>

    Improve documentation of Hexl mode
    
    * doc/emacs/misc.texi (Editing Binary Files): Explain that Hexl can
    also be used for editing text, including non-ASCII text.
---
 doc/emacs/misc.texi | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/doc/emacs/misc.texi b/doc/emacs/misc.texi
index 6894172..dcbfd75 100644
--- a/doc/emacs/misc.texi
+++ b/doc/emacs/misc.texi
@@ -2566,6 +2566,17 @@ Other Hexl commands let you insert strings (sequences) 
of binary
 bytes, move by @code{short}s or @code{int}s, etc.; type @kbd{C-h a
 hexl-@key{RET}} for details.
 
+  Hexl mode can also be used for editing text files.  This could come
+in handy if the text file includes unusual characters or uses unusual
+encoding (@pxref{Coding Systems}).  For this purpose, Hexl commands
+that insert bytes can also insert @acronym{ASCII} and
+non-@acronym{ASCII} characters, including multibyte characters.  To
+edit a text file with Hexl, visit the file as usual, and then type
+@w{@kbd{M-x hexl-mode @key{RET}}} to switch to Hexl mode.  You can now
+insert text characters by typing them.  However, inserting multibyte
+characters requires special care, to avoid the danger of creating
+invalid multibyte sequences: you should start typing such characters
+when point is on the first byte of a multibyte sequence in the file.
 
 @node Saving Emacs Sessions
 @section Saving Emacs Sessions



reply via email to

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