]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix bug #17511 with unclear documentation of line-move-ignore-invisible.
authorEli Zaretskii <eliz@gnu.org>
Sat, 17 May 2014 08:58:17 +0000 (11:58 +0300)
committerEli Zaretskii <eliz@gnu.org>
Sat, 17 May 2014 08:58:17 +0000 (11:58 +0300)
 lisp/simple.el (line-move-ignore-invisible): Doc fix.

 doc/lispref/display.texi (Invisible Text): Clarify the description of
 line-move-ignore-invisible.

doc/lispref/ChangeLog
doc/lispref/display.texi
lisp/ChangeLog
lisp/simple.el

index 3a82523df2e50eb72b9725410f031ed76f654570..87f2d85cc400ccc07bb3397ffcf242f6ceaef594 100644 (file)
@@ -1,3 +1,8 @@
+2014-05-17  Eli Zaretskii  <eliz@gnu.org>
+
+       * display.texi (Invisible Text): Clarify the description of
+       line-move-ignore-invisible.  (Bug#17511)
+
 2014-05-07  Paul Eggert  <eggert@cs.ucla.edu>
 
        * internals.texi (C Dialect): New section.
index acbef6b9495141799c64e0109f5954ff1fa90e0c..e93f9ab5a4d98fcc5dad647bc8b0ab53f35437a5 100644 (file)
@@ -930,12 +930,14 @@ current value of @code{buffer-invisibility-spec}.
 
 @vindex line-move-ignore-invisible
   Ordinarily, functions that operate on text or move point do not care
-whether the text is invisible.  The user-level line motion commands
-ignore invisible newlines if @code{line-move-ignore-invisible} is
-non-@code{nil} (the default), but only because they are explicitly
-programmed to do so.
-
-  However, if a command ends with point inside or at the boundary of
+whether the text is invisible, they process invisible characters and
+visible characters alike.  The user-level line motion commands,
+such as @code{next-line}, @code{previous-line}, ignore invisible
+newlines if @code{line-move-ignore-invisible} is non-@code{nil} (the
+default), i.e., behave like these invisible newlines didn't exist in
+the buffer, but only because they are explicitly programmed to do so.
+
+  If a command ends with point inside or at the boundary of
 invisible text, the main editing loop relocates point to one of the
 two ends of the invisible text.  Emacs chooses the direction of
 relocation so that it is the same as the overall movement direction of
@@ -952,6 +954,10 @@ command moved point forward into an invisible range, Emacs moves point forward
 to the first visible character that follows the invisible text and then forward
 one more character.
 
+  These @dfn{adjustments} of point that ended up in the middle of
+invisible text can be disabled by setting @code{disable-point-adjustment}
+to a non-@code{nil} value.  @xref{Adjusting Point}.
+
   Incremental search can make invisible overlays visible temporarily
 and/or permanently when a match includes invisible text.  To enable
 this, the overlay should have a non-@code{nil}
index 3907aade58e471fbe2edac2a16d92d9265654a4e..fc18c9d77d82e7818b7be238f46a6d5a6143bee8 100644 (file)
@@ -1,3 +1,7 @@
+2014-05-17  Eli Zaretskii  <eliz@gnu.org>
+
+       * simple.el (line-move-ignore-invisible): Doc fix.  (Bug#17511)
+
 2014-05-16  Michael Albinus  <michael.albinus@gmx.de>
 
        * net/dbus.el (dbus-init-bus, dbus-call-method)
index 36d2d0b3a15ef8a1f69e5d2800b692b53f0f7c23..1b14250e2fdb5e55f462ab0e2b794cb3669b1e9c 100644 (file)
@@ -4978,7 +4978,16 @@ When the `track-eol' feature is doing its job, the value is
 `most-positive-fixnum'.")
 
 (defcustom line-move-ignore-invisible t
-  "Non-nil means \\[next-line] and \\[previous-line] ignore invisible lines.
+  "Non-nil means commands that move by lines ignore invisible newlines.
+
+When this option is non-nil, \\[next-line], \\[previous-line], \\[move-end-of-line], and \\[move-beginning-of-line] behave
+as if newlines that are invisible didn't exist, and count
+only visible newlines.  Thus, moving across across 2 newlines
+one of which is invisible will be counted as a one-line move.
+Also, a non-nil value causes invisible text to be ignored when
+counting columns for the purposes of keeping point in the same
+column by \\[next-line] and \\[previous-line].
+
 Outline mode sets this."
   :type 'boolean
   :group 'editing-basics)