[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] emacs-25 db0b58d: Correct the statement about programming
From: |
Alan Mackenzie |
Subject: |
[Emacs-diffs] emacs-25 db0b58d: Correct the statement about programming modes always running prog-mode-hook. |
Date: |
Thu, 10 Nov 2016 21:24:22 +0000 (UTC) |
branch: emacs-25
commit db0b58da1d1e5724c783550103fcf5bb363bb713
Author: Alan Mackenzie <address@hidden>
Commit: Alan Mackenzie <address@hidden>
Correct the statement about programming modes always running prog-mode-hook.
doc/emacs/modes.texi (Major Modes): Amend the statement about programming
modes running prog-mode-hook to say that it applies to many (not all) such
modes, and specifying exactly which modes.
---
doc/emacs/modes.texi | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/doc/emacs/modes.texi b/doc/emacs/modes.texi
index c1564e9..63e31ab 100644
--- a/doc/emacs/modes.texi
+++ b/doc/emacs/modes.texi
@@ -113,10 +113,13 @@ hook}, a customizable list of Lisp functions to run each
time the mode
is enabled in a buffer. @xref{Hooks}, for more information about
hooks. Each mode hook is named after its major mode, e.g., Fortran
mode has @code{fortran-mode-hook}. Furthermore, all text-based major
-modes run @code{text-mode-hook}, and all programming language modes
-run @code{prog-mode-hook}, prior to running their own mode hooks.
-Hook functions can look at the value of the variable @code{major-mode}
-to see which mode is actually being entered.
+modes run @code{text-mode-hook}, and many programming language modes
address@hidden specifically, the modes which are ''derived'' from
address@hidden (@pxref{Derived Modes,,, elisp, The Emacs Lisp
+Reference Manual}).} (including all those distributed with Emacs) run
address@hidden, prior to running their own mode hooks. Hook
+functions can look at the value of the variable @code{major-mode} to
+see which mode is actually being entered.
Mode hooks are commonly used to enable minor modes (@pxref{Minor
Modes}). For example, you can put the following lines in your init
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] emacs-25 db0b58d: Correct the statement about programming modes always running prog-mode-hook.,
Alan Mackenzie <=