From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.bugs Subject: bug#8551: making Emacs remember a key binding to 'other-window Date: Mon, 25 Apr 2011 11:50:45 -0700 Message-ID: References: <3679AE44D8C04547A4F3EB83E7790562A8B3FE561E@MBX01.ldschurch.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1303758463 7471 80.91.229.12 (25 Apr 2011 19:07:43 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 25 Apr 2011 19:07:43 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: "'Kevin Michael Simonson'" , <8551@debbugs.gnu.org> Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Apr 25 21:07:39 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 1QER8E-00066X-Io for geb-bug-gnu-emacs@m.gmane.org; Mon, 25 Apr 2011 21:07:38 +0200 Original-Received: from localhost ([::1]:33739 helo=lists2.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QER8E-0005Kl-1I for geb-bug-gnu-emacs@m.gmane.org; Mon, 25 Apr 2011 15:07:38 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:58570) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QER8A-0005IG-Vr for bug-gnu-emacs@gnu.org; Mon, 25 Apr 2011 15:07:35 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QER8A-0008Sl-6s for bug-gnu-emacs@gnu.org; Mon, 25 Apr 2011 15:07:34 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:48316) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QER8A-0008Sg-5J for bug-gnu-emacs@gnu.org; Mon, 25 Apr 2011 15:07:34 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1QEQsA-0006g7-8q; Mon, 25 Apr 2011 14:51:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: "Drew Adams" Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 25 Apr 2011 18:51:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 8551 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 8551-submit@debbugs.gnu.org id=B8551.130375745625658 (code B ref 8551); Mon, 25 Apr 2011 18:51:02 +0000 Original-Received: (at 8551) by debbugs.gnu.org; 25 Apr 2011 18:50:56 +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 1QEQs3-0006fm-2Z for submit@debbugs.gnu.org; Mon, 25 Apr 2011 14:50:56 -0400 Original-Received: from rcsinet10.oracle.com ([148.87.113.121]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QEQs1-0006fa-0x for 8551@debbugs.gnu.org; Mon, 25 Apr 2011 14:50:53 -0400 Original-Received: from rcsinet15.oracle.com (rcsinet15.oracle.com [148.87.113.117]) by rcsinet10.oracle.com (Switch-3.4.2/Switch-3.4.2) with ESMTP id p3PIojnI019252 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 25 Apr 2011 18:50:46 GMT Original-Received: from acsmt357.oracle.com (acsmt357.oracle.com [141.146.40.157]) by rcsinet15.oracle.com (Switch-3.4.2/Switch-3.4.1) with ESMTP id p3PIoiBR017710 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 25 Apr 2011 18:50:44 GMT Original-Received: from abhmt014.oracle.com (abhmt014.oracle.com [141.146.116.23]) by acsmt357.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id p3PIoheM027740; Mon, 25 Apr 2011 13:50:44 -0500 Original-Received: from dradamslap1 (/130.35.178.194) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Mon, 25 Apr 2011 11:50:43 -0700 X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <3679AE44D8C04547A4F3EB83E7790562A8B3FE561E@MBX01.ldschurch.org> Thread-Index: AcwDbjtE6U28zWlNTQSGZPpku7e+AQACfWaQ X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6090 X-Source-IP: rcsinet15.oracle.com [148.87.113.117] X-Auth-Type: Internal IP X-CT-RefId: str=0001.0A090209.4DB5C286.0145:SCFMA4539811,ss=1,fgs=0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Mon, 25 Apr 2011 14:51:02 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) 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:46003 Archived-At: > I am often running Emacs with multiple windows. In my opinion > the "C-x o" key-combination is too cumbersome, and I never use > the "open-line" function "C-o" is bound to, so I'm always using > "global-set-key" to bind "C-o" to "other-window". How can I put > that key binding in my ".emacs" file so that this key binding is > remembered and I don't have to keep executing "global-set-key" > manually? Kevin Simonson A couple of administrative things, FYI: * The best mailing list for questions like this is `help-gnu-emacs@gnu.org' (cc'd). * Please use plain-text, not HTML formatting, when sending mail to either the bug list or the help list. --- Wrt your question, here's what I would suggest: In Emacs 22+, where (fboundp 'command-remapping) is non-nil: (global-set-key [remap open-line] 'other-window) In Emacs before 22 (no command remapping): (substitute-key-definition 'open-line 'other-window global-map)