Bug 476824

Summary: [Task Manager] Items are wider than they need to be
Product: [Plasma] plasmashell Reporter: Bacteria <dev.bacteriostat>
Component: Task Manager and Icons-Only Task Manager widgetsAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: dev.bacteriostat, nate, qydwhotmail
Priority: NOR Keywords: qt6
Version First Reported In: master   
Target Milestone: 1.0   
Platform: Other   
OS: Other   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: Task Manager item on Plasma 6
Task Manager item on Plasma 5

Description Bacteria 2023-11-11 05:58:05 UTC
Created attachment 163034 [details]
Task Manager item on Plasma 6

SUMMARY
Items are wider than they need to be


STEPS TO REPRODUCE
1. Switch to task manager widget
2. Open a window

OBSERVED RESULT
Items are wider than they should be.

EXPECTED RESULT
Items should lesser space

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Arch Linux
KDE Plasma Version: git master
KDE Frameworks Version: git master
Qt Version: 6.6.0
Comment 1 Bacteria 2023-11-11 05:58:48 UTC
Created attachment 163035 [details]
Task Manager item on Plasma 5
Comment 2 Nate Graham 2023-11-13 17:52:59 UTC
Git commit afd25b56bb8aa9ffc902f83dd6d75fec47797527 by Nate Graham, on behalf of Bacteria Dev.
Committed on 13/11/2023 at 18:52.
Pushed by ngraham into branch 'master'.

applets/taskmanager: Reduce width of items when in horizontal panel

The width of traditional Task Manager items is more than in Plasma 5
and looks odd. The reason is due to porting away from
`PlasmaCore.Theme.mSize(font).width` and using
`Kirigami.Units.iconSizes.sizeForLabels` instead.

This metric is meant to be used for icon size calculations, so instead
let's use `Kirigami.Units.gridUnit` according to the porting guide.

M  +1    -1    applets/taskmanager/package/contents/ui/code/layout.js

https://invent.kde.org/plasma/plasma-desktop/-/commit/afd25b56bb8aa9ffc902f83dd6d75fec47797527