view lispref/hooks.texi @ 83310:e58cb448e07c

Merged from miles@gnu.org--gnu-2005 (patch 80-82, 350-422) Patches applied: * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-350 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-351 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-352 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-353 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-354 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-355 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-356 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-357 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-358 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-359 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-360 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-361 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-362 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-363 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-364 Remove "-face" suffix from widget faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-365 Remove "-face" suffix from custom faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-366 Remove "-face" suffix from change-log faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-367 Remove "-face" suffix from compilation faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-368 Remove "-face" suffix from diff-mode faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-369 lisp/longlines.el (longlines-visible-face): Face removed * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-370 Remove "-face" suffix from woman faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-371 Remove "-face" suffix from whitespace-highlight face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-372 Remove "-face" suffix from ruler-mode faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-373 Remove "-face" suffix from show-paren faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-374 Remove "-face" suffix from log-view faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-375 Remove "-face" suffix from smerge faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-376 Remove "-face" suffix from show-tabs faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-377 Remove "-face" suffix from highlight-changes faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-378 Remove "-face" suffix from and downcase info faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-379 Remove "-face" suffix from pcvs faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-380 Update uses of renamed pcvs faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-381 Tweak ChangeLog * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-382 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-383 Remove "-face" suffix from strokes-char face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-384 Remove "-face" suffix from compare-windows face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-385 Remove "-face" suffix from calendar faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-386 Remove "-face" suffix from diary-button face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-387 Remove "-face" suffix from testcover faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-388 Remove "-face" suffix from viper faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-389 Remove "-face" suffix from org faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-390 Remove "-face" suffix from sgml-namespace face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-391 Remove "-face" suffix from table-cell face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-392 Remove "-face" suffix from tex-mode faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-393 Remove "-face" suffix from texinfo-heading face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-394 Remove "-face" suffix from flyspell faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-395 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-396 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-397 Remove "-face" suffix from gomoku faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-398 Remove "-face" suffix from mpuz faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-399 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-400 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-401 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-402 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-403 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-404 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-405 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-406 Merge from gnus--rel--5.10 * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-407 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-408 Remove "-face" suffix from Buffer-menu-buffer face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-409 Remove "-face" suffix from antlr-mode faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-410 Remove "-face" suffix from ebrowse faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-411 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-412 Remove "-face" suffix from flymake faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-413 Remove "-face" suffix from idlwave faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-414 Remove "-face" suffix from sh-script faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-415 Remove "-face" suffix from vhdl-mode faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-416 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-417 Remove "-face" suffix from which-func face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-418 Remove "-face" suffix from cperl-mode faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-419 Remove "-face" suffix from ld-script faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-420 Fix cperl-mode font-lock problem * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-421 Tweak which-func face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-422 Update from CVS * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-80 Merge from emacs--cvs-trunk--0 * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-81 Update from CVS * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-82 Update from CVS git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-350
author Karoly Lorentey <lorentey@elte.hu>
date Wed, 15 Jun 2005 12:57:51 +0000
parents 100e0fab95e5
children c4030bc2f36d 08185296b491
line wrap: on
line source

@c -*-texinfo-*-
@c This is part of the GNU Emacs Lisp Reference Manual.
@c Copyright (C) 1990, 1991, 1992, 1993, 1998, 2004, 2005 Free Software Foundation, Inc.
@c See the file elisp.texi for copying conditions.
@setfilename ../info/hooks
@node Standard Hooks, Index, Standard Keymaps, Top
@appendix Standard Hooks

The following is a list of hook variables that let you provide
functions to be called from within Emacs on suitable occasions.

Most of these variables have names ending with @samp{-hook}.  They are
@dfn{normal hooks}, run by means of @code{run-hooks}.  The value of such
a hook is a list of functions; the functions are called with no
arguments and their values are completely ignored.  The recommended way
to put a new function on such a hook is to call @code{add-hook}.
@xref{Hooks}, for more information about using hooks.

Every major mode defines a mode hook named
@samp{@var{modename}-mode-hook}.  The major mode command runs this
normal hook with @code{run-mode-hooks} as the very last thing it does.
@xref{Mode Hooks}.  Most minor modes have mode hooks too.  Mode hooks
are omitted in the list below.

The variables whose names end in @samp{-hooks} or @samp{-functions} are
usually @dfn{abnormal hooks}; their values are lists of functions, but
these functions are called in a special way (they are passed arguments,
or their values are used).  A few of these variables are actually normal
hooks which were named before we established the convention that normal
hooks' names should end in @samp{-hook}.

The variables whose names end in @samp{-function} have single functions
as their values.  (In older Emacs versions, some of these variables had
names ending in @samp{-hook} even though they were not normal hooks;
however, we have renamed all of those.)

@c We need to xref to where each hook is documented or else document
@c it here.

@table @code
@item activate-mark-hook
@xref{The Mark}.

@item after-change-functions
@xref{Change Hooks}.

@item after-change-major-mode-hook
@xref{Mode Hooks}.

@item after-init-hook
@xref{Init File}.

@item after-insert-file-functions
@xref{Saving Properties}.

@item after-make-frame-functions
@xref{Creating Frames}.

@item after-revert-hook
@xref{Reverting}.

@item after-save-hook
@xref{Saving Buffers}.

@item auto-fill-function
@xref{Auto Filling}.

@item auto-save-hook
@xref{Auto-Saving}.

@item before-change-functions
@xref{Change Hooks}.

