Bug 453616

Summary: Reduce the padding on icons-only task manager preview windows
Product: [Plasma] plasmashell Reporter: wenekar <wenekar1>
Component: Task Manager and Icons-Only Task Manager widgetsAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED INTENTIONAL    
Severity: minor CC: nate
Priority: NOR    
Version First Reported In: 5.24.5   
Target Milestone: 1.0   
Platform: unspecified   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: Screenshot of the huge padding between the windows.

Description wenekar 2022-05-10 09:10:20 UTC
Created attachment 148700 [details]
Screenshot of the huge padding between the windows.

SUMMARY

Reduce the padding on icons-only task manager preview windows when more than one window is open. This is especially noticeable when the panel is used in the vertical mode. 


STEPS TO REPRODUCE
1. Make a vertical panel with icons-only task manager.
2. Open 2 or more windows for 1 application.
3. Hover mouse over the task manager.

OBSERVED RESULT
The padding between two preview windows are too big.

EXPECTED RESULT
Less padding between the two windows.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Arch Linux
(available in About System)
KDE Plasma Version: 5.24.5
KDE Frameworks Version: 5.93.0
Qt Version: 5.15.3
Comment 1 Nate Graham 2022-05-10 16:00:36 UTC
Currently the Task Manager tooltips have exactly the same size no matter the window's size or aspect ratio, by design. This unavoidably results in extra padding anytime the window's aspect ratio does not exactly match the aspect ratio of the tooltip, as you've discovered. If we wanted to reduce the padding in the case you've presented, we'd have to throw all that away and make the tooltip size dynamic and match the window's aspect ratio.

But if we did that, there would be a problem: for tall and skinny windows with long titles (such as windows that have been tiled to the left or right side of the screen), their titles would get elided or wrap only to many lines, and that would be quite ugly and non-functional.

If instead we made the size dynamic but imposed a minimum width to avoid that, then the tooltip size would seem arbitrary to users, and we'd get different bug reports saying, "sometimes the tooltip fits the window perfectly, and sometimes it doesn't."

In the end we had to pick one of these imperfect options, and we picked the simple and consistent option of just making the tooltip have the same size no matter the window's aspect ratio. I don't think we can change it without creating regressions for other use cases, sorry.