Shell: Better width calculation for tabs if available space is limited
This merge request is an adaption of this 2 year old merge request by @tgier and fixes two bug reports (One, Two) by making all tabs the same width if there is not enough space for all tabs.
Changes from the original Merge-request:
- Rebased on current master branch
- Formatted the source code according to README.clang_format.
- Added new Q_OBJECT
- Falls back to the original behavior of Okular to determine tab size by length of their title if there is enough available space to do so
Before
After
Edited by Tom Knuf