Subject: Re: bug#78953: 31.0.50; tab-bar-format-align-right alignment breaks if field widths change

From: Juri Linkov <[email-masked]>
Date: Thu, 10 Jul 2025 21:24:50 +0300

> This looks interesting. But I just naively tried the following and Emacs
> hangs up as result.
>
> (setq tab-bar-auto-width t
>       tab-bar-auto-width-functions (list #'always))

This is a new bug report.

> But the auto width setting leads to growing fields and this is not what
> I want. I don't want that the tab fields grow. I want them to shrink
> only in case of overflow. So maybe `tab-bar-auto-width` could be
> extended to handle the values nil, t, or `no-grow'? And also another
> auto width function could be added which handles non-tab fields too.

This is a new feature request.  However, I doubt if it would be possible
to find a reasonable algorithm.  The current algorithm makes all tabs
equal size.  But with different sizes it's not clear what tabs to truncate.