Bug 472641 - Exiting maximized split terminal view can leave other views hidden.
Summary: Exiting maximized split terminal view can leave other views hidden.
Status: RESOLVED FIXED
Alias: None
Product: konsole
Classification: Applications
Component: split-view (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Konsole Developer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-07-26 02:34 UTC by Juerd Waalboer
Modified: 2023-08-11 23:39 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Juerd Waalboer 2023-07-26 02:34:03 UTC
SUMMARY
When a view in a second level splitter destroys itself while it is maximized, the top level set a the previously hidden other second level splitter's size to 0. This results in multiple views being hidden from view, even though they isVisible() and even though the maximization has been cleared.

STEPS TO REPRODUCE
1. Split once
2. Split each pane again. You now have a 2x2 layout
3. Mark the first three terminals by typing the letters "a", "b", and "c" in them.
4. Maximize the 4th view
5. In that 4th view, exit the shell while the view is still maximized.

OBSERVED RESULT
View "c" now occupies almost the entire window. To its left, there is a handle bar. The handle bar can be dragged to review "a" and "b".

EXPECTED RESULT
Views "a", "b" are shown in their original sizes (one quarter of the window each), view "c" occupies the right half of the window.

SOFTWARE/OS VERSIONS
Konsole 22.12.3 and current master branch
Qt Version: 5

ADDITIONAL INFORMATION
Bugfix is available, will submit shortly.
Comment 1 Juerd Waalboer 2023-07-26 02:43:51 UTC
MR of a fix: https://invent.kde.org/utilities/konsole/-/merge_requests/880
Comment 2 Juerd Waalboer 2023-07-26 10:40:21 UTC
> The handle bar can be dragged to review "a" and "b".

s/review/reveal/
Comment 3 Kurt Hindenburg 2023-08-11 23:39:14 UTC
Git commit 9dfcd62ebaab777d780a7e131de3ecc7f30a2393 by Kurt Hindenburg, on behalf of Juerd Waalboer.
Committed on 12/08/2023 at 01:39.
Pushed by hindenburg into branch 'master'.

Calculate splitter sizes when child is removed

Has as sizeable comment because the cause and fix are non-obvious and
the fix is based on the underdocumented QSplitter::refresh().

M  +9    -0    src/widgets/ViewSplitter.cpp

https://invent.kde.org/utilities/konsole/-/commit/9dfcd62ebaab777d780a7e131de3ecc7f30a2393