Restoring weather applet in kdeplasma-addons

Friedrich W. H. Kossebau kossebau at
Thu Feb 25 01:51:51 UTC 2016

Hi Marco,

time flies, and I so much would like to get the weather applet revived for the 
next release still.
Do I see correctly that kdeplasma-addons is part of "Plasma" releases, and 
thus I need to care for Feature freeze on March 3rd? So are there chances to 
get the weather applet in for 5.6 still?

In other news, I just pushed some more commits which enabled config to a good 
degree again, module rough edges :) So Turin is no longer the only place to 
get forecasts for ;)

Next porting steps are support for iconic/minimized variant of the applet and 
setting tooltips on the applet. The applet used to be a Plasma::PopupApplet in 
old Plasma. Where do I look best for how to port such applets to the new 
Plasma5 way?

showMessage() is ported to?
toolTipAboutToShow() is ported to?

Read on for some more comments/replies:

Am Dienstag, 9. Februar 2016, 12:17:40 CET schrieb Marco Martin:
> On Tuesday 09 February 2016 01:07:14 Friedrich W. H. Kossebau wrote:
> > the
> > 
> > > config key
> > 
> > You meant "main.xml" here where you wrote "config.xml", right?
> > (would match files I found elsewhere in the repo)
> ah, yes, main.xml

I looked into this, but hit a problem: the old code set default units 
depending on QLocale().measurementSystem() (e.g. Celsius vs. Fahrenheit).

Is supporting such smart defaults possible with main.xml?

For now I looked closely at the comic applet config system and found some 
methods and signal signatures which seem to offer a non-main.xml-based way to 
read & write config data via C++-applet code, and got something working :)

> > > > * KUnitConversion data handling config & widgets, no idea yet how to
> > 
> > port
> > 
> > > > that to QQ2
> > > 
> > > isn't that stuff in kde4support?
> > 
> > No, KF5::UnitConversion is a proper frameworks lib :)
> excellent then :)
> so the sanest approach is indeed have a minimal c++ applet, then adding back
> those classes you need:
> there is actually an app template for that, should be available either from
> kdevelop or kapptemplate

Given some tendency for insanity after small consideration I dropped this 
approach again and for now stayed close with the old distributed applet 
architecture, for the reasons that I still needed to completely grasp the 
concepts of the old code method by method and also was not sure if someone 
might want to restore the weatherstation applet, for which libplasmaweather 
code sharing is done.
Though I put the config stuff ported to QML plugin already only below the 
weather applet, and next will consequently also merge the lib code into the 
weather applet code itself, dropping libplasmaweather to simplify things for 
Once someone really would restore the weatherstation applet, any code & QML 
plugin sharing can be reconsidered then, the old code is for comparison always 
in the repo :)


More information about the Plasma-devel mailing list