[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffe
From: |
Eli Zaretskii |
Subject: |
bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted |
Date: |
Tue, 18 Jun 2024 17:46:10 +0300 |
> From: Eshel Yaron <me@eshelyaron.com>
> Cc: dmitry@gutov.dev, 71466@debbugs.gnu.org, juri@linkov.net
> Date: Tue, 18 Jun 2024 16:01:40 +0200
>
> Eli Zaretskii <eliz@gnu.org> writes:
>
> >> @item g
> >> -@findex xref-revert-buffer
> >> -Refresh the contents of the @file{*xref*} buffer
> >> -(@code{xref-revert-buffer}).
> >> +Refresh the contents of the @file{*xref*} buffer (@code{revert-buffer}).
> >> +@xref{Reverting}.
> >
> > Why remove the index entry? It needs to be rewritten, not removed.
>
> The index entry is for xref-revert-buffer, which we're making obsolete
> here in favor of revert-buffer, which has its own index entry elsewhere.
> How do you suggest rewriting it instead?
Like this:
@cindex revert-buffer, in @file{*xref*} buffers
And please move it before "@item g", so that following the index entry
with 'i' in Info lands on the line showing `g', not the line after it.
> >> -(defun xref-revert-buffer ()
> >> +(defun xref--revert-buffer (&rest _) ; Ignore `revert-buffer' args.
> >> "Refresh the search results in the current buffer."
> >
> > And I wonder why you preferred a backward-incompatible change to a
> > backward-compatible one:
>
> This is intended to be (basically) fully backward-compatible:
> xref-revert-buffer becomes an alias of revert-buffer, which does exactly
> what xref-revert-buffer would do.
Yes, but why not leave xref-revert-buffer alone, under its original
name?
> > leave the function's name alone, and just set up
> > revert-buffer-function to invoke it. Was this not possible for some
> > technical reason that evades me?
>
> It's possible, and it's more or less what I suggested upthread, but
> Dmitry correctly noted that this approach (using xref--revert-buffer)
> improves backward-compatibility in the following sense: users that
> currently invoke xref-revert-buffer not by pressing 'g', but in some
> other way, can continue to do so and get the same behavior that now
> revert-buffer provides when you press 'g'. Since revert-buffer does
> more than just calling revert-buffer-function (namely, it also runs
> revert-buffer-restore-functions), making xref-revert-buffer an alias of
> revert-buffer ensures invoking and xref-revert-buffer and pressing 'g'
> continues to behave the same.
But the original xref-revert-buffer didn't do all those other things,
did it? So invoking it directly will be more similar to what that did
before.
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Eshel Yaron, 2024/06/10
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Juri Linkov, 2024/06/11
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Juri Linkov, 2024/06/17
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Eshel Yaron, 2024/06/17
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Dmitry Gutov, 2024/06/17
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Eshel Yaron, 2024/06/17
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Dmitry Gutov, 2024/06/17
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Eshel Yaron, 2024/06/18
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Eli Zaretskii, 2024/06/18
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Eshel Yaron, 2024/06/18
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted,
Eli Zaretskii <=
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Eshel Yaron, 2024/06/18
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Dmitry Gutov, 2024/06/18
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Eli Zaretskii, 2024/06/18
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Dmitry Gutov, 2024/06/18
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Juri Linkov, 2024/06/20
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Dmitry Gutov, 2024/06/20
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Juri Linkov, 2024/06/24
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Dmitry Gutov, 2024/06/24
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Juri Linkov, 2024/06/25
- bug#71466: 30.0.50; Buffer-menu-group-by non-nil resets point when Buffer List is reverted, Eli Zaretskii, 2024/06/25