From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Sean O'Rourke" Newsgroups: gmane.emacs.devel Subject: Re: how about a find-library-other-window command? Date: Tue, 19 Jun 2007 12:39:01 -0700 Message-ID: References: <18040.10649.628867.535567@gargle.gargle.HOWL> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1182282003 1018 80.91.229.12 (19 Jun 2007 19:40:03 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 19 Jun 2007 19:40:03 +0000 (UTC) Cc: Drew Adams , Emacs-Devel To: David House Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jun 19 21:40:01 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1I0jYS-0000gb-6n for ged-emacs-devel@m.gmane.org; Tue, 19 Jun 2007 21:40:01 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1I0jYP-0001SF-Bi for ged-emacs-devel@m.gmane.org; Tue, 19 Jun 2007 15:39:53 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1I0jY2-0001KO-Gk for emacs-devel@gnu.org; Tue, 19 Jun 2007 15:39:30 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1I0jXz-0001Iq-JN for emacs-devel@gnu.org; Tue, 19 Jun 2007 15:39:30 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1I0jXz-0001Ih-4a for emacs-devel@gnu.org; Tue, 19 Jun 2007 15:39:27 -0400 Original-Received: from outbound1.ucsd.edu ([132.239.1.205]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1I0jXx-0005Fw-4d for emacs-devel@gnu.org; Tue, 19 Jun 2007 15:39:26 -0400 Original-Received: from smtp.ucsd.edu (smtp.ucsd.edu [132.239.1.49]) by outbound1.ucsd.edu (8.13.6/8.13.6) with ESMTP id l5JJd3Lo051508 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 19 Jun 2007 12:39:03 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; s=2007001; d=ucsd.edu; c=simple; q=dns; b=n7m7+8lxgBKMAXAYZeKajCPqCbp6IVYp32q4hW9tBQq6962P1ko0xQYy3W3BPyuip MNxkCNBNNg6r4YUjq+Auw== Original-Received: from 0-16-cb-b9-d7-be.dynamic.ucsd.edu (0-16-cb-b9-d7-be.dynamic.ucsd.edu [128.54.54.202]) by smtp.ucsd.edu (8.13.6/8.13.4) with ESMTP id l5JJd1a4055154; Tue, 19 Jun 2007 12:39:02 -0700 (PDT) In-Reply-To: <18040.10649.628867.535567@gargle.gargle.HOWL> (David House's message of "Tue\, 19 Jun 2007 20\:08\:09 +0100") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1.50 (darwin) X-detected-kernel: FreeBSD 6.x (1) 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: news.gmane.org gmane.emacs.devel:73332 Archived-At: David House writes: > Drew Adams writes: > > How about a `find-library-other-window' command? > > I've wondered in the past whether it would be feasible to have > C-x 4 be bound to a command which reads a key sequence then > executes it in another window, so that we needn't define new > commands for every command we want to execute in the other > window. This, or something similar, seems useful. I currently use a slightly different hack that makes "C-z FOO" do whatever "C-x FOO" does, but in another window. I do it by copying `ctl-x-map' and wrapping the entries with this: (defun other-windowize (fn) `(lambda () (interactive) (switch-to-buffer-other-window (save-window-excursion (call-interactively ',fn) (current-buffer))))) No doubt there's a better way, but this seems to work well enough to replace many existing FOO-other-window commands, and to other-windowize some new things. /s