From: Eli Zaretskii Date: Tue, 10 Oct 2023 11:46:08 +0000 (+0300) Subject: Improve documentation of 'project-mode-line' X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=d51f3165f7eb471acd3d178ef1b94b19254e8857;p=emacs.git Improve documentation of 'project-mode-line' * etc/NEWS: * doc/emacs/maintaining.texi (Projects): * lisp/progmodes/project.el (project-mode-line): Improve the documentation of 'project-mode-line'. (Bug#66317) --- diff --git a/doc/emacs/maintaining.texi b/doc/emacs/maintaining.texi index 5f9a5d89bf3..d37cefebb01 100644 --- a/doc/emacs/maintaining.texi +++ b/doc/emacs/maintaining.texi @@ -1743,6 +1743,14 @@ project. Also, the VC-aware Project back-end considers ``untracked'' files by default. That behavior is controllable with the variable @code{project-vc-include-untracked}. +@cindex current project name on mode line +@defopt project-mode-line +If this user option is non-@code{nil}, Emacs displays the name of the +current project (if any) on the mode line; clicking @kbd{mouse-1} on +the project name pops up the menu with the project-related commands. +The default value is @code{nil}. +@end defopt + @menu * Project File Commands:: Commands for handling project files. * Project Buffer Commands:: Commands for handling project buffers. diff --git a/etc/NEWS b/etc/NEWS index 934521ec1b0..70110768c97 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -890,8 +890,9 @@ showcases all their customization options. ** Project *** New user option 'project-mode-line'. -When non-nil, display the name of the current project on -the mode line. Clicking mouse-1 pops up the project menu. +When non-nil, display the name of the current project on the mode +line. Clicking 'mouse-1' on the project name pops up the project +menu. The default value is nil. *** New user option 'project-file-history-behavior'. Customizing it to 'relativize' makes commands like 'project-find-file' diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el index 9997833ceb1..3c469d0e51f 100644 --- a/lisp/progmodes/project.el +++ b/lisp/progmodes/project.el @@ -2014,9 +2014,10 @@ would otherwise have the same name." ;;;###autoload (defcustom project-mode-line nil - "Show the current project name with the menu on the mode line. + "Whether to show current project name and Project menu on the mode line. This feature requires the presence of the following item in -`mode-line-format': `(project-mode-line project-mode-line-format)'." +`mode-line-format': `(project-mode-line project-mode-line-format)'; it +is part of the default mode line beginning with Emacs 30." :type 'boolean :group 'project :version "30.1")