Bug 476925 - Digital clock in vertical panels has too much padding on top and bottom when not showing the date and/or timezone
Summary: Digital clock in vertical panels has too much padding on top and bottom when ...
Status: RESOLVED FIXED
Alias: None
Product: plasmashell
Classification: Plasma
Component: Digital Clock (show other bugs)
Version: 5.27.80
Platform: Arch Linux Linux
: NOR minor
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords: qt6
Depends on:
Blocks:
 
Reported: 2023-11-13 08:03 UTC by Jin Liu
Modified: 2024-01-17 23:14 UTC (History)
2 users (show)

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


Attachments
screenshot (75.55 KB, image/png)
2023-11-13 08:03 UTC, Jin Liu
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jin Liu 2023-11-13 08:03:55 UTC
Created attachment 163108 [details]
screenshot

SUMMARY
Screenshot attached.

Looks like it's not a fixed padding, but grows as the panel is wider. Perhaps the applet is always square.

I compared the code
https://github.com/KDE/plasma-workspace/blob/master/applets/digital-clock/package/contents/ui/DigitalClock.qml
against 5.27. Found no changes related to padding or height. Perhaps something in the framework code?

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 5.27.80
KDE Frameworks Version: 5.245.0
Qt Version: 6.6.0
Kernel Version: 6.6.1-arch1-1 (64-bit)
Graphics Platform: offscreen
Processors: 12 × AMD Ryzen 5 5600H with Radeon Graphics
Memory: 13.5 GiB of RAM
Graphics Processor: AMD Radeon Graphics
Comment 1 Nate Graham 2023-11-15 19:17:22 UTC
Can reproduce when the date and timezone are hidden; the applet doesn't vertically condense as needed. I didn't notice this before because I always have the date and timezone visible.
Comment 2 Nate Graham 2023-12-18 22:00:18 UTC
Git commit 0d14b0b153ef2bdbe1e097edb7415f3e3cef21bc by Nate Graham, on behalf of Niccolò Venerandi.
Committed on 18/12/2023 at 23:00.
Pushed by ngraham into branch 'master'.

Simplify code for applet sizes and respect max width/height of non-filling applets

Some applets don't fillWidth/Height, and yet they still set a MaxWidth/MaxHeight
(and, usually, a minWidth/minHeight that's the same value). This respects the
requested size, and tries to simplify the code using `||` as a fallback operator
instead of nested `? :` operators.
Related: bug 477813

M  +2    -2    applets/kickoff/package/contents/ui/main.qml
M  +23   -46   containments/panel/contents/ui/main.qml

https://invent.kde.org/plasma/plasma-desktop/-/commit/0d14b0b153ef2bdbe1e097edb7415f3e3cef21bc