From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#2975: `texinfo-master-menu' doesn't work. Date: Sat, 10 Dec 2011 14:40:39 +0200 Message-ID: <837h24mwfs.fsf__34106.9910712124$1323520931$gmane$org@gnu.org> References: <20090412213340.GA3615@muc.de> Reply-To: Eli Zaretskii NNTP-Posting-Host: lo.gmane.org X-Trace: dough.gmane.org 1323520931 2173 80.91.229.12 (10 Dec 2011 12:42:11 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 10 Dec 2011 12:42:11 +0000 (UTC) Cc: bug-texinfo@gnu.org, 2975-done@debbugs.gnu.org To: Alan Mackenzie Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Dec 10 13:42:07 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RZMFj-0007po-5O for geb-bug-gnu-emacs@m.gmane.org; Sat, 10 Dec 2011 13:42:07 +0100 Original-Received: from localhost ([::1]:60123 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RZMFi-0004xR-PR for geb-bug-gnu-emacs@m.gmane.org; Sat, 10 Dec 2011 07:42:06 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:43283) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RZMFf-0004wm-7X for bug-gnu-emacs@gnu.org; Sat, 10 Dec 2011 07:42:04 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RZMFe-0003b4-2P for bug-gnu-emacs@gnu.org; Sat, 10 Dec 2011 07:42:03 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:60337) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RZMFe-0003b0-0s for bug-gnu-emacs@gnu.org; Sat, 10 Dec 2011 07:42:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1RZMGc-0005Zi-BA for bug-gnu-emacs@gnu.org; Sat, 10 Dec 2011 07:43:02 -0500 Resent-From: Eli Zaretskii Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: bug-gnu-emacs@gnu.org Resent-Date: Sat, 10 Dec 2011 12:43:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: cc-closed 2975 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Mail-Followup-To: 2975@debbugs.gnu.org, eliz@gnu.org Original-Received: via spool by 2975-done@debbugs.gnu.org id=D2975.132352094021322 (code D ref 2975); Sat, 10 Dec 2011 12:43:02 +0000 Original-Received: (at 2975-done) by debbugs.gnu.org; 10 Dec 2011 12:42:20 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RZMFv-0005Xo-47 for submit@debbugs.gnu.org; Sat, 10 Dec 2011 07:42:20 -0500 Original-Received: from mtaout22.012.net.il ([80.179.55.172]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RZMFs-0005Xa-Uf for 2975-done@debbugs.gnu.org; Sat, 10 Dec 2011 07:42:18 -0500 Original-Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0LVZ00H00N37GD00@a-mtaout22.012.net.il> for 2975-done@debbugs.gnu.org; Sat, 10 Dec 2011 14:40:41 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([84.228.102.96]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0LVZ00AB3N7QEDC2@a-mtaout22.012.net.il>; Sat, 10 Dec 2011 14:40:41 +0200 (IST) In-reply-to: <20090412213340.GA3615@muc.de> X-012-Sender: halo1@inter.net.il X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Sat, 10 Dec 2011 07:43:02 -0500 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:54864 Archived-At: > Date: Sun, 12 Apr 2009 21:33:40 +0000 > From: Alan Mackenzie > > In Emacs, either 22.3 or a recent CVS version ... > emacs -Q > > 1. > > (i) C-c C-f .../path/to/emacs/doc/misc/cc-mode.texi > (ii) M-g M-g 238 ; the second line of the menu, > ; contents "* Overview::" > (ii) C-k C-k ; Kill this line > > (v) Now do C-c C-u m. This flashes the screen and reports > "Done...completed making master menu. You may save the buffer.". > However, it hasn't made the master menu - the "* Overview::" line is > still missing. "C-c C-u m" (texinfo-master-menu) is not supposed to update the menus in the buffer, including the menu in the Top node, unless you invoke it with a prefix argument. If you don't invoke it with a prefix arg, you need to update the menus yourself, either manually or by running texinfo-make-menu or texinfo-all-menus-update. This is because this command only looks at the _existing_ menus; it does NOT look at the @node lines to recreate or update any missing/outdated entries in those menus. I made this clear in the doc string of texinfo-master-menu. > 2. > > (i) Kill (remove) the entire master menu from the buffer (between the > lines "@menu" and "@end menu"). > > (ii) Try to regenerate the master menu with C-c C-u m. This signals the > puzzling error "Buffer lacks ordinary `Top' menu in which to insert > master". It is not clear what a "`Top' menu" is, in what respect it is > "ordinary", and in what regard the new master menu is inserted into it. > The existing master menu was not contained within any menu. The error is signaled because texinfo-master-menu does not update or create any menus, see above. By deleting the menu in the Top node, you removed the part of the buffer on which texinfo-master-menu depends for doing its job. So it barfed. I changed the error message text so it is hopefully more clear. It now says: Buffer lacks a menu in its first node; create it, then run me again > 3. > > (i) C-c C-f .../path/to/emacs/doc/lispref/elisp.texi > (ii) M-g M-g 108 ; the second line of the menu, > ; "* Lisp Data Types:: ...." > (iii) C-k C-k ; Kill this line > > (iv) Now do C-c C-u m. This doesn't regenerate the master menu. > Instead, it deletes the @detailmenu without restoring the "* Lisp Data > Types::" line. texinfo-master-menu does not support multi-file manuals (which is what elisp.texi is). For that, one should use texinfo-multiple-files-update. I made that clear in the doc string. > Neither the doc string for `texinfo-master-menu' nor the texinfo manual > (page "Updating Nodes and Menus") describe other than vaguely what this > command is supposed to do. I made that more clear in the commentary at the beginning of texnfo-upd.el and in the doc string of texinfo-master-menu. > The doc string states, accurately, that > > The function removes the detailed part of an already existing master > menu. > > , which though accurate, is puzzling in the extreme; what one wants from > this command is for the detailed bit to be inserted, not deleted. > > There is no verb in "texinfo master menu", so one is led by intelligent > guessing to believe that the command does whatever necessary to insert > or update the master menu. This doesn't happen. The crucial part of the doc string was this: The master menu includes every entry from all the other menus. IOW, it only collects entries from existing menus, it does NOT update the menus. Admittedly, this crucial piece of information was buried deep in the doc string. Hopefully, now it is more clear. All of the above changes are in revision 106651 on the trunk. I'm closing this bug report. Sorry for the long delay in handling it.