From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Daniel Engeler" Newsgroups: gmane.emacs.help Subject: Re: Can one define global-set-key to override mode-based keymap? Date: 17 Dec 2006 23:31:20 -0800 Organization: http://groups.google.com Message-ID: <1166427080.500686.237120@79g2000cws.googlegroups.com> References: NNTP-Posting-Host: dough.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" X-Trace: sea.gmane.org 1166427621 24939 80.91.229.10 (18 Dec 2006 07:40:21 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 18 Dec 2006 07:40:21 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Dec 18 08:40:20 2006 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by dough.gmane.org with esmtp (Exim 4.50) id 1GwD6i-0007VN-7A for geh-help-gnu-emacs@m.gmane.org; Mon, 18 Dec 2006 08:40:20 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GwD6h-0007Ak-Ii for geh-help-gnu-emacs@m.gmane.org; Mon, 18 Dec 2006 02:40:19 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!postnews.google.com!79g2000cws.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 15 Original-NNTP-Posting-Host: 213.173.183.18 Original-X-Trace: posting.google.com 1166427086 23380 127.0.0.1 (18 Dec 2006 07:31:26 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Mon, 18 Dec 2006 07:31:26 +0000 (UTC) In-Reply-To: User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.0.5) Gecko/20060626 Firefox/1.5.0.5 (Debian-1.5.dfsg+1.5.0.5-0bpo1),gzip(gfe),gzip(gfe) X-HTTP-Via: 1.1 zhwebcache.schmid-telecom.com:3128 (squid/2.5.STABLE11-NT) Complaints-To: groups-abuse@google.com Injection-Info: 79g2000cws.googlegroups.com; posting-host=213.173.183.18; posting-account=fbZkmA0AAADGG7YIyFUDq3R7dEvcUBm9 Original-Xref: shelby.stanford.edu gnu.emacs.help:144077 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:39680 Archived-At: martin rudalics wrote: > Not really recommended: > > (defvar my-map (make-sparse-keymap) > "My keymap.") > > (defvar my-map-alist `((t . ,my-map)) > "My keymap alist.") > > (add-to-ordered-list 'emulation-mode-map-alists 'my-map-alist 100) > > (define-key my-map [(control n)] 'other-window) I tried this and it works great so far. Why is it not recommended?