Skip to content

[applets/weather] Overhaul and unify tray and widget compact representations

This resolves a variety of issues with the Weather applet's compact representation present in the current version:

  • Widget version takes up much too much space on a vertical panel when showing the temperature
  • Widget version's temperature text is chronically inconsistent in size with the clock's text at various patch thicknesses, leading to bug reports requesting that we unify them which prove impossible to resolve due to the complexity of the text sizing code
  • Icon sizing code in general is unnecessarily complex
  • Tray version cannot show temperature and its config window shows a frustratingly disabled button to do so

This MR resolves all of the above issues by making the temperature display appear in an overlay badge in the icon's bottom-right corner. This precisely mimics the overlay used in the Battery applet, so the two now have perfectly consistent overlay appearances. This can be extracted into a shared component in plasma-framework later. And now the System Tray version is identical to the version added as a standalone widget, just like other applets that can appear in either the System Tray or as a standalone widget on a Panel.

Before: widget version uses too much space in a vertical panel:

Widget_version__before

After: widget version is more compact in a vertical panel:

Widget_version__after

After: widget and system tray versions have feature parity and look identical:

Widget_and_tray_applet_versions_identical

cc @teams/vdg cc @broulik cc @kossebau

Merge request reports