[applets/digital-clock] Fix truncated Long Date display in a vertical panel

Authored by ngraham on Dec 30 2019, 11:51 PM.

Description

[applets/digital-clock] Fix truncated Long Date display in a vertical panel

Summary:
BUG: 381551
FIXED-IN: 5.18.0

Test Plan:
Before:

After:

Texted extensively because this code is so brittle. No regressions with long date in a
thick or normal-sized horizontal panel or short date in a thick or normal-sized
horizontal or vertical panel.

The one issue I could find is that sometimes switching between short and long date
formats in a double-thickness vertical panel causes the long date to be truncated again
until plasmashell is restarted. I was unable to determine why. Assistance would be
appreciated if this is a blocker.

Reviewers: Plasma, VDG, ndavis

Reviewed By: VDG, ndavis

Subscribers: ndavis, plasma-devel

Tags: Plasma

Differential Revision: https://phabricator.kde.org/D26312