From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: David Ponce Newsgroups: gmane.emacs.devel Subject: Re: New easymenu behavior Date: Wed, 03 Nov 2004 15:28:17 +0000 Message-ID: <4188F911.5090502@wanadoo.fr> References: <4188C2D1.6000607@wanadoo.fr> <4188E566.5080601@wanadoo.fr> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1099491995 11770 80.91.229.6 (3 Nov 2004 14:26:35 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 3 Nov 2004 14:26:35 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Nov 03 15:26:25 2004 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1CPM5g-0007Xx-00 for ; Wed, 03 Nov 2004 15:26:25 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CPMDn-0004bp-2z for ged-emacs-devel@m.gmane.org; Wed, 03 Nov 2004 09:34:47 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1CPMDB-00047l-MA for emacs-devel@gnu.org; Wed, 03 Nov 2004 09:34:09 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1CPMDA-00046O-Ep for emacs-devel@gnu.org; Wed, 03 Nov 2004 09:34:08 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CPMDA-00045z-4z for emacs-devel@gnu.org; Wed, 03 Nov 2004 09:34:08 -0500 Original-Received: from [193.252.22.28] (helo=mwinf0306.wanadoo.fr) by monty-python.gnu.org with esmtp (Exim 4.34) id 1CPM51-0001nq-NF; Wed, 03 Nov 2004 09:25:43 -0500 Original-Received: from me-wanadoo.net (localhost [127.0.0.1]) by mwinf0306.wanadoo.fr (SMTP Server) with SMTP id 174561800197; Wed, 3 Nov 2004 15:25:43 +0100 (CET) Original-Received: from [192.168.1.2] (AGrenoble-152-1-12-147.w82-122.abo.wanadoo.fr [82.122.10.147]) by mwinf0306.wanadoo.fr (SMTP Server) with ESMTP id 9A7401800141; Wed, 3 Nov 2004 15:25:42 +0100 (CET) User-Agent: Mozilla Thunderbird 0.9 (X11/20041102) X-Accept-Language: en-us, en Original-To: David Kastrup In-Reply-To: X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:29388 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:29388 >> > What does your code do that did not already break in Emacs 21.3? >> >>recentf simply uses (easy-menu-add-item nil '("files") ...) to add >>the recentf menu into the "File" menu which is identified with the >>'files key symbol. This worked well in 21.3 because the code just >>interned "files" to get the key symbol. > > > That appears very shaky. I agree. >>Notice that XEmacs directly use menu item names to locate them. For >>example you can use '("File") to locate the "File" menu in the menu >>bar. Maybe is it a better mechanism to use in external libraries? > > > Actually, that is all that I ever used with regard to easymenu. It is > probably a bad idea to create and manage menus by a mixture of direct > accesses and easymenu. recentf only uses easymenu not a mixture of direct access and easymenu. How do you tell easy-menu-add-item to use menu item names instead of internal names? The following works with XEmacs but not with Emacs: (easy-menu-add-item nil '("File") '("Submmenu" ["item1" ignore] ["item2" ignore])) In Emacs it replaces all the "File" menu items with "Submenu", and create another empty "File" entry in the menu bar. But the following works as expected. (easy-menu-add-item nil '("Files") '("Submmenu" ["item1" ignore] ["item2" ignore]))