On Wednesday 17 December 2008, D. R. Evans wrote: > Aaron J. Seigo said the following at 12/15/2008 03:42 PM : > > so, the "Plasma Way" to do this would be to create a DataEngine that > > handles the NOAA part. it would download and parse the data for the > > Applet. the Applet would connect to it by doing something like (assuming > > you called your dataengine "noaa", probably a better name for it ;): > > > > > > > > in the Applet part, for plotting we have Plasma::SignalPlotter ... it's a > > bit of a beast, but rather powerful. > > > > you'd make a dataUpdated(const QString &sourceName, const > > Plasma::DataEngine::Data &data) method in your applet (or whatever you > > connect the source to) .. sourceName would be "solarflux" in this > > example, and the data would contain whatever the engine sends your way. > > > > the updateInterval, engine loading, etc is all handled automagically for > > you. > > Where is there some documentation for SignalPlotter (the python version; > I've decided that python is the way to go for this simple plasmoid)?
i'm sure Simon Edwards will be please to hear that =)) > I have > a draft of the DataEngine written (doubtless with bugs, but I understand > the principle so it's basically just debugging that's needed). I couldn't cool > find an example of a python plasmoid that uses a SignalPlotter the way that > I could for the DataEngine, though, so I have nothing to steal and no > documentation to get an understanding of what SignalPlotter does and how to ah, it's just a graph ... basically, you call addPlot for each line you'd like it to graph; then you call addSample whenever the data updates =) -- Aaron J. Seigo humru othro a kohnu se GPG Fingerprint: 8B8B 2209 0C6F 7C47 B1EA EE75 D6B7 2EB1 A7F1 DB43 KDE core developer sponsored by Qt Software
signature.asc
Description: This is a digitally signed message part.
_______________________________________________ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel