unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Juri Linkov <juri@linkov.net>
To: Carlos Pita <carlosjosepita2@gmail.com>
Cc: 51935@debbugs.gnu.org
Subject: bug#51935: 29.0.50; tab-switch hides identically named tabs
Date: Thu, 18 Nov 2021 19:32:10 +0200	[thread overview]
Message-ID: <86r1bdxvt8.fsf@mail.linkov.net> (raw)
In-Reply-To: <m2tugaj8oi.fsf@gmail.com> (Carlos Pita's message of "Thu, 18 Nov 2021 03:10:21 -0300")

> when one creates a new tab with C-x t 2 or C-x t n it gets the same name
> than the current tab. One can rename it but sometimes it's just a quick
> tab that isn't worth renaming, or perhaps it's just a different view to
> the original content and one is happy with it having the same name than
> the original tab, last but not least one might simply forget to rename
> it. All these scenarios aren't properly supported by tab-switch (C-x t
> RET) since it doesn't disambiguate entries before calling
> completing-read, for example by appending a numeric suffix to dups, so
> just a single representative of the homonyms set appears in the list.

How adding a numeric suffix in completions of tab-switch (C-x t RET)
could help to disambiguate the tabs?  If there will be such automatically
generated completions as "same-buffer<1>", "same-buffer<2>", "same-buffer<3>",
there is no way for users to distinguish these tabs.

Only manually renaming the tabs to names meaningful to the user
will help to disambiguate them, for example, renaming them to
"same-buffer<first-part>", "same-buffer<unfinished-reading>",
"same-buffer<will-read-later>", etc.

The package uniquify.el tries to solve this problem with some low degree
of success by trying to provide hints for disambiguating buffer names
by adding some parts of their directory names, for example:
"same-buffer<dir-name-1>", "same-buffer<dir-name-2>".  But no such thing
is possible for tab names.

> OTOH tab-switcher offers to choose between identically named tabs,
> but IMO it's not a very convenient UI (somewhat invasive and doesn't
> integrate with ordinary minibuffer completion), it's not assigned to a
> standard shortcut and it doesn't seem a good idea to me that functions

`tab-list' with new mode more like list-buffers is developed
in bug#38680 and bug#38624.

> named tab-switch and tab-switcher offer different sets of tabs to pick
> from.  Disambiguation may happen at the moment of tab creation or at the
> moment of tab selection, but I think it must happen one way or another

As you said this is a temporary situation before the user decides what
to do with the tab: either to visit another buffer that will automatically
rename the tab, or rename the tab manually, etc.  So it's a non-problem.





  reply	other threads:[~2021-11-18 17:32 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-18  6:10 bug#51935: 29.0.50; tab-switch hides identically named tabs Carlos Pita
2021-11-18 17:32 ` Juri Linkov [this message]
2021-11-19  0:31   ` Carlos Pita
2021-11-19  8:36     ` Juri Linkov
2021-11-20  3:17       ` Carlos Pita
2021-11-20 19:42         ` Juri Linkov
2021-11-22 18:16         ` Juri Linkov

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=86r1bdxvt8.fsf@mail.linkov.net \
    --to=juri@linkov.net \
    --cc=51935@debbugs.gnu.org \
    --cc=carlosjosepita2@gmail.com \
    /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 public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).