aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lispref/positions.texi78
1 files changed, 41 insertions, 37 deletions
diff --git a/lispref/positions.texi b/lispref/positions.texi
index 32e423efdbc..282f897ebab 100644
--- a/lispref/positions.texi
+++ b/lispref/positions.texi
@@ -165,23 +165,20 @@ minibuffer.
165@c @kindex end-of-buffer 165@c @kindex end-of-buffer
166This function moves point @var{count} characters forward, towards the 166This function moves point @var{count} characters forward, towards the
167end of the buffer (or backward, towards the beginning of the buffer, if 167end of the buffer (or backward, towards the beginning of the buffer, if
168@var{count} is negative). If the function attempts to move point past 168@var{count} is negative). If @var{count} is @code{nil}, the default
169the beginning or end of the buffer (or the limits of the accessible 169is 1.
170portion, when narrowing is in effect), an error is signaled with error 170
171code @code{beginning-of-buffer} or @code{end-of-buffer}. 171If this attempts to move past the beginning or end of the buffer (or
172the limits of the accessible portion, when narrowing is in effect), it
173signals an error with error symbol @code{beginning-of-buffer} or
174@code{end-of-buffer}.
172 175
173In an interactive call, @var{count} is the numeric prefix argument. 176In an interactive call, @var{count} is the numeric prefix argument.
174@end deffn 177@end deffn
175 178
176@deffn Command backward-char &optional count 179@deffn Command backward-char &optional count
177This function moves point @var{count} characters backward, towards the 180This is just like @code{forward-char} except that it moves
178beginning of the buffer (or forward, towards the end of the buffer, if 181in the opposite direction.
179@var{count} is negative). If the function attempts to move point past
180the beginning or end of the buffer (or the limits of the accessible
181portion, when narrowing is in effect), an error is signaled with error
182code @code{beginning-of-buffer} or @code{end-of-buffer}.
183
184In an interactive call, @var{count} is the numeric prefix argument.
185@end deffn 182@end deffn
186 183
187@node Word Motion 184@node Word Motion
@@ -192,12 +189,15 @@ whether a given character is part of a word. @xref{Syntax Tables}.
192 189
193@deffn Command forward-word &optional count 190@deffn Command forward-word &optional count
194This function moves point forward @var{count} words (or backward if 191This function moves point forward @var{count} words (or backward if
195@var{count} is negative). ``Moving one word'' means moving until point 192@var{count} is negative). If @var{count} is @code{nil}, it moves
196crosses a word-constituent character and then encounters a 193forward one word.
197word-separator character. However, this function cannot move point past 194
198the boundary of the accessible portion of the buffer, or across a field 195``Moving one word'' means moving until point crosses a
199boundary (@pxref{Fields}). The most common case of a field boundary is 196word-constituent character and then encounters a word-separator
200the end of the prompt in the minibuffer. 197character. However, this function cannot move point past the boundary
198of the accessible portion of the buffer, or across a field boundary
199(@pxref{Fields}). The most common case of a field boundary is the end
200of the prompt in the minibuffer.
201 201
202If it is possible to move @var{count} words, without being stopped 202If it is possible to move @var{count} words, without being stopped
203prematurely by the buffer boundary or a field boundary, the value is 203prematurely by the buffer boundary or a field boundary, the value is
@@ -258,22 +258,24 @@ they set the mark and display messages in the echo area.
258@deffn Command beginning-of-buffer &optional n 258@deffn Command beginning-of-buffer &optional n
259This function moves point to the beginning of the buffer (or the limits 259This function moves point to the beginning of the buffer (or the limits
260of the accessible portion, when narrowing is in effect), setting the 260of the accessible portion, when narrowing is in effect), setting the
261mark at the previous position. If @var{n} is non-@code{nil}, then it 261mark at the previous position (except in Transient Mark mode, if
262puts point @var{n} tenths of the way from the beginning of the 262the mark is already active, it does not set the mark.)
263accessible portion of the buffer.
264 263
265In an interactive call, @var{n} is the numeric prefix argument, 264If @var{n} is non-@code{nil}, then it puts point @var{n} tenths of the
266if provided; otherwise @var{n} defaults to @code{nil}. 265way from the beginning of the accessible portion of the buffer. In an
266interactive call, @var{n} is the numeric prefix argument, if provided;
267otherwise @var{n} defaults to @code{nil}.
267 268
268@strong{Warning:} Don't use this function in Lisp programs! 269@strong{Warning:} Don't use this function in Lisp programs!
269@end deffn 270@end deffn
270 271
271@deffn Command end-of-buffer &optional n 272@deffn Command end-of-buffer &optional n
272This function moves point to the end of the buffer (or the limits of the 273This function moves point to the end of the buffer (or the limits of
273accessible portion, when narrowing is in effect), setting the mark at 274the accessible portion, when narrowing is in effect), setting the mark
274the previous position. If @var{n} is non-@code{nil}, then it puts point 275at the previous position (except in Transient Mark mode when the mark
275@var{n} tenths of the way from the end of the accessible portion of the 276is already active). If @var{n} is non-@code{nil}, then it puts point
276buffer. 277@var{n} tenths of the way from the end of the accessible portion of
278the buffer.
277 279
278In an interactive call, @var{n} is the numeric prefix argument, 280In an interactive call, @var{n} is the numeric prefix argument,
279if provided; otherwise @var{n} defaults to @code{nil}. 281if provided; otherwise @var{n} defaults to @code{nil}.
@@ -373,7 +375,7 @@ This function moves point forward @var{count} lines, to the beginning of
373the line. If @var{count} is negative, it moves point 375the line. If @var{count} is negative, it moves point
374@minus{}@var{count} lines backward, to the beginning of a line. If 376@minus{}@var{count} lines backward, to the beginning of a line. If
375@var{count} is zero, it moves point to the beginning of the current 377@var{count} is zero, it moves point to the beginning of the current
376line. 378line. If @var{count} is @code{nil}, that means 1.
377 379
378If @code{forward-line} encounters the beginning or end of the buffer (or 380If @code{forward-line} encounters the beginning or end of the buffer (or
379of the accessible portion) before finding that many lines, it sets point 381of the accessible portion) before finding that many lines, it sets point
@@ -703,13 +705,15 @@ This function moves backward across @var{arg} (default 1) balanced expressions.
703@deffn Command beginning-of-defun &optional arg 705@deffn Command beginning-of-defun &optional arg
704This function moves back to the @var{arg}th beginning of a defun. If 706This function moves back to the @var{arg}th beginning of a defun. If
705@var{arg} is negative, this actually moves forward, but it still moves 707@var{arg} is negative, this actually moves forward, but it still moves
706to the beginning of a defun, not to the end of one. 708to the beginning of a defun, not to the end of one. @var{arg} defaults
709to 1.
707@end deffn 710@end deffn
708 711
709@deffn Command end-of-defun &optional arg 712@deffn Command end-of-defun &optional arg
710This function moves forward to the @var{arg}th end of a defun. If 713This function moves forward to the @var{arg}th end of a defun. If
711@var{arg} is negative, this actually moves backward, but it still moves 714@var{arg} is negative, this actually moves backward, but it still moves
712to the end of a defun, not to the beginning of one. 715to the end of a defun, not to the beginning of one. @var{arg} defaults
716to 1.
713@end deffn 717@end deffn
714 718
715@defopt defun-prompt-regexp 719@defopt defun-prompt-regexp
@@ -761,12 +765,12 @@ then advances point if the character matches @var{character-set}. This
761continues until it reaches a character that does not match. The 765continues until it reaches a character that does not match. The
762function returns the number of characters moved over. 766function returns the number of characters moved over.
763 767
764The argument @var{character-set} is like the inside of a 768The argument @var{character-set} is a string, like the inside of a
765@samp{[@dots{}]} in a regular expression except that @samp{]} is never 769@samp{[@dots{}]} in a regular expression except that @samp{]} does not
766special and @samp{\} quotes @samp{^}, @samp{-} or @samp{\}. Thus, 770terminate it, and @samp{\} quotes @samp{^}, @samp{-} or @samp{\}.
767@code{"a-zA-Z"} skips over all letters, stopping before the first 771Thus, @code{"a-zA-Z"} skips over all letters, stopping before the
768nonletter, and @code{"^a-zA-Z"} skips nonletters stopping before the 772first nonletter, and @code{"^a-zA-Z"} skips nonletters stopping before
769first letter. @xref{Regular Expressions}. 773the first letter. @xref{Regular Expressions}.
770 774
771If @var{limit} is supplied (it must be a number or a marker), it 775If @var{limit} is supplied (it must be a number or a marker), it
772specifies the maximum position in the buffer that point can be skipped 776specifies the maximum position in the buffer that point can be skipped