From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: Re: What happened to the key-menu patch? Date: Wed, 10 Jul 2002 04:43:22 -0600 (MDT) Sender: emacs-devel-admin@gnu.org Message-ID: <200207101043.g6AAhMZ14976@aztec.santafe.edu> References: <200205050534.g455YfF01634@aztec.santafe.edu> <5xbsbumexh.fsf@kfs2.cua.dk> <200205141941.g4EJfud15293@aztec.santafe.edu> <5xvg9qmgzt.fsf@kfs2.cua.dk> <200205151927.g4FJRRW26103@rum.cs.yale.edu> <5x3cwr4q7m.fsf@kfs2.cua.dk> <87g00rd74y.fsf@tc-1-100.kawasaki.gol.ne.jp> <87sn4otknt.fsf@tc-1-100.kawasaki.gol.ne.jp> <200205191441.g4JEfMg23080@rum.cs.yale.edu> <200205202134.g4KLYHj26031@aztec.santafe.edu> <200205222227.g4MMRIX29393@aztec.santafe.edu> <87g0030xah.fsf@tc-1-100.kawasaki.gol.ne.jp> <5xn0t3p362.fsf_-_@kfs2.cua.dk> <200207091358.g69Dwlr26999@rum.cs.yale.edu> Reply-To: rms@gnu.org NNTP-Posting-Host: localhost.gmane.org X-Trace: main.gmane.org 1026297929 350 127.0.0.1 (10 Jul 2002 10:45:29 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 10 Jul 2002 10:45:29 +0000 (UTC) Cc: miles@lsi.nec.co.jp, storm@cua.dk, monnier+gnu/emacs@rum.cs.yale.edu, emacs-devel@gnu.org Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by main.gmane.org with esmtp (Exim 3.33 #1 (Debian)) id 17SEyP-00005X-00 for ; Wed, 10 Jul 2002 12:45:29 +0200 Original-Received: from fencepost.gnu.org ([199.232.76.164]) by quimby.gnus.org with esmtp (Exim 3.12 #1 (Debian)) id 17SF7G-0007yN-00 for ; Wed, 10 Jul 2002 12:54:38 +0200 Original-Received: from localhost ([127.0.0.1] helo=fencepost.gnu.org) by fencepost.gnu.org with esmtp (Exim 3.35 #1 (Debian)) id 17SEx9-0001lN-00; Wed, 10 Jul 2002 06:44:11 -0400 Original-Received: from pele.santafe.edu ([192.12.12.119]) by fencepost.gnu.org with esmtp (Exim 3.35 #1 (Debian)) id 17SEwS-0001hS-00; Wed, 10 Jul 2002 06:43:28 -0400 Original-Received: from aztec.santafe.edu (aztec [192.12.12.49]) by pele.santafe.edu (8.11.6+Sun/8.11.6) with ESMTP id g6AAhMB10380; Wed, 10 Jul 2002 04:43:22 -0600 (MDT) Original-Received: (from rms@localhost) by aztec.santafe.edu (8.10.2+Sun/8.9.3) id g6AAhMZ14976; Wed, 10 Jul 2002 04:43:22 -0600 (MDT) X-Authentication-Warning: aztec.santafe.edu: rms set sender to rms@aztec using -f Original-To: monnier+gnu/emacs@rum.cs.yale.edu In-Reply-To: <200207091358.g69Dwlr26999@rum.cs.yale.edu> (monnier+gnu/emacs@rum.cs.yale.edu) Errors-To: emacs-devel-admin@gnu.org X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.devel:5625 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:5625 Also there is the issue of eliminating/merging duplicate bindings, which I think XEmacs' code punts on by declaring that `map-keymap' does not look at the keymap's parent(s). By duplicate bindings do you mean shadowed bindings? I think that if you ask for "scan the parents", by default you should get all the bindings, including shadowed bindings. However, there could be an optional feature to ignore shadowed bindings. That is not terribly hard to do. Just do a lookup for that event type, and see if the binding that it reports is the one you have in hand. I think that there is already code to do this, probably in where-is-internal. As for merging of subkeymaps, you don't have to worry about that. read-key-sequence implicitly merges the keymaps that it gets for a prefix key, when it gets them from different maps. But it does not merge the prefix definition from one map A with prefix definitions from its parent B. That is handled by making the prefix binding found in map A have as its parent the prefix binding found in map B. In other words, for scanning parents, you don't have to do anything special when the binding is a keymap.