bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#37667: 27.0.50; Tab Bar display problems with more than 5 tabs


From: Juri Linkov
Subject: bug#37667: 27.0.50; Tab Bar display problems with more than 5 tabs
Date: Thu, 31 Oct 2019 02:03:51 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu)

>> I don't want to modify display_string to take the tab-line
>> into account because more logic for searching the current tab
>> needs to be implemented anyway.
>
> Searching the current tab and displaying truncation indicators are two
> separate tasks that don't necessarily need the same (or even similar)
> code.  The former could be found much easier, I think.

Before starting to search the current tab, the code needs to known
whether truncation really occurred.

>> So maybe better to copy code from display_string to a new function
>> tab_visible_in_tab_line, and beside detection of truncation also add
>> more code to detect a situation when the current tab is not visible
>> due to truncation.
>
> I don't think these two jobs are similar enough, but maybe I don't
> understand well enough what you have in mind.  Can you elaborate how
> you intended to search for the current tab?

We need to detect whether the current tab is before the right truncation point
(so it is visible), or after the truncation (so the current tab is not visible).

It seems searching for the current tab is not possible in the glyph matrix,
because when the current tab is after the truncation point, then its
glyphs are not produced.

Then the code for searching the current tab should be similar to
display_string but without producing glyphs.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]