diff options
| author | Eli Zaretskii | 2008-10-15 11:27:32 +0000 |
|---|---|---|
| committer | Eli Zaretskii | 2008-10-15 11:27:32 +0000 |
| commit | 9cf52b11bbeec82a0ede9fb89fce1033b275e467 (patch) | |
| tree | 5a8eb0559044f8ed4caa88197dc75f758ab9ce4f | |
| parent | 61ab9392dedf37bd379f3bdd586e4f12a2965218 (diff) | |
| download | emacs-9cf52b11bbeec82a0ede9fb89fce1033b275e467.tar.gz emacs-9cf52b11bbeec82a0ede9fb89fce1033b275e467.zip | |
(Major Mode Conventions, Mode Line Variables): `mode-name' need not be a
string. xref to "Mode Line Data" for details, and to "Emulating Mode Line"
for computing a string value.
| -rw-r--r-- | doc/lispref/ChangeLog | 7 | ||||
| -rw-r--r-- | doc/lispref/modes.texi | 13 | ||||
| -rw-r--r-- | etc/NEWS | 1 |
3 files changed, 17 insertions, 4 deletions
diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index b481377cc2d..d00f0cb06a8 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog | |||
| @@ -1,3 +1,10 @@ | |||
| 1 | 2008-10-15 Eli Zaretskii <eliz@gnu.org> | ||
| 2 | |||
| 3 | * modes.texi (Major Mode Conventions, Mode Line Variables): | ||
| 4 | `mode-name' need not be a string. xref to "Mode Line Data" for | ||
| 5 | details, and to "Emulating Mode Line" for computing a string | ||
| 6 | value. | ||
| 7 | |||
| 1 | 2008-10-14 Eli Zaretskii <eliz@gnu.org> | 8 | 2008-10-14 Eli Zaretskii <eliz@gnu.org> |
| 2 | 9 | ||
| 3 | * processes.texi (System Processes): New section. | 10 | * processes.texi (System Processes): New section. |
diff --git a/doc/lispref/modes.texi b/doc/lispref/modes.texi index 3004ca3a934..3227aa3bdc3 100644 --- a/doc/lispref/modes.texi +++ b/doc/lispref/modes.texi | |||
| @@ -317,8 +317,9 @@ which documentation to print. | |||
| 317 | 317 | ||
| 318 | @item | 318 | @item |
| 319 | The major mode command should set the variable @code{mode-name} to the | 319 | The major mode command should set the variable @code{mode-name} to the |
| 320 | ``pretty'' name of the mode, as a string. This string appears in the | 320 | ``pretty'' name of the mode, usually a string (but see @ref{Mode Line |
| 321 | mode line. | 321 | Data}, for other possible forms). The name of the mode appears |
| 322 | in the mode line. | ||
| 322 | 323 | ||
| 323 | @item | 324 | @item |
| 324 | @cindex functions in modes | 325 | @cindex functions in modes |
| @@ -1865,8 +1866,12 @@ effect. | |||
| 1865 | 1866 | ||
| 1866 | @defvar mode-name | 1867 | @defvar mode-name |
| 1867 | This buffer-local variable holds the ``pretty'' name of the current | 1868 | This buffer-local variable holds the ``pretty'' name of the current |
| 1868 | buffer's major mode. Each major mode should set this variable so that the | 1869 | buffer's major mode. Each major mode should set this variable so that |
| 1869 | mode name will appear in the mode line. | 1870 | the mode name will appear in the mode line. The value does not have |
| 1871 | to be a string, but can use any of the data types valid in a mode-line | ||
| 1872 | construct (@pxref{Mode Line Data}). To compute the string that will | ||
| 1873 | identify the mode name in the mode line, use @code{format-mode-line} | ||
| 1874 | (@pxref{Emulating Mode Line}). | ||
| 1870 | @end defvar | 1875 | @end defvar |
| 1871 | 1876 | ||
| 1872 | @defvar mode-line-process | 1877 | @defvar mode-line-process |
| @@ -1068,6 +1068,7 @@ checking/manipulating elements directly, use the new functions | |||
| 1068 | `byte-compile-warning-enabled-p', `byte-compile-disable-warning', and | 1068 | `byte-compile-warning-enabled-p', `byte-compile-disable-warning', and |
| 1069 | `byte-compile-enable-warning.' | 1069 | `byte-compile-enable-warning.' |
| 1070 | 1070 | ||
| 1071 | +++ | ||
| 1071 | ** `mode-name' is no longer guaranteed to be a string. | 1072 | ** `mode-name' is no longer guaranteed to be a string. |
| 1072 | Use `(format-mode-line mode-name)' to ensure a string value. | 1073 | Use `(format-mode-line mode-name)' to ensure a string value. |
| 1073 | 1074 | ||