Bug 448574

Summary: "performance mode disabled" and "charge limit set" message have unequal top paddings
Product: [Plasma] plasmashell Reporter: Photon <ncqm3qdz>
Component: Power and Battery widgetAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED FIXED    
Severity: minor CC: bharadwaj.raju777, kde, me, nate, vrdhotre
Priority: VLO    
Version First Reported In: git-stable-Plasma/5.24   
Target Milestone: 1.0   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In: 6.0
Sentry Crash Report:
Attachments: Battery applet
Battery applet -- with consistent measurements this time

Description Photon 2022-01-16 00:24:25 UTC
Created attachment 145518 [details]
Battery applet

SUMMARY


STEPS TO REPRODUCE
1. Open the battery system tray applet.

OBSERVED RESULT
There's different spacements everywhere in between the items.

EXPECTED RESULT


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 5.24 beta (I saw this issue in a screenshot provided in this post https://kde.org/announcements/plasma/5/5.23.90/)
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
Comment 1 Photon 2022-01-16 00:28:40 UTC
It seems that every item has it's own padding. Maybe it would be better if this padding was provided by the same place, just like the concept of a CSS class selector.
Comment 2 Photon 2022-01-16 00:29:44 UTC
This issue possibly affects other systray applets, but I haven't checked yet.
Comment 3 ratijas 2022-01-16 01:09:12 UTC
There are always ways to improve, especially for reusable inhibition hints (those small labels with icons). We refactoring it lately, step by step. And patches are welcome :)

But mind you, if you gonna measure distance between a lower bottom of lowercase letter "g" and a ceiling top notch of letter "b", "f" or any uppercase like "T" — it won't get you far in layout management. In fact, we have spent some efforts to ensure that text around battery's "progress bar" is padded by the same distance as those labels around brightness sliders.
Comment 4 Bharadwaj Raju 2022-01-16 08:59:53 UTC
Created attachment 145526 [details]
Battery applet -- with consistent measurements this time

Your measurements are all wrong. One place you're measuring from the tail of a "y", some other place you're measuring from the bottom of an "a". Some place you're measuring to the top of a capital letter. Some other place something else.

I've attached an image with measurements made *consistently* from the bottom of a lowercase letter to the top of a lowercase letter. Most of the claimed inconsistencies are shown to not actually exist.

The only possible inconsistencies left after correcting the measurements are:

1) from "Battery health" to "Your battery is configured ..." is 29px, should be 36px
2) from "Power save" to "Performance mode ..." is 21px, should be 36px
Comment 5 Vaibhav Dhotre 2022-03-17 18:32:23 UTC Comment hidden (spam)
Comment 6 ratijas 2022-03-17 19:49:02 UTC Comment hidden (spam)
Comment 7 Vaibhav Dhotre 2022-03-18 04:39:55 UTC Comment hidden (spam)
Comment 8 Nate Graham 2023-04-27 23:06:35 UTC
Ivan and Bharadwaj are right and, Bharadwaj's accurate measurements are ones you want to be using.

Basically the only thing actionable here is to make the battery charge limit message have equal top padding as the performance mode message.
Comment 9 Nate Graham 2023-12-08 20:53:53 UTC
These inconsistencies have been effectively resolved during the split of the applet between power and brightness for Plasma 6.