From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Matthias Meulien Newsgroups: gmane.emacs.devel,gmane.emacs.bugs Subject: Key bindings for info in other window or frame Date: Wed, 24 Jul 2013 23:28:00 +0200 Message-ID: <87k3kfmyvz.fsf@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: ger.gmane.org 1374701040 2126 80.91.229.3 (24 Jul 2013 21:24:00 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 24 Jul 2013 21:24:00 +0000 (UTC) Cc: emacs-devel@gnu.org To: bug-gnu-emacs@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Jul 24 23:24:01 2013 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1V26XO-0003YR-W5 for ged-emacs-devel@m.gmane.org; Wed, 24 Jul 2013 23:23:59 +0200 Original-Received: from localhost ([::1]:36912 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V26XO-0008WK-IF for ged-emacs-devel@m.gmane.org; Wed, 24 Jul 2013 17:23:58 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33361) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V26XJ-0008W6-Ni for emacs-devel@gnu.org; Wed, 24 Jul 2013 17:23:56 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V26XH-0006nT-7k for emacs-devel@gnu.org; Wed, 24 Jul 2013 17:23:53 -0400 Original-Received: from mail-wg0-x22f.google.com ([2a00:1450:400c:c00::22f]:44566) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V26XH-0006nG-1E; Wed, 24 Jul 2013 17:23:51 -0400 Original-Received: by mail-wg0-f47.google.com with SMTP id j13so900184wgh.2 for ; Wed, 24 Jul 2013 14:23:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:user-agent:mime-version :content-type; bh=1cjm9skxMjQoPppSIFPnQz774lFCBrvx9m5CBIt6pJ0=; b=b4I29WRrRgcCHhYJnl5BtXZNkoK5OwjTzV+SZR50xgNOGHRgCEweHGQxLNi2iIk5Ud WXci8Sp+W2Ft7fasFJwuiW/N2q8QSbRquAfZPcd+sB01FZBNjseDxrfLrItc9rPQFY+q V1S+oG5z7yXqCs+jfLixnosnD9mWs4tUiZ4M9sdOPzPljzAwZyDWGi69EI3vGPcDzcAj qk/ND7fWQIp/UIuD9Bytkf2klgqgQTd1norF2DRXIG5oFv05H4hvJWG/hs4xlQvsuog9 nl0DACE2iiwV+yrJWW3CVzSFIp5xeMm2LA9AbI93xYt7BquFQA2NFfE7gkYRnp0VCRy9 28Ew== X-Received: by 10.194.119.195 with SMTP id kw3mr28082109wjb.64.1374701029499; Wed, 24 Jul 2013 14:23:49 -0700 (PDT) Original-Received: from choubidou.localdomain (jau31-3-82-239-20-84.fbx.proxad.net. [82.239.20.84]) by mx.google.com with ESMTPSA id fb2sm8105558wic.4.2013.07.24.14.23.47 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Wed, 24 Jul 2013 14:23:48 -0700 (PDT) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:400c:c00::22f X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:162116 gmane.emacs.bugs:76633 Archived-At: --=-=-= Content-Type: text/plain; format=flowed Severity: wishlist Tags: patch Everything is in the subject! The attached patch defines `info-other-frame' and bind it to `C-x 5 i'. It also bind `info-other-window' to `C-x 4 i'. I know that `info-other-window' is already bind to `C-h 4 i' but I found it more difficult to remember than the key binding which use the ubiquitous `C-x 4' keymap. --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=info_other_frame_and_window.patch Content-Description: Key bindings for info in other window or frame >From cf8d4210743c1c9b06db28e5b5bb5a51f8a190bf Mon Sep 17 00:00:00 2001 From: Matthias Meulien Date: Wed, 24 Jul 2013 23:23:44 +0200 Subject: [PATCH] lisp/info.el (info-other-window): Add key binding and other frame defun --- lisp/info.el | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/lisp/info.el b/lisp/info.el index 0e0a117..99098e8 100644 --- a/lisp/info.el +++ b/lisp/info.el @@ -745,6 +745,7 @@ in `Info-file-supports-index-cookies-list'." (not (member dir (split-string path ":" t))) (push dir Info-directory-list))))))) +;;;###autoload (define-key ctl-x-4-map "i" 'info-other-window) ;;;###autoload (defun info-other-window (&optional file-or-node buffer) "Like `info' but show the Info buffer in another window." @@ -756,6 +757,18 @@ in `Info-file-supports-index-cookies-list'." (info-setup file-or-node (switch-to-buffer-other-window (or buffer "*info*")))) +;;;###autoload (define-key ctl-x-5-map "i" 'info-other-frame) +;;;###autoload +(defun info-other-frame (&optional file-or-node buffer) + "Like `info' but put the Info buffer in another frame." + (interactive (list + (if (and current-prefix-arg (not (numberp current-prefix-arg))) + (read-file-name "Info file name: " nil nil t)) + (if (numberp current-prefix-arg) + (format "*info*<%s>" current-prefix-arg)))) + (info-setup file-or-node + (switch-to-buffer-other-frame (or buffer "*info*")))) + ;;;###autoload (put 'info 'info-file (purecopy "emacs")) ;;;###autoload (defun info (&optional file-or-node buffer) -- 1.8.3.3 --=-=-= Content-Type: text/plain; format=flowed Thanks for reading, -- Matthias --=-=-=--