aboutsummaryrefslogtreecommitdiffstats
path: root/lispref
diff options
context:
space:
mode:
authorKaroly Lorentey2005-05-20 17:44:36 +0000
committerKaroly Lorentey2005-05-20 17:44:36 +0000
commitb4bb3cbc7caca5c9c207d9ed42cacb978790af67 (patch)
tree6d347dbb4b2db074171d0bbcb89afe851cffe85b /lispref
parent35bc5d82600f330082298823f09f53259a90ea81 (diff)
parenta18ff9886771c41186eebf8d7984fee2120dbe36 (diff)
downloademacs-b4bb3cbc7caca5c9c207d9ed42cacb978790af67.tar.gz
emacs-b4bb3cbc7caca5c9c207d9ed42cacb978790af67.zip
Merged from miles@gnu.org--gnu-2005 (patch 69, 313-319)
Patches applied: * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-313 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-314 Merge from gnus--rel--5.10 * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-315 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-316 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-317 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-318 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-319 Update from CVS * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-69 Update from CVS git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-347
Diffstat (limited to 'lispref')
-rw-r--r--lispref/ChangeLog25
-rw-r--r--lispref/keymaps.texi1
-rw-r--r--lispref/modes.texi63
3 files changed, 61 insertions, 28 deletions
diff --git a/lispref/ChangeLog b/lispref/ChangeLog
index 2563f22d36b..ad16fe264f0 100644
--- a/lispref/ChangeLog
+++ b/lispref/ChangeLog
@@ -1,3 +1,28 @@
12005-05-19 Luc Teirlinck <teirllm@auburn.edu>
2
3 * keymaps.texi (Active Keymaps): Add anchor.
4
5 * modes.texi (Hooks): Delete confusing and unnecessary sentence.
6 (Major Mode Conventions): Refer to `Auto Major Mode' in more
7 appropriate place.
8 (Derived Modes): Small clarifications.
9 (Minor Mode Conventions, Keymaps and Minor Modes): Replace
10 references to nodes with references to anchors.
11 (Mode Line Data): Warn that `(:eval FORM)' should not load any files.
12 Clarify description of lists whose first element is an integer.
13 (Mode Line Variables): Add anchor.
14 (%-Constructs): Clarify description of integer after %.
15 (Emulating Mode Line): Describe nil value for FACE.
16
172005-05-18 Luc Teirlinck <teirllm@auburn.edu>
18
19 * modes.texi (Derived Modes): Correct references to non-existing
20 variable standard-syntax-table.
21
222005-05-17 Lute Kamstra <lute@gnu.org>
23
24 * modes.texi (Defining Minor Modes): Mention the mode hook.
25
12005-05-15 Kim F. Storm <storm@cua.dk> 262005-05-15 Kim F. Storm <storm@cua.dk>
2 27
3 * processes.texi (Network): Remove open-network-stream-nowait. 28 * processes.texi (Network): Remove open-network-stream-nowait.
diff --git a/lispref/keymaps.texi b/lispref/keymaps.texi
index e1784dd10a0..63832ced1b4 100644
--- a/lispref/keymaps.texi
+++ b/lispref/keymaps.texi
@@ -666,6 +666,7 @@ commands use this function.
666 666
667@c Emacs 19 feature 667@c Emacs 19 feature
668@defvar minor-mode-map-alist 668@defvar minor-mode-map-alist
669@anchor{Definition of minor-mode-map-alist}
669This variable is an alist describing keymaps that may or may not be 670This variable is an alist describing keymaps that may or may not be
670active according to the values of certain variables. Its elements look 671active according to the values of certain variables. Its elements look
671like this: 672like this:
diff --git a/lispref/modes.texi b/lispref/modes.texi
index 9af56fd9d37..1b30a23e128 100644
--- a/lispref/modes.texi
+++ b/lispref/modes.texi
@@ -88,8 +88,7 @@ in Lisp Interaction mode:
88@end example 88@end example
89 89
90 At the appropriate time, Emacs uses the @code{run-hooks} function to 90 At the appropriate time, Emacs uses the @code{run-hooks} function to
91run particular hooks. This function calls the hook functions that have 91run particular hooks.
92been added with @code{add-hook}.
93 92
94@defun run-hooks &rest hookvars 93@defun run-hooks &rest hookvars
95This function takes one or more normal hook variable names as 94This function takes one or more normal hook variable names as
@@ -470,13 +469,13 @@ and Buffer List use this feature.
470@item 469@item
471If you want to make the new mode the default for files with certain 470If you want to make the new mode the default for files with certain
472recognizable names, add an element to @code{auto-mode-alist} to select 471recognizable names, add an element to @code{auto-mode-alist} to select
473the mode for those file names. If you define the mode command to 472the mode for those file names (@pxref{Auto Major Mode}). If you
474autoload, you should add this element in the same file that calls 473define the mode command to autoload, you should add this element in
475@code{autoload}. If you use an autoload cookie for the mode command, 474the same file that calls @code{autoload}. If you use an autoload
476you can also use an autoload cookie for the form that adds the element 475cookie for the mode command, you can also use an autoload cookie for
477(@pxref{autoload cookie}). If you do not autoload the mode command, 476the form that adds the element (@pxref{autoload cookie}). If you do
478it is sufficient to add the element in the file that contains the mode 477not autoload the mode command, it is sufficient to add the element in
479definition. @xref{Auto Major Mode}. 478the file that contains the mode definition.
480 479
481@item 480@item
482In the comments that document the file, you should provide a sample 481In the comments that document the file, you should provide a sample
@@ -1001,7 +1000,7 @@ The new mode has its own syntax table, kept in the variable
1001@code{:syntax-table} keyword (see below). @code{define-derived-mode} 1000@code{:syntax-table} keyword (see below). @code{define-derived-mode}
1002makes the parent mode's syntax-table the parent of 1001makes the parent mode's syntax-table the parent of
1003@code{@var{variant}-syntax-table}, unless the latter is already set 1002@code{@var{variant}-syntax-table}, unless the latter is already set
1004and already has a parent different from @code{standard-syntax-table}. 1003and already has a parent different from the standard syntax table.
1005 1004
1006@item 1005@item
1007The new mode has its own abbrev table, kept in the variable 1006The new mode has its own abbrev table, kept in the variable
@@ -1011,13 +1010,13 @@ The new mode has its own abbrev table, kept in the variable
1011@item 1010@item
1012The new mode has its own mode hook, @code{@var{variant}-hook}. It 1011The new mode has its own mode hook, @code{@var{variant}-hook}. It
1013runs this hook, after running the hooks of its ancestor modes, with 1012runs this hook, after running the hooks of its ancestor modes, with
1014@code{run-mode-hooks} (@pxref{Mode Hooks}). 1013@code{run-mode-hooks}, as the last thing it does. @xref{Mode Hooks}.
1015@end itemize 1014@end itemize
1016 1015
1017In addition, you can specify how to override other aspects of 1016In addition, you can specify how to override other aspects of
1018@var{parent} with @var{body}. The command @var{variant} 1017@var{parent} with @var{body}. The command @var{variant}
1019evaluates the forms in @var{body} after setting up all its usual 1018evaluates the forms in @var{body} after setting up all its usual
1020overrides, just before running @code{@var{variant}-hook}. 1019overrides, just before running the mode hooks.
1021 1020
1022You can also specify @code{nil} for @var{parent}. This gives the new 1021You can also specify @code{nil} for @var{parent}. This gives the new
1023mode no parent. Then @code{define-derived-mode} behaves as described 1022mode no parent. Then @code{define-derived-mode} behaves as described
@@ -1039,7 +1038,7 @@ If this is specified, it is the customization group for this mode.
1039@item :syntax-table 1038@item :syntax-table
1040You can use this to explicitly specify a syntax table for the new 1039You can use this to explicitly specify a syntax table for the new
1041mode. If you specify a @code{nil} value, the new mode uses the same 1040mode. If you specify a @code{nil} value, the new mode uses the same
1042syntax table as @var{parent}, or @code{standard-syntax-table} if 1041syntax table as @var{parent}, or the standard syntax table if
1043@var{parent} is @code{nil}. (Note that this does @emph{not} follow 1042@var{parent} is @code{nil}. (Note that this does @emph{not} follow
1044the convention used for non-keyword arguments that a @code{nil} value 1043the convention used for non-keyword arguments that a @code{nil} value
1045is equivalent with not specifying the argument.) 1044is equivalent with not specifying the argument.)
@@ -1262,8 +1261,9 @@ enable or disable the minor mode based on the raw prefix argument value.
1262 1261
1263@item 1262@item
1264Add an element to @code{minor-mode-alist} for each minor mode 1263Add an element to @code{minor-mode-alist} for each minor mode
1265(@pxref{Mode Line Variables}), if you want to indicate the minor mode in 1264(@pxref{Definition of minor-mode-alist}), if you want to indicate the
1266the mode line. This element should be a list of the following form: 1265minor mode in the mode line. This element should be a list of the
1266following form:
1267 1267
1268@smallexample 1268@smallexample
1269(@var{mode-variable} @var{string}) 1269(@var{mode-variable} @var{string})
@@ -1305,7 +1305,7 @@ should also specify a @code{:set} method which enables the mode by
1305invoking the mode command. Note in the variable's documentation string that 1305invoking the mode command. Note in the variable's documentation string that
1306setting the variable other than via Custom may not take effect. 1306setting the variable other than via Custom may not take effect.
1307 1307
1308 Also mark the definition with an autoload cookie (@pxref{Autoload}), 1308 Also mark the definition with an autoload cookie (@pxref{autoload cookie}),
1309and specify a @code{:require} so that customizing the variable will load 1309and specify a @code{:require} so that customizing the variable will load
1310the library that defines the mode. This will copy suitable definitions 1310the library that defines the mode. This will copy suitable definitions
1311into @file{loaddefs.el} so that users can use @code{customize-option} to 1311into @file{loaddefs.el} so that users can use @code{customize-option} to
@@ -1334,7 +1334,7 @@ use either \\[customize] or the function `msb-mode'."
1334 1334
1335 Each minor mode can have its own keymap, which is active when the mode 1335 Each minor mode can have its own keymap, which is active when the mode
1336is enabled. To set up a keymap for a minor mode, add an element to the 1336is enabled. To set up a keymap for a minor mode, add an element to the
1337alist @code{minor-mode-map-alist}. @xref{Active Keymaps}. 1337alist @code{minor-mode-map-alist}. @xref{Definition of minor-mode-map-alist}.
1338 1338
1339@cindex @code{self-insert-command}, minor modes 1339@cindex @code{self-insert-command}, minor modes
1340 One use of minor mode keymaps is to modify the behavior of certain 1340 One use of minor mode keymaps is to modify the behavior of certain
@@ -1408,9 +1408,10 @@ This is equivalent to specifying @var{keymap} positionally.
1408Any other keyword arguments are passed passed directly to the 1408Any other keyword arguments are passed passed directly to the
1409@code{defcustom} generated for the variable @var{mode}. 1409@code{defcustom} generated for the variable @var{mode}.
1410 1410
1411The command named @var{mode} finishes by executing the @var{body} forms, 1411The command named @var{mode} first performs the standard actions such
1412if any, after it has performed the standard actions such as setting 1412as setting the variable named @var{mode} and then executes the
1413the variable named @var{mode}. 1413@var{body} forms, if any. It finishes by running the mode hook
1414variable @code{@var{mode}-hook}.
1414@end defmac 1415@end defmac
1415 1416
1416@findex easy-mmode-define-minor-mode 1417@findex easy-mmode-define-minor-mode
@@ -1627,7 +1628,9 @@ common form of mode-line construct.
1627 1628
1628@item (:eval @var{form}) 1629@item (:eval @var{form})
1629A list whose first element is the symbol @code{:eval} says to evaluate 1630A list whose first element is the symbol @code{:eval} says to evaluate
1630@var{form}, and use the result as a string to display. 1631@var{form}, and use the result as a string to display. Make sure this
1632evaluation cannot load any files, as doing so could cause infinite
1633recursion.
1631 1634
1632@item (:propertize @var{elt} @var{props}@dots{}) 1635@item (:propertize @var{elt} @var{props}@dots{})
1633A list whose first element is the symbol @code{:propertize} says to 1636A list whose first element is the symbol @code{:propertize} says to
@@ -1649,9 +1652,10 @@ the value of @var{symbol} is @code{nil}.
1649A list whose first element is an integer specifies truncation or 1652A list whose first element is an integer specifies truncation or
1650padding of the results of @var{rest}. The remaining elements 1653padding of the results of @var{rest}. The remaining elements
1651@var{rest} are processed recursively as mode-line constructs and 1654@var{rest} are processed recursively as mode-line constructs and
1652concatenated together. Then the result is space filled (if 1655concatenated together. When @var{width} is positive, the result is
1653@var{width} is positive) or truncated (to @minus{}@var{width} columns, 1656space filled on the right if its width is less than @var{width}. When
1654if @var{width} is negative) on the right. 1657@var{width} is negative, the result is truncated on the right to
1658@minus{}@var{width} columns if its width exceeds @minus{}@var{width}.
1655 1659
1656For example, the usual way to show what percentage of a buffer is above 1660For example, the usual way to show what percentage of a buffer is above
1657the top of the window is to use a list like this: @code{(-3 "%p")}. 1661the top of the window is to use a list like this: @code{(-3 "%p")}.
@@ -1817,6 +1821,7 @@ is @code{nil}.
1817@end defvar 1821@end defvar
1818 1822
1819@defvar minor-mode-alist 1823@defvar minor-mode-alist
1824@anchor{Definition of minor-mode-alist}
1820This variable holds an association list whose elements specify how the 1825This variable holds an association list whose elements specify how the
1821mode line should indicate that a minor mode is active. Each element of 1826mode line should indicate that a minor mode is active. Each element of
1822the @code{minor-mode-alist} should be a two-element list: 1827the @code{minor-mode-alist} should be a two-element list:
@@ -1888,7 +1893,8 @@ specifies addition of text properties.
1888 1893
1889 The following table lists the recognized @code{%}-constructs and what 1894 The following table lists the recognized @code{%}-constructs and what
1890they mean. In any construct except @samp{%%}, you can add a decimal 1895they mean. In any construct except @samp{%%}, you can add a decimal
1891integer after the @samp{%} to specify how many characters to display. 1896integer after the @samp{%} to specify a minimum field width. If the
1897width is less, the field is padded with spaces to the right.
1892 1898
1893@table @code 1899@table @code
1894@item %b 1900@item %b
@@ -1993,7 +1999,7 @@ The value of @code{global-mode-string}. Currently, only
1993 1999
1994 Certain text properties are meaningful in the 2000 Certain text properties are meaningful in the
1995mode line. The @code{face} property affects the appearance of text; the 2001mode line. The @code{face} property affects the appearance of text; the
1996@code{help-echo} property associate help strings with the text, and 2002@code{help-echo} property associates help strings with the text, and
1997@code{local-map} can make the text mouse-sensitive. 2003@code{local-map} can make the text mouse-sensitive.
1998 2004
1999 There are four ways to specify text properties for text in the mode 2005 There are four ways to specify text properties for text in the mode
@@ -2061,7 +2067,7 @@ It is normally @code{nil}, so that ordinary buffers have no header line.
2061 2067
2062 You can use the function @code{format-mode-line} to compute 2068 You can use the function @code{format-mode-line} to compute
2063the text that would appear in a mode line or header line 2069the text that would appear in a mode line or header line
2064based on certain mode-line specification. 2070based on a certain mode-line specification.
2065 2071
2066@defun format-mode-line format &optional face window buffer 2072@defun format-mode-line format &optional face window buffer
2067This function formats a line of text according to @var{format} as if 2073This function formats a line of text according to @var{format} as if
@@ -2077,7 +2083,8 @@ faces, keymaps, etc., that the mode line would have. And any character
2077for which no @code{face} property is specified gets a default 2083for which no @code{face} property is specified gets a default
2078value which is usually @var{face}. (If @var{face} is @code{t}, 2084value which is usually @var{face}. (If @var{face} is @code{t},
2079that stands for either @code{mode-line} if @var{window} is selected, 2085that stands for either @code{mode-line} if @var{window} is selected,
2080otherwise @code{mode-line-inactive}.) 2086otherwise @code{mode-line-inactive}. If @var{face} is @code{nil} or
2087omitted, that stands for no face property.)
2081 2088
2082However, if @var{face} is an integer, the value has no text properties. 2089However, if @var{face} is an integer, the value has no text properties.
2083 2090