@item before-init-hook
@xref{Init File}.

@item before-make-frame-hook
@xref{Creating Frames}.

@item before-revert-hook
@xref{Reverting}.

@item before-save-hook
@xref{Saving Buffers}.

@item blink-paren-function
@xref{Blinking}.

@item buffer-access-fontify-functions
@xref{Lazy Properties}.

@item calendar-load-hook
@inforef{Calendar Customizing,, emacs-xtra}.

@item change-major-mode-hook
@xref{Creating Buffer-Local}.

@item command-line-functions
@xref{Command-Line Arguments}.

@item comment-indent-function
@xref{Options for Comments,, Options Controlling Comments, emacs, the
GNU Emacs Manual}.

@item custom-define-hook
Hook called after defining each customize option.

@item deactivate-mark-hook
@xref{The Mark}.

@item desktop-after-read-hook
Normal hook run after a successful @code{desktop-read}.  May be used
to show a buffer list.  @xref{Saving Emacs Sessions,, Saving Emacs
Sessions, emacs, the GNU Emacs Manual}.

@item desktop-no-desktop-file-hook
Normal hook run when @code{desktop-read} can't find a desktop file.
May be used to show a dired buffer.  @xref{Saving Emacs Sessions,,
Saving Emacs Sessions, emacs, the GNU Emacs Manual}.

@item desktop-save-hook
Normal hook run before the desktop is saved in a desktop file.  This
is useful for truncating history lists, for example.  @xref{Saving
Emacs Sessions,, Saving Emacs Sessions, emacs, the GNU Emacs Manual}.

@item diary-display-hook
@inforef{Fancy Diary Display,, emacs-xtra}.

@item diary-hook
List of functions called after the display of the diary.  Can be used
for appointment notification.

@item disabled-command-function
@xref{Disabling Commands}.

@item echo-area-clear-hook
@xref{The Echo Area}.

@item emacs-startup-hook
@xref{Init File}.

@item find-file-hook
@xref{Visiting Functions}.

@item find-file-not-found-functions
@xref{Visiting Functions}.

@item first-change-hook
@xref{Change Hooks}.

@item font-lock-beginning-of-syntax-function
@xref{Syntactic Font Lock}.

@item font-lock-fontify-buffer-function
@xref{Other Font Lock Variables}.

@item font-lock-fontify-region-function
@xref{Other Font Lock Variables}.

@item font-lock-mark-block-function
@xref{Other Font Lock Variables}.

@item font-lock-syntactic-face-function
@xref{Syntactic Font Lock}.

@item font-lock-unfontify-buffer-function
@xref{Other Font Lock Variables}.

@item font-lock-unfontify-region-function
@xref{Other Font Lock Variables}.

@item initial-calendar-window-hook
@inforef{Calendar Customizing,, emacs-xtra}.

@item kbd-macro-termination-hook
@xref{Keyboard Macros}.

@item kill-buffer-hook
@xref{Killing Buffers}.

@item kill-buffer-query-functions
@xref{Killing Buffers}.

@item kill-emacs-hook
@xref{Killing Emacs}.

@item kill-emacs-query-functions
@xref{Killing Emacs}.

@item lisp-indent-function

@item list-diary-entries-hook
@inforef{Fancy Diary Display,, emacs-xtra}.

@item mail-setup-hook
@xref{Mail Mode Misc,, Mail Mode Miscellany, emacs, the GNU Emacs
Manual}.

@item mark-diary-entries-hook
@inforef{Fancy Diary Display,, emacs-xtra}.

@item menu-bar-update-hook
@xref{Menu Bar}.

@item minibuffer-setup-hook
@xref{Minibuffer Misc}.

@item minibuffer-exit-hook
@xref{Minibuffer Misc}.

@item mouse-position-function
@xref{Mouse Position}.

@item nongregorian-diary-listing-hook
@inforef{Hebrew/Islamic Entries,, emacs-xtra}.

@item nongregorian-diary-marking-hook
@inforef{Hebrew/Islamic Entries,, emacs-xtra}.

@item post-command-hook
@xref{Command Overview}.

@item pre-abbrev-expand-hook
@xref{Abbrev Expansion}.

@item pre-command-hook
@xref{Command Overview}.

@item print-diary-entries-hook
@inforef{Diary Customizing,, emacs-xtra}.

@item redisplay-end-trigger-functions
@xref{Window Hooks}.

@item scheme-indent-function

@item suspend-hook
@xref{Suspending Emacs}.

@item suspend-resume-hook
@xref{Suspending Emacs}.

@item temp-buffer-setup-hook
@xref{Temporary Displays}.

@item temp-buffer-show-function
@xref{Temporary Displays}.

@item temp-buffer-show-hook
@xref{Temporary Displays}.

@item term-setup-hook
@xref{Terminal-Specific}.

@item today-visible-calendar-hook
@inforef{Calendar Customizing,, emacs-xtra}.

@item today-invisible-calendar-hook
@inforef{Calendar Customizing,, emacs-xtra}.

@item window-configuration-change-hook
@xref{Window Hooks}.

@item window-scroll-functions
@xref{Window Hooks}.

@item window-setup-hook
@xref{Window Systems}.

@item window-size-change-functions
@xref{Window Hooks}.

@item write-contents-functions
@xref{Saving Buffers}.

@item write-file-functions
@xref{Saving Buffers}.

@item write-region-annotate-functions
@xref{Saving Properties}.
@end table

@ignore
   arch-tag: 55fd0296-d906-4551-b300-979d3846aa88
@end ignore