Next: Text Lines, Previous: Word Motion, Up: Motion [Contents][Index]
To move point to the beginning of the buffer, write:
(goto-char (point-min))
Likewise, to move to the end of the buffer, use:
(goto-char (point-max))
Here are two commands that users use to do these things. They are documented here to warn you not to use them in Lisp programs, because they set the mark and display messages in the echo area.
This function moves point to the beginning of the buffer (or the limits
of the accessible portion, when narrowing is in effect), setting the
mark at the previous position. If count is non-nil
, then it
puts point count tenths of the way from the beginning of the buffer.
In an interactive call, count is the numeric prefix argument,
if provided; otherwise count defaults to nil
.
Don’t use this function in Lisp programs!
This function moves point to the end of the buffer (or the limits of
the accessible portion, when narrowing is in effect), setting the mark
at the previous position. If count is non-nil
, then it puts
point count tenths of the way from the end of the buffer.
In an interactive call, count is the numeric prefix argument,
if provided; otherwise count defaults to nil
.
Don’t use this function in Lisp programs!