all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: joaotavora@gmail.com (João Távora)
To: Eli Zaretskii <eliz@gnu.org>
Cc: 28814@debbugs.gnu.org, Dmitry Gutov <dgutov@yandex.ru>
Subject: bug#28814: [BUMP, PATCH] (26.0.90; When *xref* window is needed, original window-switching intent is lost )
Date: Wed, 25 Oct 2017 16:27:13 +0100	[thread overview]
Message-ID: <87k1zjs0xa.fsf@gmail.com> (raw)
In-Reply-To: <83inf38dq2.fsf@gnu.org> (Eli Zaretskii's message of "Wed, 25 Oct 2017 18:11:01 +0300")

Eli Zaretskii <eliz@gnu.org> writes:

> I understand that the motivation for changing the existing solution
> for the "disappearing XREF buffer" was the unexpected or even
> incorrect behavior when the "C-x 4" variety of the commands is
> invoked.  That is, the existing code would display the definition in
> the original window, not in "the other" window (which is taken by the
> XREF buffer).  And the original solution was to display the definition
> in the window where the XREF buffer was displayed, thus making it
> "disappear".  Is that correct?

More or less. You are 90% correct. I wouldn’t link unexpected behaviour
with the "disappear XREF buffer" because they can be seen as independent
issues, though closely related. Anyway, it’s OK because the fix you
propose further below is exactly the current one I propose (minus some
subtleties for when we "can’t" pop a new window because of insuficient
window dimensions).

> If so, then the easiest solution IMO would be to pop up one more
> window, i.e. behave as if the window displaying the XREF buffer didn't
> exist.  That would both keep the contract of "C-x 4" and leave the
> XREF buffer visible.

Yes, this is the default behaviour in the current patches.

> As for quitting the XREF buffer when it's no longer needed: how about
> 'q', like other similar modes do, or some variety thereof?  "C-u RET"
> is too odd, almost outlandish in Emacs.

’q’ is already taken by ’quit-window’ in *xref* buffers. It quits the
window and does nothing else. I’m looking for a command that quits *and*
goes to the target. If done in this order, it has the nice benefit that
the window thus immediately released is available for showing the cross
reference (in the C-x 4 case, that is)

If no suitable key for this command can be found (’a’, ’o’ would perhaps
be nice), then let’s make an unbound command that I can bound to RET.

Then let’s open a separate discussion on whether that behaviour should
become the default (I think it should).

> If the above solves the remaining issues, and if you have no other
> problems, can we have patches to that effect?

Sure, as soon as you (or we) decide on one of the following:

* C-u RET (for completeness sake, you seem to be against this one)
* ’a’ bound to a new command xref-quit-and-goto-xref
* ’o’ bound to a new command xref-quit-and-goto-xref
* a new unbound command xref-quit-and-goto-xref

> And then the next question would be: what branch to install this on?

It’s a bugfix, so emacs-26.





  reply	other threads:[~2017-10-25 15:27 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-13 16:07 bug#28814: 26.0.90; When *xref* window is needed, original window-switching intent is lost João Távora
     [not found] ` <handler.28814.B.150791088020837.ack@debbugs.gnu.org>
2017-10-16 17:58   ` bug#28814: Acknowledgement (26.0.90; When *xref* window is needed, original window-switching intent is lost ) João Távora
2017-10-20  9:13   ` bug#28814: [BUMP, PATCH] " João Távora
2017-10-20 10:39     ` Dmitry Gutov
2017-10-23  2:06     ` Dmitry Gutov
2017-10-23  8:23       ` João Távora
2017-10-23 20:03         ` João Távora
2017-10-25  0:24           ` Dmitry Gutov
2017-10-25  7:43             ` João Távora
2017-10-25 10:24               ` Dmitry Gutov
2017-10-25 13:29                 ` João Távora
2017-10-25 14:49                   ` Dmitry Gutov
2017-10-25 15:35                     ` João Távora
2017-10-25 15:46                       ` Dmitry Gutov
2017-10-25 15:11             ` Eli Zaretskii
2017-10-25 15:27               ` João Távora [this message]
2017-10-25 15:39                 ` Eli Zaretskii
2017-10-25 20:56                   ` João Távora
2017-10-26  7:56                     ` martin rudalics
2017-10-26 16:42                     ` Eli Zaretskii
2017-10-26 22:40                       ` Dmitry Gutov
2017-10-27  0:05                         ` João Távora
2017-11-02 17:06                           ` Dmitry Gutov
2017-10-26 23:59                       ` João Távora
2017-10-28  9:41                         ` Eli Zaretskii
2017-10-28 19:19                           ` João Távora
2017-11-02 17:03                             ` João Távora
2017-11-02 17:07                               ` Eli Zaretskii
2017-11-02 19:07                                 ` João Távora
2017-11-02 19:32                                   ` Eli Zaretskii
2017-11-03 13:47                             ` Eli Zaretskii
2017-11-03 16:18                               ` João Távora
2017-11-03 19:06                                 ` Eli Zaretskii
2017-10-26 12:39                   ` Dmitry Gutov
2017-10-25  7:46           ` martin rudalics
2017-10-25 13:19             ` João Távora
2017-10-26  7:56               ` martin rudalics
2017-10-25  0:07         ` Dmitry Gutov

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=87k1zjs0xa.fsf@gmail.com \
    --to=joaotavora@gmail.com \
    --cc=28814@debbugs.gnu.org \
    --cc=dgutov@yandex.ru \
    --cc=eliz@gnu.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.