all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Stefan Kangas <stefan@marxist.se>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: 12436@debbugs.gnu.org
Subject: bug#12436: 24.2.50; rename `(next|previous)-multiframe-window'
Date: Wed, 30 Oct 2019 23:30:53 +0100	[thread overview]
Message-ID: <878sp1x3vm.fsf@joffe.skangas.se> (raw)
In-Reply-To: <87fuu57img.fsf@gnus.org> (Lars Ingebrigtsen's message of "Thu, 28 Apr 2016 19:23:03 +0200")

[-- Attachment #1: Type: text/plain, Size: 671 bytes --]

Lars Ingebrigtsen <larsi@gnus.org> writes:

> "Drew Adams" <drew.adams@oracle.com> writes:
>
>> Rename these commands and deprecate the old names.  There is no such
>> thing as a multiframe window, which would mean a window on more than one
>> frame.  These commands should be called something like:
>> `(next|previous)-window-any-frame'.
>
> I agree.  Any objections?  There does not seem to be many users of these
> functions:
>
> ./frame.el:522:(defun next-multiframe-window ()
> ./frame.el:530:(defun previous-multiframe-window ()
> ./term/ns-win.el:105:(define-key global-map [?\s-'] 'next-multiframe-window)

Makes sense to me.  Any objections to the below patch?


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-Rename-multiframe-window-to-window-any-frame.patch --]
[-- Type: text/x-diff, Size: 3720 bytes --]

From 1ee698b0b0722c18ee211d79821370af2f60af56 Mon Sep 17 00:00:00 2001
From: Stefan Kangas <stefankangas@gmail.com>
Date: Wed, 30 Oct 2019 23:27:37 +0100
Subject: [PATCH] Rename `*-multiframe-window' to '*-window-any-frame'

Suggested by Drew Adams.

* lisp/frame.el
(next-multiframe-window): Define as obsolete alias for...
(next-window-any-frame): ...new function name.
(previous-multiframe-window): Define as obsolete alias for...
(previous-window-any-frame): ...new function name.  (Bug#12436)

* lisp/term/ns-win.el (global-map): Use new command name.
* doc/emacs/windows.texi (Other Window): Document it.
* etc/NEWS: Announce it.
---
 doc/emacs/windows.texi | 4 ++--
 etc/NEWS               | 5 +++++
 lisp/frame.el          | 8 ++++++--
 lisp/term/ns-win.el    | 2 +-
 4 files changed, 14 insertions(+), 5 deletions(-)

diff --git a/doc/emacs/windows.texi b/doc/emacs/windows.texi
index 19f6cff7bf..53e9a4bb58 100644
--- a/doc/emacs/windows.texi
+++ b/doc/emacs/windows.texi
@@ -181,12 +181,12 @@ Other Window
 back and finish supplying the minibuffer argument that is requested.
 @xref{Minibuffer Edit}.
 
-@findex next-multiframe-window
+@findex next-window-any-frame
 The @code{other-window} command will normally only switch to the next
 window in the current frame (unless otherwise configured).  If you
 work in a multi-frame environment and you want windows in all frames
 to be part of the cycle, you can rebind @kbd{C-x o} to the
-@code{next-multiframe-window} command.  (@xref{Rebinding}, for how to
+@code{next-window-any-frame} command.  (@xref{Rebinding}, for how to
 rebind a command.)
 
 @kindex C-M-v
diff --git a/etc/NEWS b/etc/NEWS
index cd1e46bb87..bb288a4aac 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -202,6 +202,11 @@ the new version of the file again.)
 \f
 * Changes in Emacs 27.1
 
++++
+** 'next-multiframe-window' and 'previous-multiframe-window' are obsolete.
+Use new names 'next-window-any-frame' and 'previous-window-any-frame'
+instead.
+
 ** emacsclient
 
 +++
diff --git a/lisp/frame.el b/lisp/frame.el
index 92fe57fbe6..7aa1b75f1f 100644
--- a/lisp/frame.el
+++ b/lisp/frame.el
@@ -673,21 +673,25 @@ get-other-frame
 is not considered (see `next-frame')."
   (if (equal (next-frame) (selected-frame)) (make-frame) (next-frame)))
 
-(defun next-multiframe-window ()
+(defun next-window-any-frame ()
   "Select the next window, regardless of which frame it is on."
   (interactive)
   (select-window (next-window (selected-window)
 			      (> (minibuffer-depth) 0)
 			      0))
   (select-frame-set-input-focus (selected-frame)))
+(define-obsolete-function-alias 'next-multiframe-window
+  'next-window-any-frame "27.1")
 
-(defun previous-multiframe-window ()
+(defun previous-window-any-frame ()
   "Select the previous window, regardless of which frame it is on."
   (interactive)
   (select-window (previous-window (selected-window)
 				  (> (minibuffer-depth) 0)
 				  0))
   (select-frame-set-input-focus (selected-frame)))
+(define-obsolete-function-alias 'previous-multiframe-window
+  'previous-window-any-frame "27.1")
 
 (defun window-system-for-display (display)
   "Return the window system for DISPLAY.
diff --git a/lisp/term/ns-win.el b/lisp/term/ns-win.el
index 83b845b1a5..1841e679ac 100644
--- a/lisp/term/ns-win.el
+++ b/lisp/term/ns-win.el
@@ -102,7 +102,7 @@ 'ns-alternatives-map
 
 ;; Here are some Nextstep-like bindings for command key sequences.
 (define-key global-map [?\s-,] 'customize)
-(define-key global-map [?\s-'] 'next-multiframe-window)
+(define-key global-map [?\s-'] 'next-window-any-frame)
 (define-key global-map [?\s-`] 'other-frame)
 (define-key global-map [?\s-~] 'ns-prev-frame)
 (define-key global-map [?\s--] 'center-line)
-- 
2.20.1


[-- Attachment #3: Type: text/plain, Size: 29 bytes --]


Best regards,
Stefan Kangas

  reply	other threads:[~2019-10-30 22:30 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-13 16:30 bug#12436: 24.2.50; rename `(next|previous)-multiframe-window' Drew Adams
2016-04-28 17:23 ` Lars Ingebrigtsen
2019-10-30 22:30   ` Stefan Kangas [this message]
2019-10-30 22:46     ` Lars Ingebrigtsen
2019-10-30 23:20     ` Drew Adams
2019-10-31 14:05     ` Eli Zaretskii
2019-11-02  1:37       ` Stefan Kangas
2019-11-05 23:51         ` Stefan Kangas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=878sp1x3vm.fsf@joffe.skangas.se \
    --to=stefan@marxist.se \
    --cc=12436@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.