Bug 360059 - Inconsistent and too large font used for time in digital clock plasmoid
Summary: Inconsistent and too large font used for time in digital clock plasmoid
Status: RESOLVED FIXED
Alias: None
Product: plasmashell
Classification: Plasma
Component: Digital Clock (show other bugs)
Version: 5.5.5
Platform: Arch Linux Linux
: NOR normal
Target Milestone: 1.0
Assignee: Martin Klapetek
URL:
Keywords:
: 366140 (view as bug list)
Depends on:
Blocks:
 
Reported: 2016-03-04 11:23 UTC by Peter Lewis
Modified: 2017-01-03 14:48 UTC (History)
9 users (show)

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


Attachments
Screenshot illustrating the problem. (12.59 KB, image/png)
2016-03-04 11:24 UTC, Peter Lewis
Details
small font clock (2.54 KB, image/jpeg)
2016-09-25 04:10 UTC, Mark Fairbairn
Details
space to left clock (2.93 KB, image/jpeg)
2016-09-25 04:10 UTC, Mark Fairbairn
Details
too large font (2.90 KB, image/jpeg)
2016-09-25 08:58 UTC, Mark Fairbairn
Details
Screenshot showing the large date size (12.20 KB, image/png)
2016-10-07 06:59 UTC, Nikos Platis
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Lewis 2016-03-04 11:23:22 UTC
When displaying the digital clock in a panel, the fonts used for the date and time are inconsistent. This looks bad. Also, the font used for the time is too big. Further, while the time itself is configurable (but not in terms of size), the timezone does not appear to be. The result is very inconsistent. See the attached screenshot.

The font size that is automatically chosen for the date seems to be the best choice. A good solution would be to use use that for all textual elements in the clock: date, time and timezone.

Reproducible: Always

Steps to Reproduce:
1. Enable digital clock in the panel
2. Enable long date and timezone visibility.
3. Look at the inconsistent fonts!

Actual Results:  
The fonts are inconsistent in terms of typeface and size.

Expected Results:  
There should be one consistent font and size, which fits well with the panel size.
Comment 1 Peter Lewis 2016-03-04 11:24:20 UTC
Created attachment 97671 [details]
Screenshot illustrating the problem.
Comment 2 Daniel Faust 2016-03-19 13:30:28 UTC
There is a patch at https://git.reviewboard.kde.org/r/127393/, which unifies the font used for the date and the time when the clock is shown in a narrow panel. But it will in most cases increase the font size of the date label.

If having an option to scale the font size is important to you, you might want to create a feature request just for that.
Comment 3 David Edmundson 2016-09-11 23:40:08 UTC
*** Bug 366140 has been marked as a duplicate of this bug. ***
Comment 4 Mark Fairbairn 2016-09-25 04:09:39 UTC
with the release of 5.7.95 (5.8 beta) this issue seems to have gone in the opposite direction with the digital clock plasmoid font now too small (and with too much space to the left of the clock.
Font size can be increased in systemsettings but results in too large fonts elsewhere in plasma
Comment 5 Mark Fairbairn 2016-09-25 04:10:17 UTC
Created attachment 101266 [details]
small font clock
Comment 6 Mark Fairbairn 2016-09-25 04:10:58 UTC
Created attachment 101267 [details]
space to left clock
Comment 7 Mark Fairbairn 2016-09-25 08:58:38 UTC
Created attachment 101272 [details]
too large font

increasing tray width by just one pixel results in a large jump in font size to one that is now too big - but solves the wasted space to the left of the clock problem.
Comment 8 Nikos Platis 2016-10-07 06:59:19 UTC
Created attachment 101464 [details]
Screenshot showing the large date size

In addition, in Plasma 5.8, the date seems to have a minimum font size that is too big (in previous versions the minimum font size for the date was indeed too small, and it could become unreadable). So, especially if you want to see the full date, you end up using too much space on the taskbar. Also, as it is apparent on the screenshot, the bottom few pixels of the date are cut off at this taskbar size.

The screenshot also makes evident why one should be able to customize the date format on the clock (eg. I want to see the day of the week but I would prefer a shorter version), but that's probably on bug 278200...
Comment 9 x 2016-11-03 22:09:08 UTC
What comment 8 says and illustrates with a screenshot: the date font size is too big (and so is the time's, btw).

Would it somehow be possible to have an option to select not just the font face, but also the font size for the time, and separately, for the date?

Reason why you want them to be different: most frequently the user looks at the time, and if that is the shorter string, then it would make sense to allow it to take more space by increasing its font size relative to the date, which is only glanced at occasionally.

On the other hand, some users may prefer to have a long time (with seconds) and only a short date, or no date at all. In this case, they may also prefer a smaller font size in order to save screen space (or bigger font size, if they have eyesight trouble).
Comment 10 Roman Gilg 2016-12-25 17:03:37 UTC
Take a look at my proposed ui cleanup: https://phabricator.kde.org/D3630

The screenshots there are slightly outdated, but if you are able to compile Plasma Workspace on your machine, you can try out the diff yourself.
Comment 11 Roman Gilg 2017-01-03 14:48:13 UTC
Git commit 1d362c4ae2e264a80c002ab6718c1b1d9437c20c by Roman Gilg.
Committed on 03/01/2017 at 14:37.
Pushed by romangilg into branch 'master'.

[Digital Clock] Bug fixes and ui code optimization

Summary:
- Fixed timezone size and alignment in vertical mode
- Instead of `Flow` use `Grid` for labels as it's simpler and gives better
  control over alignment
- Seperator in small horizontal mode centered between date and time and in
  height now dependent on label size
- Less empty space around time in small horizontal mode
- Binding loop and initlializting anchor errors fixed
- Elements now size completely down and have always the same ratio to each other
  with the time label being the largest
- Round functions removed since they disrupted the resizing for small sizes
- Introduce max font size values for text elements in panel mode
Related: bug 367585, bug 373396

Reviewers: #plasma, mart

Subscribers: mart, plasma-devel

Tags: #plasma

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

M  +206  -148  applets/digital-clock/package/contents/ui/DigitalClock.qml

https://commits.kde.org/plasma-workspace/1d362c4ae2e264a80c002ab6718c1b1d9437c20c