Mercurial > emacs
annotate lispref/hooks.texi @ 31652:41a7ba41a6ee
*** empty log message ***
author | Gerd Moellmann <gerd@gnu.org> |
---|---|
date | Fri, 15 Sep 2000 21:01:39 +0000 |
parents | d4ac295a98b3 |
children | df31899ab320 |
rev | line source |
---|---|
6440 | 1 @c -*-texinfo-*- |
2 @c This is part of the GNU Emacs Lisp Reference Manual. | |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
3 @c Copyright (C) 1990, 1991, 1992, 1993, 1998 Free Software Foundation, Inc. |
6440 | 4 @c See the file elisp.texi for copying conditions. |
5 @setfilename ../info/hooks | |
12098 | 6 @node Standard Hooks, Index, Standard Keymaps, Top |
6440 | 7 @appendix Standard Hooks |
8 | |
7600 | 9 The following is a list of hook variables that let you provide |
6440 | 10 functions to be called from within Emacs on suitable occasions. |
11 | |
7600 | 12 Most of these variables have names ending with @samp{-hook}. They are |
13 @dfn{normal hooks}, run by means of @code{run-hooks}. The value of such | |
16056
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
14 a hook is a list of functions; the functions are called with no |
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
15 arguments and their values are completely ignored. The recommended way |
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
16 to put a new function on such a hook is to call @code{add-hook}. |
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
17 @xref{Hooks}, for more information about using hooks. |
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
18 |
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
19 The variables whose names end in @samp{-hooks} or @samp{-functions} are |
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
20 usually @dfn{abnormal hooks}; their values are lists of functions, but |
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
21 these functions are called in a special way (they are passed arguments, |
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
22 or their values are used). A few of these variables are actually normal |
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
23 hooks which were named before we established the convention that normal |
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
24 hooks' names should end in @samp{-hook}. |
6440 | 25 |
26 The variables whose names end in @samp{-function} have single functions | |
16056
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
27 as their values. (In older Emacs versions, some of these variables had |
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
28 names ending in @samp{-hook} even though they were not normal hooks; |
bfe1d6597f08
Explain better about abnormal hooks.
Richard M. Stallman <rms@gnu.org>
parents:
12098
diff
changeset
|
29 however, we have renamed all of those.) |
6440 | 30 |
31 @c !!! need xref to where each hook is documented or else document it | |
32 @c by specifying what is expected, and when it is called relative to | |
22138
d4ac295a98b3
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
21007
diff
changeset
|
33 @c mode initialization. |
6440 | 34 |
35 @table @code | |
36 @item activate-mark-hook | |
37 @item after-change-function | |
6782
5b07647ec8f7
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
6440
diff
changeset
|
38 @item after-change-functions |
6440 | 39 @item after-init-hook |
40 @item after-insert-file-functions | |
41 @item after-make-frame-hook | |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
42 @item after-revert-hook |
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
43 @item after-save-hook |
6440 | 44 @item auto-fill-function |
45 @item auto-save-hook | |
46 @item before-change-function | |
6782
5b07647ec8f7
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
6440
diff
changeset
|
47 @item before-change-functions |
6440 | 48 @item before-init-hook |
49 @item before-make-frame-hook | |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
50 @item before-revert-hook |
6440 | 51 @item blink-paren-function |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
52 @item buffer-access-fontify-functions |
6440 | 53 @item c-mode-hook |
54 @item calendar-load-hook | |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
55 @item change-major-mode-hook |
6440 | 56 @item command-history-hook |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
57 @item command-line-functions |
6440 | 58 @item comment-indent-function |
59 @item deactivate-mark-hook | |
60 @item diary-display-hook | |
61 @item diary-hook | |
62 @item dired-mode-hook | |
63 @item disabled-command-hook | |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
64 @item echo-area-clear-hook |
6440 | 65 @item edit-picture-hook |
66 @item electric-buffer-menu-mode-hook | |
67 @item electric-command-history-hook | |
68 @item electric-help-mode-hook | |
69 @item emacs-lisp-mode-hook | |
70 @item find-file-hooks | |
71 @item find-file-not-found-hooks | |
72 @item first-change-hook | |
73 @item fortran-comment-hook | |
74 @item fortran-mode-hook | |
75 @item ftp-setup-write-file-hooks | |
76 @item ftp-write-file-hook | |
77 @item indent-mim-hook | |
78 @item initial-calendar-window-hook | |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
79 @item kill-buffer-hook |
6440 | 80 @item kill-buffer-query-functions |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
81 @item kill-emacs-hook |
6440 | 82 @item kill-emacs-query-functions |
83 @item LaTeX-mode-hook | |
84 @item ledit-mode-hook | |
85 @item lisp-indent-function | |
86 @item lisp-interaction-mode-hook | |
87 @item lisp-mode-hook | |
88 @item list-diary-entries-hook | |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
89 @item local-write-file-hooks |
6440 | 90 @item m2-mode-hook |
91 @item mail-mode-hook | |
92 @item mail-setup-hook | |
93 @item mark-diary-entries-hook | |
94 @item medit-mode-hook | |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
95 @item menu-bar-update-hook |
6440 | 96 @item minibuffer-setup-hook |
6782
5b07647ec8f7
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
6440
diff
changeset
|
97 @item minibuffer-exit-hook |
6440 | 98 @item news-mode-hook |
99 @item news-reply-mode-hook | |
100 @item news-setup-hook | |
101 @item nongregorian-diary-listing-hook | |
102 @item nongregorian-diary-marking-hook | |
103 @item nroff-mode-hook | |
104 @item outline-mode-hook | |
105 @item plain-TeX-mode-hook | |
106 @item post-command-hook | |
107 @item pre-abbrev-expand-hook | |
108 @item pre-command-hook | |
109 @item print-diary-entries-hook | |
110 @item prolog-mode-hook | |
111 @item protect-innocence-hook | |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
112 @item redisplay-end-trigger-functions |
6440 | 113 @item rmail-edit-mode-hook |
114 @item rmail-mode-hook | |
115 @item rmail-summary-mode-hook | |
116 @item scheme-indent-hook | |
117 @item scheme-mode-hook | |
118 @item scribe-mode-hook | |
119 @item shell-mode-hook | |
120 @item shell-set-directory-error-hook | |
121 @item suspend-hook | |
122 @item suspend-resume-hook | |
123 @item temp-buffer-show-function | |
124 @item term-setup-hook | |
125 @item terminal-mode-hook | |
126 @item terminal-mode-break-hook | |
127 @item TeX-mode-hook | |
128 @item text-mode-hook | |
129 @item today-visible-calendar-hook | |
130 @item today-invisible-calendar-hook | |
131 @item vi-mode-hook | |
132 @item view-hook | |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
133 @item window-configuration-change-hook |
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
134 @item window-scroll-functions |
6440 | 135 @item window-setup-hook |
21007
66d807bdc5b4
*** empty log message ***
Richard M. Stallman <rms@gnu.org>
parents:
16056
diff
changeset
|
136 @item window-size-change-functions |
6440 | 137 @item write-contents-hooks |
138 @item write-file-hooks | |
12098 | 139 @item write-region-annotate-functions |
6440 | 140 @end table |