GNU bug report logs - #79159
[PATCH] Do not display in the tab line tabs that are excluded.

Previous Next

Package: emacs;

Reported by: Elijah Gabe Pérez <eg642616 <at> gmail.com>

Date: Sat, 2 Aug 2025 20:02:02 UTC

Severity: normal

Tags: patch

Fixed in version 31.0.50

Done: Juri Linkov <juri <at> linkov.net>

Full log


View this message in rfc822 format

From: Juri Linkov <juri <at> linkov.net>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 79159 <at> debbugs.gnu.org, eg642616 <at> gmail.com
Subject: bug#79159: [PATCH] Do not display in the tab line tabs that are excluded.
Date: Wed, 06 Aug 2025 09:28:06 +0300
>> >> 1. M-x global-tab-line-mode RET
>> >> 2. C-x b foo RET
>> >> 3. C-x b SPC *bar* RET
>> >> 4. C-x <left>
>> >>    Now the buffer name " *bar*" is visible on the tab-line.
>> >> 5. C-x <left>
>> >>    But now " *bar*" suddenly goes away.
>> >> 
>> >> This is because handling of excluded buffers is hard-coded
>> >> in many window.el functions.
>> >> 
>> >> So not showing excluded buffers by default will avoid this snag.
>> >
>> > If there are bugs with handling excluded buffers, I hope we can fix
>> > them, instead of leaving them hidden behind a user option.  People who
>> > will use that option will see those bugs exactly as all of the users
>> > see them today, and they _will_ complain.
>> >
>> > OTOH, since no one has yet complained about those bugs, perhaps
>> > leaving this behavior be the default is not such a bad idea?
>> 
>> Not bugs, just unexpected inconsistencies.  window.el doesn't
>> permit excluded buffers to exist in the window-prev-buffers list
>> that is used for tab-line.  No one complained about this problem
>> because it's very difficult to notice it: one moment there is
>> an excluded buffer on the tab-line, and the next moment it disappears.
>> 
>> Not showing such buffers by default will fix this inconsistency.
>
> No, it will just sweep the problem under the carpet.  Since when are
> we handling bugs in this manner?  If a feature needs work to be
> finished, let's please invest the effort to do that work.  Let's
> please not have semi-broken features.

Currently there is a bug in tab-line.el, and the proposed patch fixes it.

Without activating global-tab-line-mode try the following:

0. emacs -Q
1. C-x b SPC *bar* RET
2. C-x b foo RET
3. C-x <left>

It switches to the initial buffer *scratch*,
skipping the excluded buffer " *bar*".

Without the proposed patch the tab-line is broken,
because it displays the excluded buffer,
but 'C-x <left>' can't switch to it.

So tab-line.el should follow the logic of window.el
and omit excluded buffers as well.




This bug report was last modified 5 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.