]> git.eshelyaron.com Git - emacs.git/commitdiff
(Lisp and Coding Systems): Document inhibit-null-byte-detection and
authorEli Zaretskii <eliz@gnu.org>
Sat, 10 Jan 2009 12:02:28 +0000 (12:02 +0000)
committerEli Zaretskii <eliz@gnu.org>
Sat, 10 Jan 2009 12:02:28 +0000 (12:02 +0000)
inhibit-iso-escape-detection.

doc/lispref/ChangeLog
doc/lispref/nonascii.texi

index d89e71d564644a52ce2efc4f9a30e238dc656111..bf6d58f15dbaf24e46cb0eb55c6cd74407724496 100644 (file)
@@ -1,3 +1,8 @@
+2009-01-10  Eli Zaretskii  <eliz@gnu.org>
+
+       * nonascii.texi (Lisp and Coding Systems): Document
+       inhibit-null-byte-detection and inhibit-iso-escape-detection.
+
 2009-01-09  Chong Yidong  <cyd@stupidchicken.com>
 
        * display.texi (Font Lookup): Remove obsolete function
index 421c849f138f83523878478bf7e304df2bce376d..fceabcc3fc166ff539f468a71e1e7267c0099eb3 100644 (file)
@@ -1098,6 +1098,9 @@ If the region contains only @acronym{ASCII} characters except for such
 ISO-2022 control characters ISO-2022 as @code{ESC}, the value is
 @code{undecided} or @code{(undecided)}, or a variant specifying
 end-of-line conversion, if that can be deduced from the text.
+
+If the region contains null bytes, the value is @code{no-conversion},
+even if the region contains text encoded in some coding system.
 @end defun
 
 @defun detect-coding-string string &optional highest
@@ -1105,6 +1108,22 @@ This function is like @code{detect-coding-region} except that it
 operates on the contents of @var{string} instead of bytes in the buffer.
 @end defun
 
+@defvar inhibit-null-byte-detection
+If this variable has a non-@code{nil} value, null bytes are ignored
+when detecting the encoding of a region or a string.  This allows to
+correctly detect the encoding of text that contains null bytes, such
+as Info files with Index nodes.
+@end defvar
+
+@defvar inhibit-iso-escape-detection
+If this variable has a non-@code{nil} value, ISO-2022 escape sequences
+are ignored when detecting the encoding of a region or a string.  The
+result is that no text is ever detected as encoded in some ISO-2022
+encoding, and all escape sequences become visible in a buffer.
+@strong{Warning:} @emph{Use this variable with extreme caution,
+because many files in the Emacs distribution use ISO-2022 encoding.}
+@end defvar
+
 @defun coding-system-charset-list coding-system
 This function returns the list of character sets (@pxref{Character
 Sets}) supported by @var{coding-system}.  Some coding systems that