; Improve documentation of last changeset (bug#69305)

* etc/NEWS (Example):
* doc/lispref/modes.texi (Tabulated List Mode): Improve
documentation of 'Buffer-menu-group-by' and
'tabulated-list-groups'.

* lisp/buff-menu.el (Buffer-menu-group-by): Doc fix.
This commit is contained in:
Eli Zaretskii 2024-02-29 20:57:12 +02:00
parent 8305d0e0c9
commit 4dd4f145b8
3 changed files with 14 additions and 12 deletions

View file

@ -1248,7 +1248,7 @@ above form when called with no arguments.
@defvar tabulated-list-groups
This buffer-local variable specifies the groups of entries displayed in
the Tabulated List buffer. Its value should be either a list, or a
the Tabulated List buffer. Its value should be either a list or a
function.
If the value is a list, each list element corresponds to one group, and
@ -1271,6 +1271,7 @@ from @code{tabulated-list-entries}. For example:
@end group
@end smallexample
@noindent
where you can define @code{Buffer-menu-group-by-mode} like this:
@smallexample

View file

@ -1358,8 +1358,8 @@ chat buffers use by default.
---
*** New user option 'Buffer-menu-group-by'.
It splits buffers by groups that are displayed with headings
in Outline minor mode.
It controls how buffers are divided into groups that are displayed with
headings using Outline minor mode.
---
*** New command 'Buffer-menu-toggle-internal'.
@ -2077,7 +2077,7 @@ treesitter grammar.
+++
** New buffer-local variable 'tabulated-list-groups'.
It prints and sorts the groups of entries separately.
It controls display and separate sorting of groups of entries.
* Changes in Emacs 30.1 on Non-Free Operating Systems

View file

@ -96,15 +96,16 @@ as it is by default."
:version "22.1")
(defcustom Buffer-menu-group-by nil
"If non-nil, buffers are grouped by function.
This function takes one argument: a list of entries in the same format
as in `tabulated-list-entries', and should return a list in the format
suitable for `tabulated-list-groups'. Also when this variable is non-nil,
then `outline-minor-mode' is enabled in the Buffer Menu. Then with the
default value of `outline-regexp' you can use Outline minor mode commands
to show/hide groups of buffers.
"If non-nil, a function to call to divide buffer-menu buffers into groups.
This function is called with one argument: a list of entries in the same
format as in `tabulated-list-entries', and should return a list in the
format suitable for `tabulated-list-groups'. Also, when this variable
is non-nil, `outline-minor-mode' is enabled in the Buffer Menu and you
can use Outline minor mode commands to show/hide groups of buffers,
according to the value of `outline-regexp'.
The default options can group by a mode, and by a root directory of
a project or just `default-directory'."
a project or just `default-directory'.
If this is nil, buffers are not divided into groups."
:type '(choice (const :tag "No grouping" nil)
(function-item :tag "Group by mode"
Buffer-menu-group-by-mode)