From mboxrd@z Thu Jan 1 00:00:00 1970 Path: quimby.gnus.org!not-for-mail From: storm@cua.dk (Kim F. Storm) Newsgroups: gmane.emacs.devel Subject: Re: Shall menu_bar_items and tool_bar_items look at text property keymaps? Date: 13 Feb 2002 22:26:31 +0100 Message-ID: <5xit915b08.fsf@kfs2.cua.dk> References: <5x8z9yfdvz.fsf@kfs2.cua.dk> <200202131652.g1DGqju12594@rum.cs.yale.edu> NNTP-Posting-Host: quimby2.netfonds.no Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: quimby2.netfonds.no 1013636334 28562 195.204.10.66 (13 Feb 2002 21:38:54 GMT) X-Complaints-To: usenet@quimby2.netfonds.no NNTP-Posting-Date: 13 Feb 2002 21:38:54 GMT Original-Received: from fencepost.gnu.org ([199.232.76.164]) by quimby2.netfonds.no with esmtp (Exim 3.12 #1 (Debian)) id 16b777-0007Qa-00 for ; Wed, 13 Feb 2002 22:38:53 +0100 Original-Received: from localhost ([127.0.0.1] helo=fencepost.gnu.org) by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian)) id 16b6vx-0008Dd-00; Wed, 13 Feb 2002 16:27:21 -0500 Original-Received: from mail.filanet.dk ([195.215.206.179]) by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian)) id 16b6u1-00083b-00 for ; Wed, 13 Feb 2002 16:25:21 -0500 Original-Received: from kfs2.cua.dk.cua.dk (unknown [10.1.82.3]) by mail.filanet.dk (Postfix) with SMTP id 972907C035 for ; Wed, 13 Feb 2002 21:25:19 +0000 (GMT) Original-To: emacs-devel@gnu.org In-Reply-To: <200202131652.g1DGqju12594@rum.cs.yale.edu> Original-Lines: 33 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2.50 Errors-To: emacs-devel-admin@gnu.org X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.0.5 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: Xref: quimby.gnus.org gmane.emacs.devel:1091 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:1091 "Stefan Monnier" writes: > > I was looking at the above functions and wondered whether it really > > makes sense for those functions to look for menu-bar and tool-bar > > bindings in the keymap and local-map properties of PT in the current > > buffer? > > > > I guess it makes sense in some specific cases that the menu bar or > > tool bar changes dynamically depending on what kind of text is below > > the cursor, but I was wondering whether it will actually work - as it > > requires that the menu-bar and tool-bar are updated (or at least > > checked for updates) every time the cursor moves... > > They are updated when they are activated (f.ex. when you click on > the menubar to brinf down a menu), so it should work fine. I cannot see how this can work reliable. What if the keymap contain a new main menu item which is not currently on the menu-bar ... then when you click on the menu-bar, it suddenly changes ... and it wont change back if you move the cursor (until you click on the menu-bar again). This might be a minor problem for the menu-bar, but for the tool-bar, it really doesn't make sense ... you say it is updated when you click on the tool-bar, but how can you click on something which isn't shown yet (and afterwards you may be able to click on something which isn't valid anymore.) Are you aware of any packages which actually relies on this? -- Kim F. Storm http://www.cua.dk _______________________________________________ Emacs-devel mailing list Emacs-devel@gnu.org http://mail.gnu.org/mailman/listinfo/emacs-devel