This fixes the broken layout of the tab bar (tab bar takes the whole view)
when a panel is changed from horizontal to vertical that persists
until plasmashell is restarted.
BUG: 393888
Details
- Reviewers
hein ngraham - Group Reviewers
Plasma - Maniphest Tasks
- T10047: Guerilla UX testing: a GNOME switcher
- Commits
- R119:2054d9be40bc: Fix incorrect Kickoff tab bar layout for vertical panels
Change panel orientation from horizontal to vertical. Open Kickoff.
Before fix: tab bar fills the whole view making the Kickoff unusable even if you make the panel horizontal again.
After fix: tab bar has the correct size.
Diff Detail
- Repository
- R119 Plasma Desktop
- Lint
Automatic diff as part of commit; lint not applicable. - Unit
Automatic diff as part of commit; unit tests not applicable.
Line onHeightChanged: onWidthChanged() fixes BUG: 395390
I'm not sure if this is the best solution. For some reason, plasmacomponents/qml/TabBar.qml lacks an onHeightChanged() function but it has onWidthChanged() that seems to do what needs to happen here. Maybe TabBar.qml should be changed instead.
The rest of the changes is for BUG: 393888
It seems to me that the removed code was a more clean way to do this, but it didn't update the values without restarting.
I also couldn't reproduce the gray overlay (which is caused by tabBarSeparator having a wrong size and taking the whole view - yesterday I could reproduce it but no more) that is shown in the comment 16 here: https://bugs.kde.org/show_bug.cgi?id=395390#c16
So it may still be present. Currently, I can't see any separator but it's a different issue.
Thanks very much for the patch! This fixes both issues for me and looks conceptually like an appropriate fix to me, but I'm not the original author or maintainer of this code as @hein is, so let's wait for his review.
... I'm not the author or maintainer of this code, but I had a look anyway :).
@lisin, I agree with you that the sizing bug should be fixed in TabBar instead, in plasma-frameworks.git. It's very unorthodox to call a property change handler as a function, and it's not going to fix this for other potential users of the component.
Otherwise the patch looks good. Could you resubmit it without line 435, and then submit a seperate patch to plasma-frameworks?
Now we just need that plasma-frameworks patch to also fix https://bugs.kde.org/show_bug.cgi?id=395390. :)
Let me know if you need a hand.
Thank you, this was my first ever contribution to FOSS!
I have submitted the fix for the TabBar here: https://phabricator.kde.org/D23036
I'm not quite sure about who to add as reviewers though.
Very nice job! May it be the first of many. :) I hope the process wasn't too difficult. We're trying to make it smoother for new contributors.