Bug 426520 - Limit number of displayed tabs automatically
Summary: Limit number of displayed tabs automatically
Status: RESOLVED FIXED
Alias: None
Product: kate
Classification: Applications
Component: application (other bugs)
Version First Reported In: unspecified
Platform: Other All
: NOR normal
Target Milestone: ---
Assignee: KWrite Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-09-14 13:35 UTC by martchus
Modified: 2020-09-15 14:00 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description martchus 2020-09-14 13:35:00 UTC
The tab bar showed only a limited number of tabs before https://invent.kde.org/utilities/kate/-/merge_requests/89 has been merged. I liked that behavior because that way the tab bar was automatically kept clean and showed the most relevant currently opened documents. The new tab bar is completely useless as soon as one has many documents opened concurrently. So I'd like to see the old behavior back again, e.g. as a feature which can be optionally enabled.
Comment 1 Bug Janitor Service 2020-09-14 20:26:15 UTC
A possibly relevant merge request was started @ https://invent.kde.org/utilities/kate/-/merge_requests/101
Comment 2 Christoph Cullmann 2020-09-14 20:27:09 UTC
Ok, seems that changes is more controversial than thought.

I added a option to have the old behavior "back" in some similar way but still using the "normal" tab bar.

Could you try

https://invent.kde.org/utilities/kate/-/merge_requests/101

Thanks!
Comment 3 martchus 2020-09-15 10:12:59 UTC
I've already commented on the MR. So thanks again for the quick response. If the MR is merged the bug can be resolved.
Comment 4 Christoph Cullmann 2020-09-15 14:00:10 UTC
Git commit 14e0da664a2733dee652795323b128ecbcf85c5c by Christoph Cullmann.
Committed on 15/09/2020 at 13:59.
Pushed by cullmann into branch 'master'.

implement optional limit for number of tabs and LRU replacement

this allows to have the "old" behavior of pre 20.08 as option

it is not exactly the same as in e.g. 20.04, as we still use the normal QTabBar,
but it should feel equivalent enough

as positive side effect, the user is no able to configure how many
tabs he wants to have as maximum, default is 0, aka unlimited,
before this was based on same heuristics

M  +17   -0    kate/kateapp.h
M  +24   -0    kate/kateconfigdialog.cpp
M  +1    -0    kate/kateconfigdialog.h
M  +89   -7    kate/katetabbar.cpp
M  +27   -1    kate/katetabbar.h
M  +5    -13   kate/kateviewspace.cpp

https://invent.kde.org/utilities/kate/commit/14e0da664a2733dee652795323b128ecbcf85c5c