aboutsummaryrefslogtreecommitdiffstats
path: root/src/window.c
diff options
context:
space:
mode:
authorMartin Rudalics2014-03-07 16:11:12 +0100
committerMartin Rudalics2014-03-07 16:11:12 +0100
commit2c6053e8387ca3d60dcc82e702f5a113ce5fb59f (patch)
tree611bdf5c7479e306dbbf46ce7740d64bdcf022ff /src/window.c
parent84254bbdf069f0386f188d0e2bc5be795a9272bb (diff)
downloademacs-2c6053e8387ca3d60dcc82e702f5a113ce5fb59f.tar.gz
emacs-2c6053e8387ca3d60dcc82e702f5a113ce5fb59f.zip
Update docs for select-window and buffer-list-update-hook.
* buffer.c (Vbuffer_list_update_hook): Doc-string fix. * window.c (Fselect_window): Explain NORECORD and `buffer-list-update-hook' in doc-string. * buffers.texi (The Buffer List): Rename node to Buffer List. Describe `buffer-list-update-hook'. * elisp.texi (Top): "The Buffer List" renamed to "Buffer List". Add node for Window Dividers. * hooks.texi (Standard Hooks): Add reference to `buffer-list-update-hook'. * windows.texi (Selecting Windows): Update description of `select-window'.
Diffstat (limited to 'src/window.c')
-rw-r--r--src/window.c15
1 files changed, 12 insertions, 3 deletions
diff --git a/src/window.c b/src/window.c
index 4d8520d7436..f42219cae94 100644
--- a/src/window.c
+++ b/src/window.c
@@ -559,7 +559,7 @@ select_window_1 (Lisp_Object window, bool inhibit_point_swap)
559DEFUN ("select-window", Fselect_window, Sselect_window, 1, 2, 0, 559DEFUN ("select-window", Fselect_window, Sselect_window, 1, 2, 0,
560 doc: /* Select WINDOW which must be a live window. 560 doc: /* Select WINDOW which must be a live window.
561Also make WINDOW's frame the selected frame and WINDOW that frame's 561Also make WINDOW's frame the selected frame and WINDOW that frame's
562selected window. In addition, make WINDOW's buffer current and set that 562selected window. In addition, make WINDOW's buffer current and set its
563buffer's value of `point' to the value of WINDOW's `window-point'. 563buffer's value of `point' to the value of WINDOW's `window-point'.
564Return WINDOW. 564Return WINDOW.
565 565
@@ -567,8 +567,17 @@ Optional second arg NORECORD non-nil means do not put this buffer at the
567front of the buffer list and do not make this window the most recently 567front of the buffer list and do not make this window the most recently
568selected one. 568selected one.
569 569
570Note that the main editor command loop sets the current buffer to the 570Run `buffer-list-update-hook' unless NORECORD is non-nil. Note that
571buffer of the selected window before each command. */) 571applications and internal routines often select a window temporarily for
572various purposes; mostly, to simplify coding. As a rule, such
573selections should be not recorded and therefore will not pollute
574`buffer-list-update-hook'. Selections that "really count" are those
575causing a visible change in the next redisplay of WINDOW's frame and
576should be always recorded. So if you think of running a function each
577time a window gets selected put it on `buffer-list-update-hook'.
578
579Also note that the main editor command loop sets the current buffer to
580the buffer of the selected window before each command. */)
572 (register Lisp_Object window, Lisp_Object norecord) 581 (register Lisp_Object window, Lisp_Object norecord)
573{ 582{
574 return select_window (window, norecord, 0); 583 return select_window (window, norecord, 0);